728x90
반응형
T계열은 ILOM이 있는데 ILOM 접속 후 전력소비량을 볼 수 가 있다.

1. 전원 사용 관리 및 전력 소비량 모니터링
▼ 전원 관리 등록 정보 보기(CLI)
● -> 프롬프트에서 다음 명령을 입력합니다.

-> show /SP/powermgmt

/SP/powermgmt
Targets:
     Properties:
actual_power = 202
permitted_power = 762
available_power = 762

Commands:
     cd
          create
delete
set
show


설명
구분의미
actual_power
시스템의 모든 전원 공급 장치가 소모하는 입력 전력(W)을 표시합니다.
permitted_power
예상되는 최대 전력 소모량(W)을 표시합니다.
available_power
시스템 구성 요소가 이용할 수 있는 입력 전력량(W)을 표시합니다.



 2. 시스템이 소비한 전체 전력 보기 

▼ 시스템이 소비한 전체 전력 보기(CLI)
/SYS/VPS 값은 다음 명령의 값과 같습니다. show /SP/powermgmt actual_power
/SP/powermgt actual_power 등록 정보는 /SYS/VPS가 임계값이 있는 센서이고
actual_power가 센서에 의해 반환된 값이라는 점에서 /SYS/VPS와 같습니다.


-> show /SYS/VPS

/SYS/VPS
Targets:
Properties:
type = Power Unit
class = Threshold Sensor
value = 202 Watts
upper_nonrecov_threshold = 780.00 Watts
upper_critical_threshold = 705.00 Watts
upper_noncritical_threshold = 625.00 Watts
lower_noncritical_threshold = N/A
lower_critical_threshold = N/A
lower_nonrecov_threshold = N/A
Commands:
cd
show

설명
구분의미
typePower Unit
classThreshold Sensor
valueTotal cansumed power in watts
upper_nonrecov_threshold100% of /SP/powermgmt available_power
upper_critical_threshold90% of /SP/powermgmt available_power
upper_noncritical_threshold80% of /SP/powermgmt available_power



728x90
반응형
728x90
반응형
유닉스와 리눅스 부팅 및 런레벨

유닉스 부팅 순서
순서
부팅 과정
정의
01
Power On
 
02
Boot PROM
POST(Power On Self Test) - 디바이스 정보와 장치 점검
부팅장치 설정
VTOC 확인
※ VTOC :디스크 섹터0번에 Partition Table을 확인한다.
1~15 Sertor에는 bootblk 프로그램의 위치를 가르키는 포인터가 있는데, 로더 시킨다. bootblk는 유닉스에서 쓰는 boot loder중 하나이다.
03
Boot Program
ufs boot : 커널에서 모듈을 읽을 수 있게 하는 boot 파일이다. 이 과정에서 메모리에 적재한다.
genunix, unix : 두 개를 합쳐 커널을 생성하고, 메모리에 적재한다.
04
커널 초기화
/etc/system 디렉토리를 참조하여 초기화를 시킨다.
※ /etc/system 디렉토리는 커널의 파라미터와 정보값이 저장되어 있다.
ufsboot를 이용한 장치 초기화
PID 0번인 sched가 로드되고, sched가
PID 1번인 init 프로세스를 메모리에 로더 시킨다.
05
init 프로세스 동작
svc.startd 에 정의되어 동작
06
svc.startd
milestone에서 해당 레벨로 부팅




리눅스 부팅 순서
순서
부팅 과정
정의
01
Power On
 
02
ROM BIOS
POST(Power On Self Test) - 디바이스 정보와 장치 점검
부팅장치 설정
VTOC, MBR(Master Boot Recode) 확인
※ 디스크 섹터0번에 VTOC, MBR의 위치가 들어있다.
03
GRUB
커널의 이미지를 선택하여 메모리에 적재시킨다.
GRUB의 위치는 /etc/vmlinuz버전.img 에 정의되어 있다.
04
커널 이미지 적재
‘/ ’파일시스템을 Read Only로 마운트하여 테스트 과정을 거치고 난 뒤
정상적으로 Read/Wirte 권한으로 마운트하여 장치 드라이버를 설정한다.
05
Swapper 생성
커널에 의해서 PID 0번인 Swapper 프로세스가 생성된다.
06
init 생성 및 커널부팅, 초기화
Swapper 프로세스가 PID 1번인 init 프로세스를 생성시키고, init 프로세스는 /etc/inittab 파일에 default 런레벨이 정의되어 있고 해당 런 레벨로 부팅 시 /etc/rc.d/rc.sysinit 스크립트가 실행되어 커널을 초기화 시킨 다음 정상적으로 부팅 완료된다.

일반적인 OS 기본적 부팅 순서
순서
부팅 과정
정의
01
Power On
 
02
BIOS
PROM 안에 들어있는 POST(Power On Self Test): 하드웨어 자가 테스트 실행한다. BIOS에서 지정된 부팅장치에서 부트 프로그램을 메모리 상에 적재한다.
03
Boot Program
(Boot Loader)
운영체제가 동작하기 전 반드시 동작하여야하고, 디스크 앞쪽에 반드시 있어야한다. 역할은 커널의 위치를 메모리에 적재시킨다. 대표적으로 리눅스는 GRUB, 윈도우는 NTLDR, WINLOAD이 있다.
04
Kernel 초기화
초기화를 시키고, 커널이 어떻게 동작할 것인지를 결정한다.
05
서비스 동작
해당 런레벨에 따라 어떤 서비스를 동작시킬 것인지를 결정하고 백그라운드로 동작시킨다.


유닉스 런레벨 정의
실행레벨
의미
0
시스템을 BIOS 상태로 부팅, 종료
1
single mod로 부팅되는데 모든 파일시스템을 마운트
S
중요한 파일시스템만 마운트
2
NFS를 지원하지 않는 다중 사용자 모드
3
네트워킹을 지원하는 다중 사용자 모드
4
사용자가 정의해서 쓸 수 있는 실행레벨
5
시스템 종료
6
시스템을 재부팅시키도록 정의된 실행레벨


리눅스 런레벨 정의(cat /etc/inittab)
실행레벨
의미
0
시스템 종료
1
single mod로 부팅
2
NFS를 지원하지 않는 다중 사용자 모드
3
네트워킹을 지원하는 다중 사용자 모드
4
사용자가 정의해서 쓸 수 있는 실행레벨
5
X를 실행시키기 위한 실행레벨(GUI지원)
6
시스템을 재부팅시키도록 정의된 실행레벨

  


728x90
반응형
728x90
반응형

대략적인 개념만 잡기를 바라며, 이 글을 보고 한번도 안해본 사람이 설정을 할 수는 없을것이다.


반드시 Solaris 전문 엔지니어에게 도움을 받길 바라며, 본 문은 서버 담당자 혹은 엔지니어가 대략적인 개념을 잡기 위한 글임을 밝혀 둔다.




- 목차
1. M10-1 설치
1.1 XSCF 구성
1.2 Core License 등록
1.3 OS 설치 및 EIS설치
1.4 M10-1 Domain 제어

2. OVM 3.0 구성
2.1 OVM 설치
2.2 OVM 구성
  1) 컨트롤 Domain 구성
  2) VM Domain 구성
  3) Domain 구성 정보 저장
  4) VM Domain 제어
2.3 OVM 삭제
  1) VM 삭제
  2) OVM Config 삭제 및 시스템 초기화
  3) OVM PKG 삭제



