Linux Ubuntu - sprawdzanie konfiguracji sprzętowej za pomocą terminala
Egzamin zawodowy technik informatyk
Ostatnio na egzaminie pojawiły się zadania ze sprawdzania konfiguracji sprzętowej w terminalu. Przykładowo poniżej zaprezentuje to na podstawie egzaminu z czerwca 2020, zadanie 2. Do wypełnienia była tabela, gdzie gdzie obok zadanych parametrów trzeba było wpisać użyte polecenie. Trzeba było zidentyfikować co najmniej 5 z 6 elementów.
Jak widać poniżej użyto polecenia dmidecode -t memory
. Nie zapomnij o sudo.
Można też posłużyć się poleceniem lshw
. Nie zapomnij o sudo.
Polecenie dmidecode
Jak sprawdzić inne parametry sprzętowe za pomocą dmidecode? Wpisujmy sudo dmidecodec -t
i widzimy co mozemy sprawdzić
ubuntu@ubuntu:~$ dmidecode -t dmidecode: option requires an argument -- 't' Type number or keyword expected Valid type keywords are: bios system baseboard chassis processor memory cache connector slot
Przykładowo chcemy wyświetlić informacje o procesorze to wpisujemy sudo dmidecode -t processor
ubuntu@ubuntu:~$ sudo dmidecode -t processor # dmidecode 3.1 Getting SMBIOS data from sysfs. SMBIOS 3.1.1 present. Handle 0x004E, DMI type 4, 48 bytes Processor Information Socket Designation: U3E1 Type: Central Processor Family: Core i5 Manufacturer: Intel(R) Corporation ID: EA 06 09 00 FF FB EB BF Signature: Type 0, Family 6, Model 158, Stepping 10 Flags: FPU (Floating-point unit on-chip) VME (Virtual mode extension) DE (Debugging extension) PSE (Page size extension) TSC (Time stamp counter) MSR (Model specific registers) PAE (Physical address extension) MCE (Machine check exception) CX8 (CMPXCHG8 instruction supported) APIC (On-chip APIC hardware supported) SEP (Fast system call) MTRR (Memory type range registers) PGE (Page global enable) MCA (Machine check architecture) CMOV (Conditional move instruction supported) PAT (Page attribute table) PSE-36 (36-bit page size extension) CLFSH (CLFLUSH instruction supported) DS (Debug store) ACPI (ACPI supported) MMX (MMX technology supported) FXSR (FXSAVE and FXSTOR instructions supported) SSE (Streaming SIMD extensions) SSE2 (Streaming SIMD extensions 2) SS (Self-snoop) HTT (Multi-threading) TM (Thermal monitor supported) PBE (Pending break enabled) Version: Intel(R) Core(TM) i5-8300H CPU @ 2.30GHz Voltage: 0.9 V External Clock: 100 MHz Max Speed: 4000 MHz Current Speed: 3900 MHz Status: Populated, Enabled Upgrade: Other L1 Cache Handle: 0x004B L2 Cache Handle: 0x004C L3 Cache Handle: 0x004D Serial Number: To Be Filled By O.E.M. Asset Tag: To Be Filled By O.E.M. Part Number: To Be Filled By O.E.M. Core Count: 4 Core Enabled: 4 Thread Count: 8 Characteristics: 64-bit capable Multi-Core Hardware Thread Execute Protection Enhanced Virtualization Power/Performance Control
Polecenie lshw
Pełna informacja o sprzęcie to po prostu wpisanie sudo lshw
Wkleję tylko fragment.
ubuntu@ubuntu:~$ sudo lshw ubuntu description: Notebook product: Precision 3530 (0820) vendor: Dell Inc. serial: J5L9TQ2 width: 64 bits capabilities: smbios-3.1 dmi-3.1 smp vsyscall32 configuration: boot=normal chassis=notebook family=Precision sku=0820 uuid=44454C4C-3500-104C-8039-CAC04F545132 *-core description: Motherboard product: 0YM64G vendor: Dell Inc. physical id: 0 version: A00 serial: /J5L9TQ2/CNCMK008980002/ *-firmware description: BIOS vendor: Dell Inc. physical id: 0 version: 1.2.5 date: 06/22/2018 size: 64KiB capacity: 15MiB capabilities: pci pnp upgrade shadowing cdboot bootselect edd int13floppynec int13floppy1200 int13floppy720 int13floppy2880 int5printscreen int9keyboard int14serial int17printer acpi usb smartbattery biosbootspecification netboot uefi *-memory description: System Memory physical id: 42 slot: System board or motherboard size: 16GiB *-bank:0 description: SODIMM DDR4 Synchronous 2667 MHz (0.4 ns) product: 16ATF2G64HZ-2G6E1 vendor: Micron Technology physical id: 0 serial: 1D3C676B slot: DIMM A size: 16GiB width: 64 bits clock: 2667MHz (0.4ns)
Można też użyć wersji skróconej sudo lshw -short
. Generalnie macie helpa i mana :)
buntu@ubuntu:~$ sudo lshw -short H/W path Device Class Description ============================================================== system Precision 3530 (0820) /0 bus 0YM64G /0/0 memory 64KiB BIOS /0/42 memory 16GiB System Memory /0/42/0 memory 16GiB SODIMM DDR4 Synchronous /0/42/1 memory DIMM [empty] /0/4b memory 256KiB L1 cache /0/4c memory 1MiB L2 cache /0/4d memory 8MiB L3 cache /0/4e processor Intel(R) Core(TM) i5-8300H CP /0/100 bridge Intel Corporation /0/100/1 bridge Xeon E3-1200 v5/E3-1500 v5/6t /0/100/1/0 display GP107GLM [Quadro P600 Mobile] /0/100/2 display Intel Corporation /0/100/4 generic Xeon E3-1200 v5/E3-1500 v5/6t /0/100/8 generic Xeon E3-1200 v5/v6 / E3-1500 /0/100/12 generic Cannon Lake PCH Thermal Contr /0/100/14 bus Cannon Lake PCH USB 3.1 xHCI /0/100/14/0 usb1 bus xHCI Host Controller /0/100/14/0/1 input USB Optical Mouse /0/100/14/0/2 scsi3 storage Mass Storage /0/100/14/0/2/0.0.0 /dev/sdb disk 31GB Flash Disk /0/100/14/0/2/0.0.0/0 /dev/sdb disk 31GB /0/100/14/0/2/0.0.0/0/1 /dev/sdb1 volume 29GiB Windows FAT volume /0/100/14/0/a generic 5880 /0/100/14/0/b multimedia Integrated_Webcam_HD /0/100/14/0/e communication Bluetooth wireless interface /0/100/14/1 usb2 bus xHCI Host Controller /0/100/14/1/4 scsi4 storage Ultra /0/100/14/1/4/0.0.0 /dev/sdc disk 30GB Ultra /0/100/14/1/4/0.0.0/0 /dev/sdc disk 30GB /0/100/14/1/4/0.0.0/0/1 /dev/sdc1 volume 28GiB Windows NTFS volume /0/100/14.2 memory RAM memory /0/100/14.3 wlo1 network Wireless-AC 9560 [Jefferson P /0/100/15 bus Intel Corporation /0/100/15.1 bus Intel Corporation /0/100/16 communication Cannon Lake PCH HECI Controll /0/100/17 storage 82801 Mobile SATA Controller /0/100/1c bridge Intel Corporation /0/100/1c.5 bridge Intel Corporation /0/100/1c.5/0 generic RTS525A PCI Express Card Read /0/100/1f bridge Intel Corporation /0/100/1f.3 multimedia Cannon Lake PCH cAVS /0/100/1f.4 bus Cannon Lake PCH SMBus Control /0/100/1f.5 bus Cannon Lake PCH SPI Controlle /0/100/1f.6 eno2 network Ethernet Connection (7) I219- /0/1 scsi2 storage /0/1/0.0.0 /dev/sda disk 500GB TOSHIBA MQ01ACF0 /0/1/0.0.0/1 /dev/sda1 volume 127MiB reserved partition /0/1/0.0.0/2 /dev/sda2 volume 465GiB Windows NTFS volume /1 power DELL GD1JP65
Ćwiczenia
Proszę uruchomić Ubuntu w wersji live na komputerze (VirtualBox wykluczony) i wykonać poniższe zadania. Dokumentacja na zrzutach ekranu lub zdjęciach. Szukane elementy mają być zaznaczone w programie graficznym, sam zrzut mnie nie interesuje. Szukać na nim nie będę.
- Proszę podać typ, wielkość i nr seryjny pamięci RAM.
- Proszę podać jaką masz wersję procesora (np. Intel(R) Core(TM) i5-8300H CPU @ 2.30GHz).
- Proszę podać nr seryjny i producenta płyty głównej.
- Proszę podać informacje o wielkości dysków twardych, logicznej lokalizacji (np. /dev/sda1).
- Proszę podać następujące informacje o karcie sieciowej: przepustowość, adres MAC.