Front | Info | Lists | Newsfeeds | Study Guide | What is BSD? |
|
This is the BSDA Study Guide Book written via a wiki collaboration. This is a work in progress. You may contribute to or discuss this specific page at http://bsdwiki.reedmedia.net/wiki/View_and_configure_system_hardware.html. Recognize the utilities used to view and configure system hardwareConceptBSD systems come with many utilities to determine what hardware is installed on a system. Know how to determine which hardware was probed at boot time as well as recognize utilities which can be used to troubleshoot and manipulate PCI, ATA, and SCSI devices on BSD systems. IntroductionWarning: The BSDA is not required to make changes to hardware devices, but should recognize what tools are available for this. As noted in some of the corresponding manual pages, some of the following utilities can cause a loss of data and/or server system crashes if used improperly. It is suggested that novice users stay away from some of these tools and even expert users are encouraged to exercise caution. On FreeBSD and DragonFly, the pciconf(8) tool can be used to read (and write) the PCI configuration register. The -l switch lists the devices found in the boot probe and the -v option will print identification strings (if found) for the vendor and device as found in the vendor/device information database. (TODO: make this more understandable for novice?) For example:
A similar tool on NetBSD for accessing the PCI bus is pcictl(8). For example:
FreeBSD and DragonFly provide a camcontrol(8) tool for interfacing with the CAM (Common Access Method) system. CAM provides a generic way to address I/O buses (such as IDE and USB) in a SCSI-like way. The following is an example of listing all the CAM devices:
Here is an example of sending a SCSI inquiry command for the da0 device:
This "inquiry" can be used to check RAID volumes for example. The camcontrol tool can "reset" devices that have become unresponsive (instead of rebooting system) and it can also "rescan" to find new attached devices. The camcontrol tool has numerous other features and many switches; run "camcontrol help" for details. On FreeBSD and DragonFly systems, IDE or EIDE devices can be controlled using the atacontrol(8) utility. It can be used to set modes (like UDMA33); delete, create, and rebuild RAID arrays; and other ATA operations. Use "atacontrol list" to list all attached ATA devices. The following example shows manufacturer and version information for the second device (count starts at 0):
This next example shows RAID details for the ar0 device:
ExamplesPractice ExercisesMore informationdmesg(8), /var/run/dmesg.boot, pciconf(8), atacontrol(8) and camcontrol(8); atactl(8) and /kern/msgbuf; scsictl(8) or scsi(8); pcictl(8)
|