1.     M10-1 설치

1.1 xscf 구성
localhost login: default 
Change the panel mode switch to Locked and press return...
Leave it in that position for at least 5 seconds.  Change the panel mode switch to Service, and press return...

XSCF> adduser xscf
XSCF> password xscf
xscPassword: xscf
BAD PASSWORD: it is too short
BAD PASSWORD: is too simple
Retype new password: xscf
passwd: password updated successfully
XSCF> setprivileges xscf fieldeng useradm platadm

XSCF> showboards -a
PSB  PPAR-ID(LSB) Assignment  Pwr  Conn Conf Test    Fault   
---- ------------ ----------- ---- ---- ---- ------- --------
00-0 00(00)       Assigned    n    n    n    Unknown Normal  

XSCF> shownetwork -a
bb#00-lan#0
          Link encap:Ethernet  HWaddr B0:99:28:A1:47:99 
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Base address:0xa000

bb#00-lan#1
          Link encap:Ethernet  HWaddr B0:99:28:A1:47:9A 
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Base address:0x2000

XSCF> setnetwork -m 255.255.255.0 bb#00-lan#0 192.168.200.1
XSCF> applynetwork
The following network settings will be applied:
  bb#00 hostname   :
  DNS domain name  :

  interface        :bb#00-lan#0
  status           :up
  IP address       :192.168.200.1
  netmask          :255.255.255.0
  route            :

  interface        :bb#00-lan#1
  status           :down
  IP address       :
  netmask          :
  route            :

Continue? [y|n] :y
Please reset the all XSCFs by rebootxscf to apply the network settings.
Please confirm that the settings have been applied by executing
showhostname, shownetwork, showroute, showsscp and shownameserver after
rebooting the all XSCFs.

XSCF> settelnet -c enable
Continue? [y|n] :y

XSCF> sethttps -c selfsign kr daejeon fkl fkl fkl fkl sbwkon@kr.fujitsu.com
CA key and CA cert already exist. Do you still wish to update? [y|n] :y
Enter passphrase:Enter

XSCF> sethttps -c enable
The web serverkey or web server certificate which has been signed by an external certification authority does not exist.
Created self-signed certificate for HTTPS service.Continue? [y|n] :y

XSCF> rebootxscf -y -a
The XSCF will be reset. Continue? [y|n] :y

localhost login: xscf
Password: xscf

XSCF> showdomainstatus -p 0
Logical Domain Name   Status
primary               Host Stop

XSCF> showdomainconfig -p 0
PPAR-ID     :0
Booting config
(Current)  :factory-default
(Next)     :factory-default
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-
XSCF> poweron -p 0
PPAR-IDs to power on :00
Continue? [y|n] :y
00 : Not powering on : Poweron canceled due to missing component.

XSCF> console -p 0
Console contents may be logged.
Connect to PPAR-ID 0?[y|n] :y



1.2 Core License 등록
menu-> setting -> Cod Activation(장비에 사용할 core 라이센스등록) -> Cod Reservation(파티션에서 사용할 Core 라이센스 등록)
1. https://192.168.1.10(xscf LAN IP)
아이디 : xscf 패스워드 : xscf




2. Cod Activation(장비에 사용할 core 라이센스등록)
menu-> setting -> Cod Activation




3. -> Cod Reservation(파티션에서 사용할 Core 라이센스 등록)
** OVM의 경우 콘트롤러 도메인에 모든 코어를 할당
** 라이센스의 경우 다른 장비의 라이센스로 활성화 및 사용가능
** M10-1의 최소 Core는 4Core이며 최대 16Core 임
**Core는 2Core 단위로 증설 가능



4. Core 확인 방법

1) OS 확인 방법
OS의 경우 thead 때문에 core당 vcpu가 2개로 인식 됨(4Core의 경우 8개의 vcpu로 인식 됨)
[test:/fkl]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary             active     -n-c--   UART      8     30976M   0.1%  1h 56m

[test:/fkl]prtdiag -v | more
System Configuration:  Oracle Corporation  sun4v SPARC M10-1
================================ 가상 CPU ================================
CPU ID Frequency Implementation         Status
------ --------- ---------------------- -------
0      2800 MHz  SPARC64-X              on-line 
1      2800 MHz  SPARC64-X              on-line 
2      2800 MHz  SPARC64-X              on-line 
3      2800 MHz  SPARC64-X              on-line 
4      2800 MHz  SPARC64-X              on-line 
5      2800 MHz  SPARC64-X              on-line 
6      2800 MHz  SPARC64-X              on-line 
7      2800 MHz  SPARC64-X              on-line



2) XSCF 확인 방법
XSCF> showhardconf -M         ================>> 장비 전체 Core는 확인 가능하지만 활성화된 Core는 확인 불가
SPARC M10-1;
    + Serial시리얼넘버 삭제; Operator_Panel_Switch:Service;
    + System_Power:On; System_Phase:Cabinet Power On;
    Partition#0 PPAR_Status:Running;
    MBU Status:Normal; Ver:2070h; Serial:TZ1342B00H  ;
        + FRU-Part-Number:CA07363-D001 A1   /7060744              ;
        + Power_Supply_System: ;
        + Memory_Size:32 GB;
        CPU#0 Status:Normal; Ver:4142h; Serial:00520796;
            + Freq:2.800 GHz; Type:0x10;
            + Core:16; Strand:2;
        MEM#00A Status:Normal;
            + Code:2c800f18KSF1G72PZ-1G6E2 4532-E2AFA9D4;
            + Type:04; Size:8 GB;
        MEM#01A Status:Normal;
            + Code:2c800f18KSF1G72PZ-1G6E2 4532-E2AFA9C1;
            + Type:04; Size:8 GB;
        MEM#02A Status:Normal;
            + Code:2c800f18KSF1G72PZ-1G6E2 4532-E2AFAB3C;
            + Type:04; Size:8 GB;
        MEM#03A Status:Normal;
            + Code:2c800f18KSF1G72PZ-1G6E2 4532-E2AFAB3F;
            + Type:04; Size:8 GB;
    PCI#0 Name_Property:network;
        + Vendor-ID:8086; Device-ID:1521;
        + Subsystem_Vendor-ID:108e; Subsystem-ID:7b18;
        + Model:SUNW,pcie-igb;
    PCI#2 Name_Property:network;
        + Vendor-ID:8086; Device-ID:1521;
        + Subsystem_Vendor-ID:108e; Subsystem-ID:7b18;
        + Model:SUNW,pcie-igb;
    OPNL Status:Normal; Ver:0101h; Serial:TZ1337F04H  ;
        + FRU-Part-Number:CA07363-D101 A0   /7060786              ;
    PSUBP Status:Normal; Ver:0101h; Serial:TZ1334P02Q  ;
        + FRU-Part-Number:CA20366-B15X 001AA/7065594              ;
    PSU#0 Status:Normal; Ver:533246h; Serial:FJPD1323001754;
        + FRU-Part-Number:CA01022-0750-M/7060781    ;
        + Power_Status:ON; AC:200 V;
    PSU#1 Status:Normal; Ver:533246h; Serial:FJPD1333003597;
        + FRU-Part-Number:CA01022-0750-M/7060781    ;
        + Power_Status:ON; AC:200 V;
    FANU#0 Status:Normal;
    FANU#1 Status:Normal;
    FANU#2 Status:Normal;
    FANU#3 Status:Normal;
    FANU#4 Status:Normal;
    FANU#5 Status:Normal;
    FANU#6 Status:Normal;

