lscfg 명령어 (AIX 5.3·6.1)

핵심 정리

  • 시스템 장치의 이름, 위치 코드, 설명과 VPD(Vital Product Data: 부품 번호, 일련번호, EC 수준, 펌웨어 등)를 보여 줍니다.
  • lscfg(설치된 자원 목록), lscfg -vl 장치(그 장치의 VPD), lscfg -vp(펌웨어 장치 트리의 플랫폼 정보까지).
  • 자주 쓰는 형태: lscfg -vl fcs0 | grep "Network Address"(FC 어댑터 WWPN), lscfg -vl ent0(MAC 주소), lscfg -vl hdisk0(디스크 일련번호), lscfg -vpl sysplanar0(시스템 정보).
  • 장애 부품 교체를 요청할 때 위치 코드와 FRU 번호를 이 명령으로 확인합니다.
  • 장치마다 VPD가 다르며, VPD가 없는 장치도 있습니다.
항목 내용
버전 AIX 5.3, AIX 6.1 (두 버전의 내용이 같음)
원문 IBM Commands Reference — 5.3 Volume 3, 6.1 Volume 3
파일 /usr/sbin/lscfg
관련 명령어 lsdev, lsattr, prtconf, lsconn, lsparent, diag

목적

시스템의 구성, 진단, VPD(vital product data) 정보를 보여 줍니다.

영어 원문

Displays configuration, diagnostic, and vital product data (VPD) information about the system.

구문

text
lscfg [ -v ] [ -p ] [ -s ] [ -l Name ]

설명

플래그 없이 실행하면 현재 사용자 정의 VPD 객체 클래스에 있으면서 sys0 객체의 자식인 장치마다 이름, 위치, 설명을 보여 줍니다. 사용자 정의 장치 객체 클래스에서 missing으로 표시된 장치는 보여 주지 않습니다. 목록은 부모, 자식, 장치 위치 순으로 정렬됩니다. 특정 장치의 정보는 -l로 봅니다.

lscfg로 부품 번호, 일련번호, EC(engineering change) 수준 같은 VPD를 사용자 정의 VPD 객체 클래스나 플랫폼별 영역에서 볼 수 있습니다. 모든 장치에 VPD가 있지는 않습니다.

ME가 앞에 붙은 VPD는 진단 서비스 도구로 손으로 넣은 것입니다. 일부 장치는 메서드가 VPD를 장치에서 자동으로 모아 사용자 정의 VPD 객체 클래스에 넣습니다.

-p로 실행하면 플랫폼별 데이터 영역에 저장된 장치 정보를 보여 주고, -v와 함께면 그 장치의 VPD도 보여 줍니다. CHRP 시스템에서는 이 정보를 오픈 펌웨어 장치 트리에서 가져옵니다.

플래그 설명
-l Name 지정한 장치의 정보를 보여 줍니다.
-p 플랫폼별 장치 정보를 보여 줍니다.
-v 사용자 정의 VPD 객체 클래스의 VPD를 보여 줍니다. -p와 함께면 플랫폼별 VPD도 보여 줍니다.
-s 장치 설명을 이름·위치와 다른 줄에 보여 줍니다.
영어 원문

If you run the lscfg command without any flags, it displays the name, location and description of each device found in the current Customized VPD object class that is a child device of the sys0 object. It will not display any device that has been marked missing in the Customized Device Object Class. The list is sorted by parent, child, and device location. Information on a specific device can be displayed with the -l flag.

Use the lscfg command to display vital product data (VPD) such as part numbers, serial numbers, and engineering change levels from either the Customized VPD object class or platform specific areas. Not all devices contain VPD data.

VPD data that is preceded by ME signifies that the VPD data was entered manually using a diagnostic service aid. For some devices, the vital product data is collected automatically from the devices through methods and added to the Customized VPD object class.

If you run the lscfg command with the -p flag, it displays device information stored in the platform specific data areas. When used with the -v flag, VPD data stored for these devices is also displayed. This information is obtained on a Common Hardware Reference Platform (CHRP) system from the open firmware device tree.

  • -l Name — Displays device information for the named device.
  • -p — Displays the platform-specific device information.
  • -v — Displays the VPD found in the Customized VPD object class. Also, displays platform specific VPD when used with the -p flag.
  • -s — Displays the device description on a separate line from the name and location.

예제

  1. 시스템 구성을 봅니다.
bash
lscfg

