AIX- Devices
Devices information is stored in ODM. There are two device configuration databases in AIX
- Predefined Database contains data for all the supported devices based on the system configuration.
- Customized Database contains configuration database for all currently defined and configured (available) devices.
The devices in AIX can be in any of the following states
01. Available - Device is ready and can be used 02. Defined - Device is unavailable 03. Unknown - Undefined 04. Stopped - Configured but unavailable
To list the devices:
lsdev
-C to list customized database -P to list predefined database -c (class) -t (type) -s (subtype)
To list all customised devices ie installed
# lsdev -C
To list all the Hard Drives in a system
# lsdev -Cc disk
To list all the adapters in a sytem
# lsdev -Cc adapter
To find out the type of Fibre adapter
# lsdev -Ct df1000f* -F "type" -l fcs1
To find out the parent of ent0 device
# lsdev -Cl ent0 -F parent
To list the supported device classes from the Predefined Devices object class,
# lsdev -P -r class PCM adapter aio array bus cdrom ....... ......
To list the name, class, subclass, and type of every device in the
Available state in the Customized Devices object class with column
headers:
# lsdev -C -H -S a -F 'name class subclass type' name class subclass type sys0 sys node chrp sysplanar0 planar sys sysplanar_rspc mem0 memory sys totmem L2cache0 memory sys L2cache_rspc proc0 processor sys proc_rspc pci0 bus chrp pci pci1 bus chrp pci isa0 bus pci isac siota0 adapter isa_sio isa_tablet ppa0 adapter isa_sio chrp_ecp sa0 adapter isa_sio pnp501 sa1 adapter isa_sio pnp501 paud0 adapter isa_sio baud4232
To display configuration and vital product data (VPD) about the system:
lscfg
-v Displays the VPD found on customized Database -p display paltform specifig device info. -l <device_name>
To list all installed devices in detail
# lscfg -v
To find out the WWN, FRU #, firmware level of fibre adapter fcs0
# lscfg -vpl fcs0
# lscfg -vpl fcs0
lscfg -vpl fcs0 fcs0 U7879.001.DQDRDGG-P1-C4-T1 FC Adapter Part Number.................03N7069 EC Level....................A Serial Number...............1B64304D32 Manufacturer................001B Customer Card ID Number.....280B FRU Number.................. 03N7069 Device Specific.(ZM)........3 Network Address.............10000000C95C98D3 ROS Level and ID............02881955 Device Specific.(Z0)........1001206D Device Specific.(Z1)........00000000 Device Specific.(Z2)........00000000 Device Specific.(Z3)........03000909 Device Specific.(Z4)........FF801413 Device Specific.(Z5)........02881955 Device Specific.(Z6)........06831955 Device Specific.(Z7)........07831955 Device Specific.(Z8)........20000000C95C98D3 Device Specific.(Z9)........TS1.91A5 Device Specific.(ZA)........T1D1.91A5 Device Specific.(ZB)........T2D1.91A5 Device Specific.(ZC)........00000000 Hardware Location Code......U7879.001.DQDRDGG-P1-C4-T1 PLATFORM SPECIFIC Name: fibre-channel Model: LP10000 Node: fibre-channel@1 Device Type: fcp Physical Location: U7879.001.DQDRDGG-P1-C4-T1
To display attributes and possible values of attributes for devices:
lsattr
-E Displays the effective value -D Displays the Default Value -R Displays the range of legal values -a <Attribute> -l <Device_name>
Examples:
To find out the possible media_speed values for ethernet card ent0
# lsattr -El ent0 -a media_speed -R 10_Half_Duplex 10_Full_Duplex 100_Half_Duplex 100_Full_Duplex Auto_Negotiation
To find out the effective attribute of a device "mem0"
# lsattr -El mem0 goodsize 512 Amount of usable physical memory in Mbytes False size 512 Total amount of physical memory in Mbytes False
To list the defaults in the pre-defined db for device ent0
# lsattr -El sys0
To Change the attributes of devices:
-
chdev
-l <device name> -a <attribute=new_value> -T to change the value temporarily -P to make the change permanent after reboot if the device is currently in use and can not be changed
To change the SCSI ID of adapter scsi0 that cannot be changed made unavailable due to available disk drives connected to it
# chdev -l scsi0 -a id=6 -P
To change the maximum number of processes allowed per user
Find out the valid range of values using lsattr command # lsattr -l sys0 -a maxuproc -R 40...131072 (+1) Change the maxuproc value using chdev command # chdev -l sys0 -a maxuproc=10000
To remove the devices:
rmdev
-d removes the device from Customized DB -l <device_name> -R Unconfigure device and its chidren -S Makes deviec un-availabel by using stop method
To change device state from available to defined
# rmdev -l (device)
To delete the device
# rmdev -l (device) -d
To delete the scsi adapter scsi0 and all its child devices
# rmdev -Rdl scsi0
Add device to the system:
mkdev
-d define -c class -l <logical device name> -p parent name -s subclass -t type
Examples:
To define a tape device
# mkdev -d -c tape -t 8mm -s scsi -p scsi0 -w 5,0
To make the predefined rmt0 tape to available status
# mkdev -l rmt0
Configuring New Devices using cfgmgr:
cfgmgr configures devices and optionally installs device software by
running the programs specified in the Configuration Rules object class.
cfgmgr
-v To give detailed output -l <Device_name> To configure the device and all it's chidren -i <device> Location of installation medium
To search for new devices and configure them
#cfgmgr
To configure detected devices attached to the fcs0 adapter
# cfgmgr -l fcs0
To install device drivers which is in /tmp/drivers automatically during configuration
# cfgmgr -i /tmp/drivers
Getting System configuration variable values
getconf, bootinfo commands can be used to collect the system
configuration variable values such as kernel bit, hardware bit, boot
device, real mem present, disk size etc... bootinfo command is not
supported on Aix V5.2 onwards.
Using bootinfo command
To find out the Kernel whether it is 32-bit or 64bit# bootinfo -K ---- > for Kernel # bootinfo -y ---- > for Hardware # bootinfo -s hdiskx ----> to find out the size of the hard drive
Some useful getconf command examples
# getconf KERNEL_BITMODE 64 # getconf HARDWARE_BITMODE 64 # getconf DISK_SIZE /dev/hdisk0 8678 # getconf REAL_MEMORY 524288 # getconf BOOT_DEVICE hdisk0 # getconf DISK_DEVNAME hdisk0 10-60-00-4,0 # getconf MP_CAPABLE 0
Displaying system configuration information
prtconf command displays system Configuration information. If run
without any flags, it displays the system model, machine serial,
processor type, number of processors, processor clock speed, cpu type,
total memory size, network information, filesystem information, paging
space information, and devices information
Flags:-
-c Displays cpu type, for example, 32-bit or 64-bit. -k Display the kernel in use, for example, 32-bit or 64-bit. -L Displays LPAR partition number and partition name if this is an LPAR partition, otherwise returns "-1 NULL". -m Displays system memory. -s Displays processor clock speed in MHz. -v Displays the VPD found in the Customized VPD object class for devices.
Examples:-
# prtconf -c CPU Type: 64-bit # prtconf -m Memory Size: 4096 MB # prtconf -s Processor Clock Speed: 1654 MHz # prtconf System Model: IBM,9119-595 Machine Serial Number: 02898EB Processor Type: PowerPC_POWER5 Number Of Processors: 2 Processor Clock Speed: 1654 MHz CPU Type: 64-bit Kernel Type: 64-bit LPAR Info: 5 sapnims Memory Size: 4096 MB Good Memory Size: 4096 MB Platform Firmware level: Not Available Firmware Version: IBM,SF235_209 Console Login: enable Auto Restart: true Full Core: false Network Information Host Name: sapnims IP Address: 10.253.1.24 Sub Netmask: 255.255.255.0 Gateway: 10.253.1.253 Name Server: 128.137.24.4 Domain Name: gene.com Paging Space Information Total Paging Space: 512MB Percent Used: 1% Volume Groups Information rootvg: PV_NAME PV STATE TOTAL PPs FREE PPs FREE DISTRIBUTION hdisk0 active 546 1 00..00..00..00..01 hdisk1 active 546 1 00..00..00..00..01 ....................... ....................... ......................
List firmware and microcode level
lsmcode command display the firmware and microcode level
-A to list microcode information for all supported devices
-c To display levels without using menus
-r To display levels in tabular format
-d <device Name> to display mictocode level for a device
-A to list microcode information for all supported devices
-c To display levels without using menus
-r To display levels in tabular format
-d <device Name> to display mictocode level for a device
lsmcode -c The current permanent system firmware image is AM730_035 The current temporary system firmware image is AM730_035 The system is currently booted from the temporary firmware image. lsmcode -A sys0!system:AM730_035 (t) AM730_035 (p) AM730_035 (t) hba0!2514300014108c03.RR0120 hba1!2514300014108c03.RR0120 sissas0!53495320.04200029 sissas1!53495322.04220029 hdisk0!ST91468.A1700D26.43413036 hdisk1!ST91468.A1700D26.43413036 fcs0!df1000fe-0002.271315 fcs1!df1000fe-0002.271315
No comments:
Post a Comment