XSCF> showcodactivation           
Index   Description Count
------- ----------- ------
      0 PROC            2
      1 PROC            2  ================>> 4개의 Core 확인

XSCF> showcodactivationhistory
11/28/2013 08:53:51AM UTC: Report Generated M10-1 SN: 시리얼넘버 삭제
11/25/2013 04:21:17AM UTC: Activation history initialized: PROC 4 cores
11/28/2013 08:53:51AM UTC: Summary: PROC 4 cores         ================>> 4개의 Core 확인
Signature: 시그니쳐 삭제


1.3 컨트롤 도메인 OS 설치 및 EIS 설치

** M10-1의 경우 전면 부 앞에 있는 USB에 외장 CD-rom및 usb cdrom 인식가능
** OS 설치 후 디스크 WWN에 따라 format에 디스크 번호가 나열되기 때문에 Slot0번 디스크만 인식 후에 설치를 권장 함.
** Solaris10 U11의 경우 버그로 인해 설치 미디어를 CD-ROM으로 반드시 지정해야 함 선택 후 되 되돌아 오기 불가
** Solaris10 U11의 경우 인터널 디스크에 OS 설치 시 비 iscsi Disk로 선택
1. 처음 설치 시 OS에 Freeinstall이 되어있기 때문에 send break 명령어를 통해 OK 프롬프트로 변경
XSCF> sendbreak -p 0
Send break signal to PPAR-ID 0?[y|n] :y
2. EIS 설치 방법
[test:/fkl]lofiadm -a /fkl/ EIS-DVD-ONE-04SEP13.iso
/dev/lofi/1
[test:/fkl]mount -F hsfs /dev/lofi/1 /mnt
[test:/mnt/sun/install]./setup-standard.sh
Is the power saving daemon to be disabled? [y/n]: y
Sun keyboard Power button to be disabled? [y/n]: y
Are the buttons & dials to be disabled? [y/n]: y
Are remote root logins via SSH to be allowed? [y/n]: y
Is the existing IPMITOOL to be replaced by version 1.8.10.4? [y/n]: y
충돌하는 파일을 설치하겠습니까? [y,n,?,q] y
Should Explorer create /opt/SUNWexplo/output (y/n)?
[y]:
Company name
[]: axa
Contract Identifier
[]:
System (test, 90070836) serial number
[PZ31346010]:
Contact name
[]:
Contact email address
[]:
Phone number
[]:
Address (line 1)
[]:
Address (line 2)
[]:
City
[]:
State
[]:
Zip
[]:
Select your geography from this list:
    1) AMERICAS
    2) EMEA
    3) APAC
[AMERICAS] 3
APAC
Two-character country code or '?' for a list of countries
[]: kr
(SFT) listener
[]: yes
When a proxy server is not needed, enter a single '-'.
[]: -

If you would like to be notified by email when your explorer output is uploaded
into the repository, enter the email address here. When notification is not
needed, enter a single '-'.
[]: -
Are these values okay (y/n)?
[]: y
Do you wish to schedule explorer in cron (y/n)?
[]: n
[test:/]. ./.profile-EIS
root@test # cd /mnt
root@test # cd sun
root@test # ls
docs     install  patch    progs    tools
root@test # cd /mnt/sun/patch/10
root@test # unpack-patches /fkl/20131127/
Are you ready to unpack patches into /fkl/20131127//10? [y/n]: y
root@test # cd /fkl/20131127/10
root@test # install_all_patches
Are you ready to continue with install? [y/n]: y
root@test # reboot






1.4 M10-1 Domain 제어
1. Domain 상태 확인
XSCF> showdomainstatus -p 0
Logical Domain Name   Status
primary               Solaris running
2.도메인 설정 확인
XSCF> showdomainconfig -p 0          ================>> OVM 구성시 도메인 설정이 xscf에 등록 됨
PPAR-ID     :0
Booting config
(Current)  :factory-default
(Next)     :factory-default
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-

3.도메인 전원 on/off
1) 전원 ON
XSCF> poweron -p 0
PPAR-IDs to power on :00
Continue? [y|n] :y
XSCF> poweron -a  
PPAR-IDs to power on :00
Continue? [y|n] :

4)전원 off
XSCF> poweroff -p 0
PPAR-IDs to power on :00
Continue? [y|n] :y
XSCF> poweroff -a  
PPAR-IDs to power on :00
Continue? [y|n] :y

4. 도메인 접속
XSCF> console -p 0
Console contents may be logged.
Connect to PPAR-ID 0?[y|n] :y
console already used by other user.
XSCF> console -f -p 0
Console contents may be logged.
Connect to PPAR-ID 0?[y|n] :y
test console login:

5.도메인 접속 종료
OS에서 #.(키보드 키(#) 키(.)을 동시에 입력하면 됨


2. OVM 3.0 구성
     2.1 OVM 설치
1. OVM3.0 설치
[test:/]pkginfo |grep SUNWldm*
system      SUNWldomr                        Solaris Logical Domains (Root)
system      SUNWldomu                        Solaris Logical Domains (Usr)

[test:/fkl/install]unzip p15880570_30_SOLARIS64.zip
[test:/fkl/install/OVM_Server_SPARC-3_0/Install]./install-ldm
y) Yes, launch the Configuration Assistant after install
n) No thanks, I will configure the system manually later

Enter y or n [y]: n                  =========================>> 패키지 설치 후 OVM을 수동 구성하려면 n

2. OVM 패치 설치
[test:/fkl/install]unzip 150011-03.zip
[test:/fkl/install]patchadd 150011-03

3. 설치 확인
[test:/fkl/install/OVM_Server_SPARC-3_0/Install]pkginfo |grep SUNWldm* ==========>> 설치된 PKG 확인
application SUNWldm                          LDoms Manager software  ===========>> OVM PKG
application SUNWldmp2v                       LDoms P2V too           l===========>> OVM PKG
system      SUNWldomr                        Solaris Logical Domains (Root)
system      SUNWldomu                        Solaris Logical Domains (Usr)

/[test:/fkl/install/OVM_Server_SPARC-3_0/Install]ldm ls        ========================>> OVM 데몬 확인
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary             active     -n-c--    UART     8     30976M   0.3%  22m

**4Core이기 때문에 Vcpu가 8개로 확인되며 Guest 도메인을 생성하기 전이기 때문에 모든 자원이 컨트롤 도메인 시스템에 할당 됨


2.2 OVM 구성
     1) 컨트롤 Domain 구성
<인터널 디스크 확인>
[test:/]diskinfo -a  =========================>> SAS 디스크의 경우 WWN 넘버에 의해 format에서 디스크 넘버가 결정 됨으로 diskinfo 명령어를 통한 H/W Slot 넘버를 확인
Enclosure path:         PZ31346010-physical-hba-0
Chassis Serial Number:  PZ31346010-physical-hba-0
Chassis Model:          ORCL,SPARC64-X
Enclosure path:         /dev/es/ses0
Chassis Serial Number:  500000e0e04a787f
Chassis Model:          FUJITSU-NBBEXP

