


##lshwlshw This command is a relatively
general tool that can be used in detail List hardware information of this machine. But this command is not available in all distributions. For example, Fedora does not have it by default and you need to install it yourself.
lshw can extract hardware information from each /proc file, such as:CPU, memory, usb controller, hard disk, etc. Without options, the information listed will be very long. With the -short option, only
summary information will be listed.
[alvin@VM_0_16_centos ~]$ sudo lshw -short #篇幅关系,以下结果有删减 H/W path Device Class Description ========================================================== system Bochs /0 bus Motherboard /0/0 memory 96KiB BIOS /0/401 processor Intel(R) Xeon(R) CPU E5-26xx v4 /0/1000 memory 2GiB System Memory /0/1000/0 memory 2GiB DIMM RAM /0/100 bridge 440FX - 82441FX PMC [Natoma] /0/100/1 bridge 82371SB PIIX3 ISA [Natoma/Triton II] /0/100/1.1/0.1.0 /dev/cdrom disk QEMU DVD-ROM /0/100/1.2/1 usb1 bus UHCI Host Controller /0/100/1.3 bridge 82371AB/EB/MB PIIX4 ACPI /0/100/4/0/1 /dev/vda1 volume 49GiB EXT3 volume /0/100/5 generic Virtio memory balloon /0/100/5/0 generic Virtual I/O device /0/1 system PnP device PNP0b00 /0/2 input PnP device PNP0303lscpulscpu can list the
CPU related information of this machine. This command does not have any options or parameters.
[alvin@VM_0_16_centos ~]$ lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 1 On-line CPU(s) list: 0 Thread(s) per core: 1 Core(s) per socket: 1 Socket(s): 1 NUMA node(s): 1 Vendor ID: GenuineIntel CPU family: 6 Model: 79 Model name: Intel(R) Xeon(R) CPU E5-26xx v4 Stepping: 1 CPU MHz: 2399.988 BogoMIPS: 4799.97 Hypervisor vendor: KVM Virtualization type: full L1d cache: 32K L1i cache: 32K L2 cache: 4096K NUMA node0 CPU(s): 0lsusblsusb Lists the information of all
USB devices connected to this machine. By default, only summary information is listed. Use the -v option to list detailed information for each
USB port.
[alvin@VM_0_16_centos ~]$ lsusb Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp. SMC9514 Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hublsscsilsscsi can list device information such as
hard disk/optical drive, etc. SCSI/SATA.
[alvin@VM_0_16_centos ~]$ lsscsi [0:0:1:0] cd/dvd QEMU QEMU DVD-ROM 1.2. /dev/sr0lspcilspci Lists all
PCI buses and detailed information of all devices connected to the PCI bus, such as VGA adapters, graphics cards, network adapters , usb port, SATA controller, etc.
[alvin@VM_0_16_centos ~]$ lspci 00:00.0 Host bridge: Intel Corporation 440FX - 82441FX PMC [Natoma] (rev 02) 00:01.0 ISA bridge: Intel Corporation 82371SB PIIX3 ISA [Natoma/Triton II] 00:01.1 IDE interface: Intel Corporation 82371SB PIIX3 IDE [Natoma/Triton II] 00:01.2 USB controller: Intel Corporation 82371SB PIIX3 USB [Natoma/Triton II] (rev 01) 00:01.3 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ACPI (rev 03) 00:02.0 VGA compatible controller: Cirrus Logic GD 5446 00:03.0 Ethernet controller: Red Hat, Inc Virtio network device 00:04.0 SCSI storage controller: Red Hat, Inc Virtio block device 00:05.0 Unclassified device [00ff]: Red Hat, Inc Virtio memory balloondfdf command can list the size of different partitions,
usage, usage, mount point and other information, plus -h The option can express the size in units such as k, M, G, etc. Otherwise, the default is
bytes, which is not easy to read.
[alvin@VM_0_16_centos ~]$ df -h Filesystem Size Used Avail Use% Mounted on /dev/vda1 50G 7.5G 40G 16% / devtmpfs 911M 0 911M 0% /dev tmpfs 920M 68K 920M 1% /dev/shm tmpfs 920M 364K 920M 1% /run tmpfs 920M 0 920M 0% /sys/fs/cgroup tmpfs 184M 0 184M 0% /run/user/0 tmpfs 184M 0 184M 0% /run/user/1001 tmpfs 184M 0 184M 0% /run/user/1000freeThe free command can view the
used, idle and overall amount of RAM in the system, usually with the -m parameter.
[alvin@VM_0_16_centos ~]$ free -m total used free shared buff/cache available Mem: 1839 221 156 0 1461 1400 Swap: 0 0 0
For more Linux articles, please visit the Linux Tutorial column to learn!
The above is the detailed content of How to check hardware information under Linux. For more information, please follow other related articles on the PHP Chinese website!

linux设备节点是应用程序和设备驱动程序沟通的一个桥梁;设备节点被创建在“/dev”,是连接内核与用户层的枢纽,相当于硬盘的inode一样的东西,记录了硬件设备的位置和信息。设备节点使用户可以与内核进行硬件的沟通,读写设备以及其他的操作。

区别:1、open是UNIX系统调用函数,而fopen是ANSIC标准中的C语言库函数;2、open的移植性没fopen好;3、fopen只能操纵普通正规文件,而open可以操作普通文件、网络套接字等;4、open无缓冲,fopen有缓冲。

端口映射又称端口转发,是指将外部主机的IP地址的端口映射到Intranet中的一台计算机,当用户访问外网IP的这个端口时,服务器自动将请求映射到对应局域网内部的机器上;可以通过使用动态或固定的公共网络IP路由ADSL宽带路由器来实现。

在linux中,eof是自定义终止符,是“END Of File”的缩写;因为是自定义的终止符,所以eof就不是固定的,可以随意的设置别名,linux中按“ctrl+d”就代表eof,eof一般会配合cat命令用于多行文本输出,指文件末尾。

在linux中,交叉编译是指在一个平台上生成另一个平台上的可执行代码,即编译源代码的平台和执行源代码编译后程序的平台是两个不同的平台。使用交叉编译的原因:1、目标系统没有能力在其上进行本地编译;2、有能力进行源代码编译的平台与目标平台不同。

在linux中,可以利用“rpm -qa pcre”命令判断pcre是否安装;rpm命令专门用于管理各项套件,使用该命令后,若结果中出现pcre的版本信息,则表示pcre已经安装,若没有出现版本信息,则表示没有安装pcre。

linux查询mac地址的方法:1、打开系统,在桌面中点击鼠标右键,选择“打开终端”;2、在终端中,执行“ifconfig”命令,查看输出结果,在输出信息第四行中紧跟“ether”单词后的字符串就是mac地址。

在linux中,rpc是远程过程调用的意思,是Reomote Procedure Call的缩写,特指一种隐藏了过程调用时实际通信细节的IPC方法;linux中通过RPC可以充分利用非共享内存的多处理器环境,提高系统资源的利用率。


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

mPDF
mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),