출력 앞부분에 머리말과 기호 설명이 나옵니다. +는 진단 자원 목록에 더해진 자원(진단 파일 세트를 설치하면 기본으로 더해지며, 진단 작업을 하려면 목록에 있어야 함), -는 목록에서 지운 자원, *는 진단을 지원하지 않는 자원입니다. 목록에 더하고 지우는 일은 diag의 Task Selection 메뉴에서 합니다. +라도 모든 진단 작업을 지원하는 것은 아니며, Run Diagnostics 작업이 빠질 수도 있습니다.

text
INSTALLED RESOURCE LIST
...
  Model Architecture: chrp
  Model Implementation: Multiple Processor, PCI bus

+ sys0                                  System Object
+ sysplanar0                            System Planar
+ mem0                                  Memory
+ proc0          U1.1-P1-C1             Processor
* pci3           U0.2-P1                PCI Bus
+ scsi0          U0.1-P1/Z1             Wide/Ultra-2 SCSI I/O Controller
+ hdisk0         U1.1-P1/Z1-A9          16 Bit LVD SCSI Disk Drive (4500 MB)
  1. 설명을 이름·위치와 다른 줄에 보여 줍니다.
bash
lscfg -s
  1. 논리 이름이 proc로 시작하는 장치의 이름, 위치, 설명을 VPD 없이 봅니다.
bash
lscfg -lproc\*
text
proc0  U1.1-P1-C1  Processor
proc1  U1.1-P1-C1  Processor
...
proc7  U1.1-P1-C2  Processor
  1. ent0의 VPD를 봅니다.
bash
lscfg -v -l ent0
text
ent0  U0.1-P1-I2/E1  Gigabit Ethernet-SX PCI Adapter (14100401)
      Network Address.............0004AC7C00C4
      Displayable Message.........Gigabit Ethernet-SX PCI Adapter (14100401)
      EC Level....................E77998
      Part Number.................07L8916
      FRU Number..................07L8918
      Device Specific.(YL)........U0.1-P1-I2/E1
  1. ent0에 해당하는 오픈 펌웨어 장치 트리 노드의 VPD도 봅니다. 위 VPD 다음에 PLATFORM SPECIFIC 아래로 Name(ethernet), Model, Node(ethernet@1), Device Type(network), Physical Location이 나옵니다.
bash
lscfg -vp -lent0

자주 쓰는 형태:

bash
lscfg -vl fcs0 | grep "Network Address"   # FC 어댑터 WWPN(스토리지 존 설정용)
lscfg -vl ent0 | grep "Network Address"   # 이더넷 MAC 주소
lscfg -vl hdisk0                          # 디스크 모델·일련번호·위치 코드
lscfg -vpl sysplanar0 | more              # 시스템 보드와 펌웨어 정보
lscfg | grep -i "^\*"                     # 진단을 지원하지 않는 자원
영어 원문
  1. To display the system configuration, enter:
lscfg

The system displays a message similar to the following: INSTALLED RESOURCE LIST The following resources are installed on the machine: +/- = Added or deleted from Resource List. * = Diagnostic support not available.

+ indicates the resource has been added to the Diagnostic Resource List. The resource is added to the Diagnostic Resource list by default when the diagnostic fileset is installed. A resource must be in the Diagnostic Resource List before diagnostics tasks can be performed on the resource.

- indicates the resource was deleted from the Diagnostic Resource List.

The resource can be added or deleted from the Resource List by running the diag command, and using the Task Selection menu to select either Add Resource to Resource List, or Delete Resource from Resource List.

Diagnostic support for a resource, indicated by the + character is not necessarily inclusive of all diagnostic tasks. Some resources are only supported with a subset of diagnostic task, and that subset might or might not include the Run Diagnostics Task.

Model Architecture: chrp
Model Implementation: Multiple Processor, PCI bus

+ sys0 System Object + sysplanar0 System Planar + mem0 Memory + L2cache0 L2 Cache + proc0 U1.1-P1-C1 Processor * pci3 U0.2-P1 PCI Bus + scsi0 U0.1-P1/Z1 Wide/Ultra-2 SCSI I/O Controller + rmt0 U1.1-P1/Z1-A3 SCSI 4mm Tape Drive (12000 MB) + cd0 U1.1-P1/Z1-A5 SCSI Multimedia CD-ROM Drive (650 MB) + hdisk0 U1.1-P1/Z1-A9 16 Bit LVD SCSI Disk Drive (4500 MB) + fd0 U0.1-P1-D1 Diskette Drive .. ..

  1. To display the system configuration with the device description on a separate line, enter:
lscfg -s

The system displays a message similar to the following:

INSTALLED RESOURCE LIST

The following resources are installed on the machine:

+/- = Added or deleted from Resource List.
* = Diagnostic support not available.
 Model Architecture: chrp
 Model Implementation: Multiple Processor, PCI bus
+ indicates the resource has been added to the Diagnostic Resource List. The resource is
added to the Diagnostic Resource list by default when the diagnostic fileset is installed. A
resource must be in the Diagnostic Resource List before diagnostics tasks can be
performed on the resource.
- indicates the resource was deleted from the Diagnostic Resource List.
The resource can be added or deleted from the Resource List by running the diag
command, and using the Task Selection menu to select either Add Resource to Resource
List, or Delete Resource from Resource List.
Diagnostic support for a resource, indicated by the + character is not necessarily
inclusive of all diagnostic tasks. Some resources are only supported with a subset of
diagnostic task, and that subset might or might not include the Run Diagnostics Task.
+ sys0
       System Object
+ sysplanar0
       System Planar
+ mem0
       Memory
+ L2cache0
       L2 Cache
+ proc0 U5734.100.1234567-P1-C1
       Processor
+ proc1 U5734.100.1234567-P1-C2
       Processor
+hdisk0 U5734.100.1234567-P1-D9
     16 Bit LVD SCSI Disk Drive (4500 MB)
+fd0 U5734.100.1234567-P1-D1
     Diskette Drive
..
..
  1. To display the name, location, and description for devices specified by the logical name proc without VPD, enter:
lscfg -lproc\*

The system displays information for all devices with logical names beginning with proc, as follows:

proc0 U1.1-P1-C1 Processor
proc1 U1.1-P1-C1 Processor
proc2 U1.1-P1-C1 Processor
proc3 U1.1-P1-C1 Processor
proc4 U1.1-P1-C2 Processor
proc5 U1.1-P1-C2 Processor
proc6 U1.1-P1-C2 Processor
proc7 U1.1-P1-C2 Processor
  1. To display the VPD for a specific device specified by the logical name ent0, enter:
lscfg -v -l ent0

The system displays the following:

ent0 U0.1-P1-I2/E1 Gigabit Ethernet-SX PCI Adapter (14100401)
      Network Address.............0004AC7C00C4
      Displayable Message.........Gigabit Ethernet-SX PCI Adapter (14100401)
EC Level....................E77998
Part Number.................07L8916
FRU Number..................07L8918
Device Specific.(YL)........U0.1-P1-I2/E1
  1. To display the VPD in the open firmware device tree for the corresponding node to the ent0 device, enter:
lscfg -vp -lent0

The following is displayed:

ent0 U0.1-P1-I2/E1 Gigabit Ethernet-SX PCI Adapter (14100401)
     Network Address.............0004AC7C00C4
     Displayable Message.........Gigabit Ethernet-SX PCI Adapter (14100401)
     EC Level....................E77998
     Part Number.................07L8916
     FRU Number..................07L8918
     Device Specific.(YL)........U0.1-P1-I2/E1
PLATFORM SPECIFIC
Name: ethernet
 Model: Galaxy, EtherLink 1000-SX-IBM
 Node: ethernet@1
 Device Type: network
 Physical Location: U0.1-P1-I2/E1

파일

파일 설명
/usr/sbin/lscfg lscfg 명령
영어 원문
  • /usr/sbin/lscfg — Contains the lscfg command.

Related reference:

  • lsattr Command
  • lsconn Command
  • lsdev Command
  • lsparent Command

리눅스(GNU)와 다른 점

리눅스에는 ODM 같은 장치 구성 데이터베이스가 없고, 장치는 커널과 udev가 자동으로 인식합니다. 장치 목록은 lspci, lsusb, lsblk, lshw, ip link로, 속성은 /sys 아래 파일이나 udevadm info로 봅니다. 장치 다시 찾기는 echo "- - -" > /sys/class/scsi_host/host0/scan이나 rescan-scsi-bus.sh가 cfgmgr에 가깝습니다. VPD에 해당하는 정보는 dmidecode(시스템·보드 일련번호), lshw, lspci -vv, smartctl -i /dev/sdX(디스크 일련번호), cat /sys/class/fc_host/host*/port_name(FC WWPN)으로 봅니다.