Label      Disk name               Vendor   Product          Vers
---------- ----------------------  -------- ---------------- ----
HDD_0      c0t500003950818606Ed0   TOSHIBA  MBF2600RC        3706
HDD_1      c0t50000395081860EAd0   TOSHIBA  MBF2600RC        3706
[test:/]
[test:/fkl/script]sh -x 0.primary.sh   ================>> 구성 정보의 보존을 위해 스크립트 파일을 서버에 보존 함
"0.primary.sh" 80 행, 4999 문자
#!/bin/sh
# 제어도메인 구축 스크립트

# 디스크 볼륨 참고
#c21t60080E500037DAC2000004DC51B7E911d0   <--- primary1 용 277.99GB (sl-search)
#c21t60080E500037D9260000050551B7EA94d0   <--- primary1 용 277.99GB (sl-intweb)
#c21t60080E500037DAC2000004DF51B7EAB7d0   <--- primary1 용 277.99GB (sl-intwas)
#c21t60080E500037D9260000050851B7EAB8d0   <--- primary1 용 277.99GB (sl-extwas)
#c21t60080E500037DAC2000004E151B7EABDd0   <--- primary1 용 277.99GB (sl-db)
#

CONFIG=config_initial     # 시스템콘트롤러에 보존하는 구성명
VCPU=4                   # 제어도메인에 할당하는 가상 CPU수 (Threads), 최소 2Core 이상(4CPU)
MAU=0                     # 제어도메인에 할당하는 암호화유닛수
MEM=8192M                 # 제어도메인에 할당하는 메모리 (K:KB,M:MB,G:GB), 최소 4GB 이상

ldm start-reconf primary
ldm set-mau $MAU primary
ldm set-vcpu $VCPU primary
ldm set-memory $MEM primary

# IO Domain용 IO제거 작업 (ldm list-io 명령어로 확인)
#ldm remove-io pci@500/pci@1/pci@0/pci@6 primary # HBA(PCI#7) <-- 슬롯별 제거
#ldm remove-io pci@500/pci@1/pci@0/pci@5 primary # OnBoard NIC (igb2,3) <-- 슬롯별 제거
#ldm remove-io PCIE2 primary                      # Remove (PCIE2) , sl-db1 에서 사용

# 가상디스크서버를 정의합니다.
ldm add-vdiskserver primary-vds0 primary

# 가상디스크서비스에 OS의 iso이미지(OS CD)를 read only 로 추가합니다.
ldm add-vdiskserverdevice options=ro /Ldoms/ISO/Sol10U11.iso ldom1_cdvol0@primary-vds0 # sl-search CD-ROM ()
ldm add-vdiskserverdevice options=ro /Ldoms/ISO/Sol10U11.iso ldom2_cdvol0@primary-vds0 # sl-intweb CD-ROM ()
ldm add-vdiskserverdevice options=ro /Ldoms/ISO/Sol10U11.iso ldom3_cdvol0@primary-vds0 # sl-intwas CD-ROM ()
ldm add-vdiskserverdevice options=ro /Ldoms/ISO/Sol10U11.iso ldom4_cdvol0@primary-vds0 # sl-extwas CD-ROM ()
ldm add-vdiskserverdevice options=ro /Ldoms/ISO/Sol10U11.iso ldom5_cdvol0@primary-vds0 # sl-db CD-ROM ()

# 가상디스크서버디바이스를 정의하고 실체를 지정합니다. (Guest Domain에서 사용할 Disk 정의)
ldm add-vdiskserverdevice /dev/dsk/c21t60080E500037DAC2000004DC51B7E911d0s2 ldom1_vol0@primary-vds0  # sl-search OS Disk ()
ldm add-vdiskserverdevice /dev/dsk/c21t60080E500037D9260000050551B7EA94d0s2 ldom2_vol0@primary-vds0  # sl-intweb OS Disk ()
ldm add-vdiskserverdevice /dev/dsk/c21t60080E500037DAC2000004DF51B7EAB7d0s2 ldom3_vol0@primary-vds0  # sl-intwas OS Disk ()
ldm add-vdiskserverdevice /dev/dsk/c21t60080E500037D9260000050851B7EAB8d0s2 ldom4_vol0@primary-vds0  # sl-extwas OS Disk ()
ldm add-vdiskserverdevice /dev/dsk/c21t60080E500037DAC2000004E151B7EABDd0s2 ldom5_vol0@primary-vds0  # sl-db OS Disk ()
##### DX8700S2 ##########
#ldm add-vdiskserverdevice /dev/dsk/c21t600000E00D1000000010314400000000d0s2 ldom1_vol1@primary-vds0  # sl-serch irs Disk ()
#ldm add-vdiskserverdevice /dev/dsk/c21t600000E00D1000000010314400010000d0s2 ldom1_vol2@primary-vds0  # sl-serch irs Disk ()
"0.primary.sh" 80 행, 4999 문자
#ldm add-vswitch net-dev=igb9 primary-vsw9 primary # direct I/O (sl-db1)
#ldm add-vswitch net-dev=igb10 primary-vsw10 primary # sl-search NIC#1 (192.168.2.x)
#ldm add-vswitch net-dev=igb11 primary-vsw11 primary # sl-intweb NIC#1 (192.168.2.x)
#ldm add-vswitch net-dev=igb12 primary-vsw12 primary # sl-extwas NIC#0 (192.168.2.x)
#ldm add-vswitch net-dev=igb13 primary-vsw13 primary # ldom1 NIC (192.168.2.x)
ldm add-vswitch net-dev=igb14 primary-vsw14 primary # sl-extwas NIC#1 (192.168.2.x)
#ldm add-vswitch net-dev=igb15 primary-vsw15 primary # ldom1 NIC (192.168.2.x)
#ldm add-vswitch net-dev=igb16 primary-vsw16 primary # sl-intwas NIC#0 (192.168.2.x)
#ldm add-vswitch net-dev=igb17 primary-vsw17 primary # ldom1 NIC (192.168.2.x)
#ldm add-vswitch net-dev=igb18 primary-vsw18 primary # sl-intwas NIC#1 (192.168.2.x)
#ldm add-vswitch net-dev=igb19 primary-vsw19 primary # ldom1 NIC (192.168.2.x)

# 가상콘솔단말집배신장치서비스와 할당하는 포트의 범위를 지정합니다.
ldm add-vconscon port-range=5000-5100 primary-vcc0 primary

# 구성을 시스템콘트롤러에 보존합니다.
eeprom auto-boot\?=false
ldm add-spconfig $CONFIG
#ldm add-spconfig -r $CONFIG
# 본 스크립트 실행 후는 전원절단, 재투입 또는 리셋이 필요합니다.

ldm list-constraints -x > /Ldoms/Domains/alldomains.xml.`date +%y%m%d%H%M%S`
**스크립트 실행 후 리부팅 필요

2) 스크립트 실행 후 구성 정보 확인

<컨트롤러 도메인 변경 전 구성 정보>
[test:/]ldm ls                
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary            active        -n-c--  UART     8      30976M   0.1%  28m
** 모든 CPU 및 메모리가 Primary Domain에 할당 되어 있음을 확인할 수 있음
[test:/]ldm ls-devices
CORE
     ID      %FREE   CPUSET                                
     16      100    (32, 33)
     20      100    (40, 41)
     24      100    (48, 49)
     28      100    (56, 57)
     32      100    (64, 65)
     36      100    (72, 73)
     40      100    (80, 81)
     44      100    (88, 89)
     48      100    (96, 97)
     52      100    (104, 105)
     56      100    (112, 113)
     60      100    (120, 121)

