Aqui está um script rápido / coleção de comandos para você começar. Adicione comandos (ifconfig, lspci, etc.) como achar melhor:
#!/bin/bash
# hwcollect.sh - Collect general system information
# Hostname
echo -e "$HOSTNAME \n"
# Display system manufacturer, model, serial and other attributes
dmidecode -t 1 | egrep '(Manufacturer|Product|Serial)'
dmidecode -t 3 | egrep '(Height)';
dmidecode -t processor| egrep '(Socket|Version)'
# Calculate installed RAM
dmidecode -t 17 | awk '( /Size/ && $2 ~ /^[0-9]+$/ ) { x+=$2 } END{ print "\t" "Installed Ram: " x "MB"}'
echo " "
echo "Disk Information"
# Filesystem mounts
df -h
# Display disk partition table
fdisk -l
Eu posso executar um loop ssh rápido ou executá-lo individualmente a partir de um host de origem usando algo como: ssh targethost < hwcollect.sh
Exemplo:
[root@xetra ~]# ssh Test_Server < hwcollect.sh
Pseudo-terminal will not be allocated because stdin is not a terminal.
Test_Server
Manufacturer: HP
Product Name: ProLiant DL380 G6
Serial Number: 2UX12345KT
Height: 2 U
Socket Designation: Proc 1
Version: Intel(R) Xeon(R) CPU X5570 @ 2.93GHz
Upgrade: Socket LGA1366
Socket Designation: Proc 2
Version: Intel(R) Xeon(R) CPU X5570 @ 2.93GHz
Upgrade: Socket LGA1366
Installed Ram: 32768MB
Disk Information
Filesystem Size Used Avail Use% Mounted on
/dev/cciss/c0d0p2 20G 5.1G 14G 28% /
/dev/cciss/c0d0p7 3.0G 74M 2.7G 3% /tmp
/dev/cciss/c0d0p6 5.9G 2.3G 3.3G 42% /var
/dev/cciss/c0d0p3 9.7G 4.7G 4.6G 51% /usr
/dev/cciss/c0d0p1 99M 39M 55M 42% /boot
/dev/cciss/c0d0p8 573G 433G 140G 76% /scratch
/dev/cciss/c0d0p9 1.1T 702G 348G 67% /data
tmpfs 16G 0 16G 0% /dev/shm
/dev/sda1 400G 298G 103G 75% /data/datatest
Disk /dev/cciss/c0d0: 1800.2 GB, 1800280694784 bytes
255 heads, 63 sectors/track, 218871 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/cciss/c0d0p1 * 1 13 104391 83 Linux
/dev/cciss/c0d0p2 14 2624 20972857+ 83 Linux
/dev/cciss/c0d0p3 2625 3929 10482412+ 83 Linux
/dev/cciss/c0d0p4 3930 218871 1726521615 5 Extended
/dev/cciss/c0d0p5 3930 6018 16779861 82 Linux swap / Solaris
/dev/cciss/c0d0p6 6019 6801 6289416 83 Linux
/dev/cciss/c0d0p7 6802 7193 3148708+ 83 Linux
/dev/cciss/c0d0p8 7194 81891 600011653+ 83 Linux
/dev/cciss/c0d0p9 81892 218871 1100291818+ 83 Linux
Disk /dev/sda: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 1 52216 419424988+ 83 Linux