checking hardware type automatically
Matthew Palmer
mjp16 at ieee.uow.edu.au
Wed Aug 8 03:39:24 CEST 2001
On Tue, 7 Aug 2001, Roland Thomas Lichti wrote:
> But now I have the problem to get the type of hardware determined by
> fai. We use three different server and I need to distinguish beetween
> them (mainly for hardware monitoring). I used to check for the pci host
Typically I set a classname based on the hardware involved, as per the
following script:
# Ethernet cards
if grep -q RTL-8139 /proc/pci; then
echo RTL8139
fi
# Sound cards
if grep -q "AudioPCI" /proc/pci; then
echo ES1371SOUND
fi
if dmesg | grep -q "sb:.*detected"; then
echo SBSOUND
fi
# Graphics cards
if grep -q "nVidia Corporation NV11 DDR" /proc/pci; then
echo VIDEONVIDIA
fi
if grep -q "Riva128" /proc/pci; then
echo VIDEORIVA128
fi
Then have scripts and package lists based on these classes. If you needed
perfect classification, you could do it based on something unique to each
machine - say, the ethernet HW address. If their from different
manufacturers, often they'll have separate prefixes.
--
-----------------------------------------------------------------------
#include <disclaimer.h>
Matthew Palmer
mjp16 at ieee.uow.edu.au
More information about the linux-fai
mailing list