VCPU
     PID     %FREE 
     32      100   
     33      100   
     40      100   
     41      100   
     48      100   
     49      100   
     56      100   
     57      100   
     64      100   
     65      100   
     72      100   
     73      100   
     80      100   
     81      100   
     88      100   
     89      100   
     96      100   
     97      100   
     104     100   
     105     100   
     112     100   
     113     100   
     120     100   
     121     100   

MEMORY
     PA                   SIZE          
     0x7e0060800000       248M  ===============>> VM에 할당 가능한 메모리
[test:/]ldm list-config
factory-default[Current]

<컨트롤러 도메인 구성 변경 후 정보>
[test:/]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.3%  9m
[test:/]ldm ls-devices
CORE
     ID      %FREE   CPUSET                                
     8       100    (16, 17)
     12      100    (24, 25)
     16      100    (32, 33)
     20      100    (40, 41)
     24      100    (48, 49)
     28      100    (56, 57)
     32      100    (64, 65)
     36      100    (72, 73)
     40      100    (80, 81)
     44      100    (88, 89)
     48      100    (96, 97)
     52      100    (104, 105)
     56      100    (112, 113)
     60      100    (120, 121)

VCPU
     PID     %FREE 
     16      100   
     17      100   
     24      100   
     25      100   
     32      100   
     33      100   
     40      100   
     41      100   
     48      100   
     49      100   
     56      100   
     57      100   
     64      100   
     65      100   
     72      100   
     73      100   
     80      100   
     81      100   
     88      100   
     89      100   
     96      100   
     97      100   
     104     100   
     105     100   
     112     100   
     113     100   
     120     100   
     121     100   

MEMORY
     PA                   SIZE          
     0x7e0160800000       27128M        ==================>> 4G를 제외한 메모리를 VM으로 할당 가능

[test:/]ldm list-config
factory-default
config_initial [current]
[test:/]ls /Ldoms/Domains/*
/Ldoms/Domains/alldomains.xml.131204094917
[test:/]



2.2 OVM 구성
     2) VM Domain 구성

1. VM 도메인 설정

[test:/fkl/script]sh -x 1.ldom1.sh ================>> 구성 정보의 보존을 위해 스크립트 파일을 서버에 보존 함
"1.ldom1.sh" 42 행, 1465 문자
#!/bin/sh
# 게스트 도메인 구축 스크립트

DOMAIN=test-vm  # 도메인명
VCPU=4            # 도메인에 할당하는 가상 CPU 수 (Threads)
MAU=0              # 도메인에 할당하는 암호화 유닛수
MEM=24G            # 도메인에 할당하는 메모리(K:KB,M:MB,G:GB)

VNET0=primary-vsw3
VNET1=primary-vsw7
VDISK0=ldom1_vol0@primary-vds0
VISO=ldom1_cdvol0@primary-vds0
VCONS="port=5001"

ldm add-domain $DOMAIN
ldm set-mau $MAU $DOMAIN
ldm add-vcpu $VCPU $DOMAIN
ldm add-memory $MEM $DOMAIN
ldm add-vnet linkprop=phys-state vnet0 $VNET0 $DOMAIN
ldm add-vnet linkprop=phys-state vnet1 $VNET1 $DOMAIN
ldm add-vdisk timeout=10 vdisk0 $VDISK0 $DOMAIN
ldm add-vdisk cdvol $VISO $DOMAIN
ldm set-vcons $VCONS $DOMAIN

# 네트워크인스톨을 위해 도메인기동시에 자동디스크부트하지 않도록 지정합니다.
ldm set-variable auto-boot\?=false $DOMAIN
#ldm set-variable boot-device=vdisk0 $DOMAIN

# 이하를 실행하면 도메인은 기동상태(active)로 됩니다.
ldm bind-domain $DOMAIN
ldm start-domain $DOMAIN

# 이하를 실행하면 도메인의 구성정보를 보존합니다.
# 보존한 구성정보는 이하의 커맨드의 입력으로써 이용할 수 있습니다.
# ldm add-domain -i
ldm list-constraints -x $DOMAIN > /Ldoms/Domains/$DOMAIN.xml
cp /Ldoms/Domains/$DOMAIN.xml /Ldoms/Domains/$DOMAIN.xml.`date +%y%m%d%H%M%S`

# 이하를 실행하면 도메인의 가상네트워크의 Ethernet address 를 출력합니다.
# ok 프롬프트에서 표시되는 Ethernet address 는 가상네트워크디바이스의 어드레스가 아닙니다.
ldm ls -e $DOMAIN|grep vnet|cut -d@ -f3|xargs -L 1 echo vnet
#reboot    ========================================>> 리부팅 이후 설정이 적용 됨

<적용된 구성 정보를 확인>
[test:/fkl/script]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.1%  18m
test-vm          active     -t----  5001    4     24G       25%  11s
[test:/fkl/script]ldm ls-devices
CORE
     ID      %FREE   CPUSET                                
     16      100    (32, 33)
     20      100    (40, 41)
     24      100    (48, 49)
     28      100    (56, 57)
     32      100    (64, 65)
     36      100    (72, 73)
     40      100    (80, 81)
     44      100    (88, 89)
     48      100    (96, 97)
     52      100    (104, 105)
     56      100    (112, 113)
     60      100    (120, 121)

VCPU
     PID     %FREE 
     32      100   
     33      100   
     40      100   
     41      100   
     48      100   
     49      100   
     56      100   
     57      100   
     64      100   
     65      100   
     72      100   
     73      100   
     80      100   
     81      100   
     88      100   
     89      100   
     96      100   
     97      100   
     104     100   
     105     100   
     112     100   
     113     100   
     120     100   
     121     100   

MEMORY
     PA                   SIZE          
     0x7e0760800000       2552M          =============>> VM 도메인 설정 적용 후 가용 메모리가 줄어든 것을 확인

[test:/fkl/script]ldm list-config
factory-default
config_initial [next poweron]                  ============>> 리부팅 후 설정 적용 가능
[test:/fkl/script]sync
[test:/fkl/script]cd /Ldoms/Domains/
[test:/Ldoms/Domains]ls
alldomains.xml.131204094917  test-vm.xml                  test-vm.xml.131204100752
[test:/Ldoms/Domains]


2.2 OVM 구성
3) Domain 구성 정보 저장

1. OVM 구성 완료 후 구성에 이상이 없을 경우 현재 설정을 저장 함(이 경우 OS 및 xscf에서 동시에 설정 확인 가능)
<구성 완료 후 설정 정보 확인>
[test:/]ldm list-config
factory-default
config_initial [next poweron]
XSCF> showdomainconfig -p 0
PPAR-ID     :0
Booting config
(Current)  :config_initial
(Next)     :config_initial
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-
-----------------------------------------------------------------------------
Index       :2
config_name :config_initial
domains     :1
date_created:'2013-12-04 00:48:02'

2. 현재의 OVM 설정을 저장 함
[test:/]ldm add-config 20131204            ==============>> 설정명 '20131204'로 OVM 설정을 저장
[test:/]ldm list-config
factory-default
config_initial
20131204 [current]
[test:/]

XSCF> showdomainconfig -p 0
PPAR-ID     :0
Booting config
(Current)  :20131204
(Next)     :20131204
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-
-----------------------------------------------------------------------------
Index       :2
config_name :config_initial
domains     :1
date_created:'2013-12-04 00:48:02'
-----------------------------------------------------------------------------
Index       :3
config_name :20131204
domains     :2
date_created:'2013-12-04 02:19:18'

2.2 OVM 구성
4) VM Domain 제어

1. VM 기동 상태 확인
[test:/]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.1%  1h 8m
test-vm          active     -t----  5001    4     24G       25%  7m

2. VM 기동
[test:/]ldm start -a        ================>> 모든 VM 기동
LDom test-vm started
[test:/]ldm start test-vm   ================>> 특정 VM 기동
LDom test-vm started
[test:/]

3. VM 종료
[test:/]ldm stop -a           ================>> 모든 VM 기동
Remote graceful shutdown or reboot capability is not available on test-vm
LDom test-vm stopped
[test:/]ldm stop test-vm     ================>> 모든 VM 기동
Remote graceful shutdown or reboot capability is not available on test-vm
LDom test-vm stopped

4. VM 콘솔 데몬 기동
[test:/]svcs -a |grep vntsd
disabled       10:14:55 svc:/ldoms/vntsd:default
[test:/]svcadm enable vntsd
[test:/]svcs -a |grep vntsd
online         11:27:45 svc:/ldoms/vntsd:default
[test:/]svcadm restart vntsd                    ================>> 콘솔 접속에 LOCK이 걸릴 경우 데몬 재기동

5. VM 데몬 접속 및 종료
<접속>
[test:/]telnet 0 5001           ================>> VM에 설정 된 VM Port컨트롤러 도메인에서 telnet 접속 가능
Trying 0.0.0.0...
Connected to 0.
Escape character is '^]'.

Connecting to console "test-vm" in group "test-vm" ....
Press ~? for control options ..

{0} ok

<종료>
[test-vm]~.  ================>> VM에 접속 종료 시 (~) + (.) 를 입력 함

<기타 옵션>
~# --Send break
~^B --Send alternate break
~. --Exit from this console
~w --Force write access
~n --Console next
~p --Console previous
~? --Help


2.3 OVM 삭제
1) VM 삭제

<현재 OVM 구성 정보 및 Domain정보 확인>
[test:/]ldm list-config
factory-default
config_initial
20131204 [current]
[test:/]ldm ls        
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.2%  4m
test-vm          bound      ------  5001    4     24G           
[test:/]

<VM 제거>
[test:/]ldm stop -a
[test:/]ldm stop -a    
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.2%  4m
test-vm          bound      ------  5001    4     24G           
[test:/]ldm unbind test-vm  or ldm unbind -a                        ==============>> vm에 할장된 모든 자원을 제거
[test:/]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       1.6%  8m
test-vm          inactive   ------          4     24G           
[test:/]ldm destroy test-vm                                 ==============>> vm을 제거
[test:/]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.1%  9m

2.3 OVM 삭제
1) OVM Config 삭제 및 시스템 초기화

<현재 OVM 구성 확인 및 OVM 구성 정보 제거>
[test:/]ldm list-config
factory-default
config_initial
20131204 [next poweron]
[test:/]ldm rm-config 20131204              ==========================>> 구성 정보를 제거
[test:/]ldm list-config
factory-default
config_initial
[test:/]ldm rm-config config_initial
[test:/]ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
primary          active     -n-cv-  UART    4     4G       0.1%  6m
[test:/]ldm list-config            
factory-default
<XSCF 에서도 구성 정보가 지워진 것을 확인>
XSCF> showdomainconfig -p 0
PPAR-ID     :0
Booting config
(Current)  :20131204
(Next)     :20131204
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-
XSCF>

<시스템을 출하시 상태로 변경>
[test:/]ldm set-config factory-default                =============>> 설정 적용을 위해서는 system이 poweroff 되어야 함
[test:/]ldm list-config
factory-default [next poweron]
[test:/]svcadm disable ldmd
[test:/]svcadm disable vntsd
[test:/]shutdown -y -g0 -i6
XSCF> showdomainconfig -p 0
PPAR-ID     :0
Booting config
(Current)  :factory-default
(Next)     :factory-default
-----------------------------------------------------------------------------
Index       :1
config_name :factory-default
domains     :1
date_created:-

2.3 OVM 삭제
2) OVM PKG 삭제

<현재 OVM PKG 확인>
[test:/]pkginfo |grep SUNWldm*
application SUNWldm                          LDoms Manager software      ========>> OVM PKG
application SUNWldmp2v                       LDoms P2V tool              ========>> OVM PKG
system      SUNWldomr                        Solaris Logical Domains (Root)
system      SUNWldomu                        Solaris Logical Domains (Usr)
[test:/]
[test:/]pkgrm SUNWldm
[test:/]pkgrm SUNWldmp2v
[test:/]pkginfo |grep SUNWldm*
system      SUNWldomr                        Solaris Logical Domains (Root)
system      SUNWldomu                        Solaris Logical Domains (Usr)
[test:/]
[test:/]
[test:/]reboot


728x90
반응형
728x90
반응형
Solaris 에서도 패키지를 다운 받아서 설치할 수 있다. 
예전 SUN에서 서비스할 때에는 거의 대부분 무료로 받을 수 있었는데, Oracle로 넘어오고 나서부터
MOS(My Oracle support)에 계약건이 없으면 다운 안되는걸로 알고 있다. 

아마 유지보수 업체에서는 MOS 계정을 갖고 있을테니, 필요한 패키지가 있으면 구해달라고 한 뒤 설치하면 된다!!




1.     소프트웨어 패키지란 ?
기존의 소스 코드를 미리 컴파일 하여 쉽게 배포할 수 있도록 해주는 것이 패키지이다.


2.     패키지 기본 관리 명령
[t5120.:/]pkgtrans file
Package type format(데이터 스트림<->파일시스템 포맷)을 변경할 때 사용한다.

[t5120.:/]pkgadd –option package_name
-d : package file의 경로를 명시
-a : 파일의 경로를 명시하면, pkgadd 명령이 소프트웨어 패키지를 설치할 때 필요한 정보를 해당 파일에서 참조한다. -a 옵션을 사용하지 않으면 /var/sadm/install/admin/default 파일이 기본으로 사용된다.
(ex. 설정내용 중 basedir=default 내용을 수정하면 설치위치를 달리하여 패키지 다른 버전을 설치할 수 있다.)
ex) # pkgadd -d /sunfree/gcc-3.4.6-sol10-sparc-local

[t5120.:/]pkgrm –option package_name
-a : 파일의 경로를 명시하면, pkgrm 명령이 소프트웨어 패키지를 제거할 때 필요한 정보를 해당 파일에서 참조한다. -a 옵션을 사용하지 않으면 /var/sadm/install/admin/default 파일이 기본으로 사용된다.

[t5120.:/]pkginfo –option { package_name }
-l : Long List Information으로 보다 자세한 정보를 출력
-d package_path : package 정보를 확인하여 시스템에 설치되지 않은 패키지 정보를 출력

[t5120.:/]pkgchk –option { package_name }
-l : 소프트웨어 패키지가 설치될 당시의 상태와 현재의 상태를 비교해서 그 차이점이나 사용 내용을 자세히 출력한다. 개인적으로는 –l 옵션 안쓰는게 더 직관적으로 출력되는듯…
-v : pkgchk 명령을 이용해서 해당 패키지를 검사할 때 비교 대상이 되는 디렉토리 혹은 파일의 리스트를 출력
-p path : 비교 대상을 path로 지정하여 체크


728x90
반응형
728x90
반응형
Solaris 10부터 SMF 라는 개념이 생겼는데, 쉽게 말하면 서비스를 관리하는 데몬? 정도 이다.. 

Linux 에서는 전통적으로 "service sshd restart" 등 service 라는 명령어가 있듯이 Solaris 에서는 본 문과 같이 서비스를 관리한다.


1.     SMF(Solaris Management Facility) 란?
Solaris 10에서는 SMF로 시작 스크립트를 대신하고 체계적인 관리(서비스 비정상 종료시 재시작 등) 및 시스템 구동에서 스크립트에 알 수 없는 오류 발생하였을 때 
가시적으로 쉽게 감지하기 위해 만들어진 서비스이다. Solaris 10은 9과 달리 SMF를 통해 서비스가 관리되기 때문에 /etc/init.d에 시작 스크립트가 거의 없다. 
하지만 일부 9의 업데이트 버전에 따라 지원할 수도 있다.

즉 윈도우 OS의 제어판 > 관리도구 > 서비스 툴과 비슷한 기능을 수행한다.



2.     SMF(Solaris Management Facility) 동작 여부 확인
[t5120:/]ps -ef | grep svc
root     7     1   0 02:04:49 ?        0:10 /lib/svc/bin/svc.startd -> 요청에 따라 시작과 중지를 담당
root     9     1   0 02:04:49 ?        0:33 /lib/svc/bin/svc.configd -> 요청에 따라 저장소에 접근
root   255     1   0 02:05:06 ?           0:00 /lib/svc/method/iscsi-initiator

[t5120:/]regadm status
Solaris Auto-Registration is currently { online | enable }

ㆍ만약 # regadm status  명령 시 offline 혹은 disable 일 때 조치 방법
[t5120:/]regadm enable  ----> 여러 번 해줘야 online으로 바뀐다.


3.     SMF 관리
svcs : 등록되어 있는 서비스의 목록과 상태를 보여주는 명령
--> [t5120:/]svcs –option { 특정 FMRI }

svcadm : 등록되어 있는 서비스를 시작, 정지, 재기동 하는 명령
--> [t5120:/]svcadm –option state { 특정 FMRI }

svccfg : 서비스의 등록, 수정, 삭제를 하는 명령
--> [t5120:/]svccfg { import(입력) | export(출력) | modify(수정) | delete(삭제) } 설정파일.xml

inetadm : inetdconf를 대신하여 inet 관련(네트워크) 서비스들을 제어한다.
--> [t5120:/]inetadm –option { 특정 FMRI }

FMRI(Fault Management Resource Identifier)
ㆍSMF에 등록된 서비스의 고유 키를 말한다. 이 키는 svcs, svccfg, svcadm 명령에 의해 사용된다. 현재 시스템에 등록된 FMRI는 svcs –a 명령을 통해 전부 확인할 수 있다.
ㆍFMRI는 [스키마:서비스명:인스턴트명] 형식으로 이뤄진다.
ㆍ인스턴스명이 default인 경우 보통 생략된다.
legacy_run      0:17:37 lrc:/etc/rc2_d/S10lu
disabled        0:17:34 svc:/network/time:stream
㉠             ㉡   ㉢        ㉣      ㉤

㉠ : 해당 서비스의 state
㉡ : start time
㉢ : SMF에 관리되는 서비스는 svc로 표기되고, lrc는 legacy process란 뜻
㉣ : svc 경우는 서비스 인스턴스를 의미하고,
legacy의 경우 스크립트를 관리하는 디렉토리와 서비스 이름을 뜻함.
㉤ : 서비스 명(legacy는 없다)

설정에 문제가 있거나, 특성 서비스가 실행이 안되면 로그는 /var/svc/log에 기록된다.



4.     SMF 명령 이용 방법


ㆍsvcs 명령을 통해 서비스의 목록과 상태를 확인할 수 있다.
[t5120:/]svcs –option { 특정 FMRI }
options설명
-astatus에 상관없이 전체 서비스 보기, 생략 시 enable만 출력한다.
-xstatus가 enable이지 않을 것들만 출력
-vverbose(자세히 보기)
-l FMRI특정 FMRI(서비스)의 모든 정보 보기(-v 옵션 보다 강력함)
-d FMRI특정 FMRI(서비스) 의존하고 있는 모든 서비스 보기
Lists a services dependencies
-D FMRI특정 FMRI(서비스)가 실행한 데몬 및 자식 프로세스 서비스 보기(FMRI 의존하고 있는 서비스 보기)
Lists a services dependents
-p 모든 서비스에 관련된 PID를 출력


ㆍsvcs 명령에서 출력된 STATE(상태 값) 정의
state설명
Uninitialized모든 인스턴스가 초기화되지 않은 상태를 의미, 해당 서비스의 구성 정보가 아직 로드되지 않았으며, 아직 구동되지 않는 상태를 의미한다. SMF 데몬에 의해 disable, offline으로 변경될 수 있다.
Offline해당 인스턴스는 활성화 되었지만 구동되지 않은 상태를 의미, 인스턴스가 시작 메소드 동앙네 발생한 에러 또는 의존성 문제로 발생된 상태를 나타낸다.
Online해당 서비스가 활성화되어 있으며, 정상적으로 구동 중인 상태
Disabled해당 서비스가 관리자에 의해 disable 되었거나, 해당 서비스 인스턴스의 설정 파일에 의해 disabled로 표시된 경우. 서비스가 구동되지 않았고, 비활성화된 상태
Degraded서비스는 활성화되었지만, 일부 실패로 인해 제한적으로 구동되는 상태, 거의 대부분이 잠시 후에 다른 상태로 변환된다.
Maintenance서비스는 활성화되었지만, 서비스를 실행할 수 없으며, 관리자에 의해 서비스와 관련된 설정을 수정하여야 한다.
Legacy_runSMF에 의해 관리되지는 않는 레거시 서비스를 사용하는 상태의 서비스, 보통 /etc/rc%.d 에서 실행된 스크립트


ㆍsvcadm 명령을 사용하여 서비스에 state를 변경할 수 있다.
[t5120:/]svcadm –option state { 특정 FMRI }
options설명
 -v수행 상황을 화면으로 출력
 -renable 명령(state)에 대해서만 적용되고, 의존되는 서비스 모두를 enable 시킨다.
-senable, disable 명령(state)에 대해 적용되고, 서비스의 enable/disable을 기다리지 않고 svcadm 명령이 종료됨 
 -tenable, disable, mark 명령(state)에 대해 적용되고,해당 서비스는 재시작 후에 enable, disable, mark 명령이 수행된다.
-dmilestone 명령어에 대해 적용되고, 기본 마일 스톤으로 지정

state설명
enable해당 FMRI(서비스)의 인스턴스 state를 활성화
disable해당 FMRI(서비스)의 인스턴스 state를 비활성화
restart해당 FMRI(서비스) 인스턴스를 재기동
refresh해당 FMRI(서비스)의 인스턴스 구성 정보를 재로딩
clearmaintenance 상태인 서비스를 클리어를 줌으로서 enable 명령을 줄 수 있다.
markdebug(디버그)용도로 서비스의 상태를 변경할 수 있다.
milestone
시스템에 설정되어 있는 서비스를 특정 용도에 맞게 실행시킨다. 
S레벨 : svc:/milestone/single-user:default
2레벨 : svc:/milestone/multi-user:default
3레벨 : svc:/milestone/multi-user-server:default

 ※ milestone 이란?
Milestone 이란 여러 서비스들을 묶은 특별한 서비스 타입을 의미한다. 솔라리스10 버전 이전에 런 레벨과 유사한 개념으로, 시스템은 특정 시스템 상태에 이르기 위해서는 실행하려는 서비스들의 정의가 필요하고 이러한 서비스들은 계층적 구조를 가짐으로서 실행된다.



ㆍsvccfg 명령 사용하여 SMF에 서비스를 등록, 수정, 삭제를 할 수 있다.
[t5120:/]svccfg { import(입력) | export(출력) | modify(수정) | delete(삭제) } 설정파일.xml

ㆍxml 파일로 SMF 등록하는 절차
순서설명
1해당 응용 프로그램의 xml 파일을 /var/svc/manifest/application 경로에 복사한다.
2해당 응용 프로그램의 기동/종료 스크립트를 /lib/svc/method 경로에 복사한다.
3# cd /var/svc/manifest/application   ---> 해당 응용 프로그램 xml 파일 경로로 이동
4# svccfg validate 응용_프로그램.xml ---> 응용 프로그램 xml 파일을 svccfg 명령을 통해 검증
5
# svccfg import 응용_프로그램.xml
---> 응용 프로그램 xml 파일을 svccfg 명령에 import 옵션으로 입력
6# svcs –a | grep 응용_프로그램  ---> svcs 명령을 통해 정상적으로 SMF에 등록되었는지 확인
7# svcadm enable svc:응용_프로그램 ---> svcadm 명령을 통해 state를 enable로 변경


ㆍinetadm 명령을 사용하여 network서비스들의 enabled와 property를 변경할 수 있다.
[t5120:/]inetadm –option { 특정 FMRI }
options설명
 -e특정 FMRI에 enabled에 값을 enabled로 변경한다.
-d특정 FMRI에 enabled 값을 disabled로 변경한다.
-l특정 FMRI에 property 정보를 모두 출력한다.
-m특정 FMRI에 property 정보를 수정한다.

 Ex) # inetadm –m network/telnet:default tcp_wrappers=TRUE


728x90
반응형
728x90
반응형
안녕하세요!! 
Solaris10 에서 Recommend patch 혹은 EIS patch 를 진행하게 되면, 
# showrev 명령을 실행했을 때, Solaris patch number가 올라가게 되는데, 

다음은 patch number에 따른 Solaris update version 을 알기위한 표 입니다.



Solaris 10 SPARC Kernel PatchIDs
Description
Solaris 10 x86 Kernel PatchIDs

150400-01 to 150400-xx

Kernel Bug Fixes
from July 2013

 150401-01 to 150401-xx

  148888-01 to 148888-05

Kernel Bug Fixes
post Solaris 10 1/13 (Update 11) to June 2013

 148889-01 to 148889-05

  147147-26 only

Solaris 10 1/13 (Update 11) Kernel PatchID

 147148-26 only

  147440-01 to 147440-27

Kernel Bug Fixes
post Solaris 10 8/11 (Update 10)

 147441-01 to 147441-27

  144500-19 only

Solaris 10 8/11 (Update 10) Kernel PatchID
 144501-19 only
 144488-01 to 144488-17

Kernel Bug Fixes
post Solaris 10 9/10 (Update 9)

 144489-01 to 144489-17

  142909-17 only

Solaris 10 9/10 (Update 9) Kernel PatchID
 142910-17 only
 142900-01 to 142900-15

Kernel Bug Fixes
post Solaris 10 10/09 (Update 8)

 142901-01 to 142901-15
 141444-09 only
Solaris 10 10/09 (Update 8) Kernel PatchID  141445-09 only
 141414-01 to 141414-10

Kernel Bug Fixes
post Solaris 10 5/09 (Update 7)

 141415-01 to 141415-10
139555-08 only
Solaris 10 5/09 (Update 7) Kernel PatchID139556-08 only
138888-01 to 138888-08

Kernel Bug Fixes
post Solaris 10 10/08 (Update 6)

138889-01 to 138889-08
 137137-09 only

Solaris 10 10/08 (Update 6) Kernel PatchID

 137138-09 only
137111-01 to 137111-08

Kernel Bug Fixes
post Solaris 10 5/08 (Update 5)

137112-01 to 137112-08
 127127-11 only
Solaris 10 5/08 (Update 5) Kernel PatchID
 127128-11 only
 127111-01 to 127111-11

Kernel Bug Fixes
post Solaris 10 8/07 (Update 4)

 127112-01 to 127112-11
 120011-14 only
Solaris 10 8/07 (Update 4) Kernel PatchID
 120012-14 only
 125100-04 to 125100-10

Kernel Bug Fixes
post Solaris 10 11/06 (Update 3)

125101-01 to 125101-10
118833-02 to 118833-36

118833-33 (SPARC) / 118855-33 (x86) is the Kernel patch included in Solaris 10 11/06 (Update 3) but these patches were not releasable as "standalone" patches to SunSolve.

118833-17 (SPARC) / 118855-14 (x86) is the Kernel patch included in Solaris 10 6/06 (Update 2). 118855-14 was not releasable as a "standalone" patch to SunSolve.

118855-01 to 118855-36
118822-01 to 118822-30
118822-25 (SPARC) / 118844-26 (x86) is the Kernel patch included in Solaris 10 1/06 (Update 1). 118844-26 was not releasable as a "standalone" patch to SunSolve.

118844-01 to 118844-30




2.     업데이트 버전 별 /etc/release 파일 내용

     A.     Update 03
# cat /etc/release
Solaris 10 11/06 s10s_u3wos_10 SPARC
Copyright 2006 Sun Microsystems, Inc. All Rights Reserved.
Use is subject to license terms.
Assembled 14 November 2006


     B.     Update 08
[t5220:/]cat /etc/release
                      Solaris 10 10/09 s10s_u8wos_08a SPARC
           Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
                        Use is subject to license terms.
                           Assembled 16 September 2009


 C.     Update 09
[t5220:/] cat /etc/release
                   Oracle Solaris 10 9/10 s10s_u9wos_14a SPARC
     Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
                            Assembled 11 August 2010


D.     Update 10
# cat /etc/release
                   Oracle Solaris 10 8/11 s10s_u10wos_17b SPARC
  Copyright (c) 1983, 2011, Oracle and/or its affiliates. All rights reserved.
                        Assembled 23 August 2011


E.     Update 11

# cat /etc/release
                   Oracle Solaris 10 1/13 s10s_u11wos_24a SPARC
  Copyright (c) 1983, 2013, Oracle and/or its affiliates. All rights reserved.
                            Assembled 17 January 2013


4.     업데이트 시기
     Solaris 10 1/06 - U1
     Solaris 10 6/06 - U2
     Solaris 10 11/06 - U3
     Solaris 10 8/07 - U4
     Solaris 10 5/08 - U5
     Solaris 10 10/08 - U6
     Solaris 10 5/09 - U7
     Solaris 10 10/09 - U8
     Solaris 10 9/10 - U9
     Solaris 10 8/11 – U10
     Solaris 10 1/13 – U11


728x90
반응형

+ Recent posts