linux advanced managementblog.syszone.co.kr/attachment/2867923805.pdf6. hardware control remote...
TRANSCRIPT
IBM System x Enterprise Architecture Linux Advanced Management
- 1 -
Linux Advanced Management
Kim Wan Hee , FTSS
Last Update 2007/07/24
IBM System x Enterprise Architecture Linux Advanced Management
- 2 -
Index
1. xCAT (Extreme Cluster Administrat ion Toolkit ) 05
1.1. xCAT ์ค์น 07
1.2. xCAT ํ๊ฒฝ ์ค์ 07
1.3. Time Service ๋ฑ๋ก 08
1.4. Compute Node SOL (Serial Over LAN) Enable 08
1.5. xCAT Config File 09
1.6. xCAT Node Installation Process 10
1.7. ๋ชจ๋ ๋ ธ๋์ ๊ตฌ์ฑ 11
1.8. /etc/hosts ํ์ผ ์ ์ 11
1.9. Blade Center Node Installation 11
1.10 xCAT ์ค์ ๋ช ๋ น์ด 21
2. HPC Software Stack Instal lat ion 24
2.1 Intel C Compiler 25
2.2 Intel Fortran Compiler 25
2.3 Intel MPI 25
2.4 Intel MKL (Math Kernel Library) 26
2.5 PBS Pro 26
2.6 PBS Pro Check 26
3. HPL Compile, Instal lat ion and Running BMT 28
3.1 HPC ์์คํ ์ ์ฑ๋ฅ์์น - FLOPS 28
3.2 ์ด๋ก ์ฑ๋ฅ vs ์ค์ ์ฑ๋ฅ โ Rpeak vs Rmax 28
3.3 HPL (High Performance Linpack) 28
3.4 ์ ํ๋์ โ BLAS , ATLAS 29
3.5 MPI (Message Passing Interface) 29
3.6 MPICH and LIbrary Installation 30
3.6.1 ์ฌ์ ์์คํ ๊ตฌ์ฑ ํ๊ฒฝ 30
3.6.2 MPICH Installation 30
3.6.3 ATLAS Installation 34
3.6.4 ATLAS Cache Size 34
3.6.5 GotoBLAS Installation 35
3.6.7 HPL Installation 37
3.7 Run HPL 40
3.7.1 Compile 40
3.7.2 Send the Execution file 40
3.7.3 Preparation for MPI Job 40
3.7.4 xhpl ์คํ 40
IBM System x Enterprise Architecture Linux Advanced Management
- 3 -
4 GPFS (General Parallel File System) 43
4.1 GPFS ๊ฐ์ 43
4.2 GPFS ํ๊ฒฝ 43
4.3 GPFS ํน์ฑ 44
4.4 GPFS (GENERAL PARALLEL FILE SYSTEM) ์ค์น 45
4.4.1 GPFS ์ค์น ์ ์ค๋น์ฌํญ 45
4.4.2 GPFS ์ค์น ๋ฐ Portability Layer Buildํ๊ธฐ 45
4.5 GPFS (GENERAL PARALLEL FILE SYSTEM) ๊ตฌ์ฑ 46
4.5.1 GPFS test ์์คํ ๊ตฌ์ฑ๋ 46
4.5.2 GPFS ๊ตฌ์ฑ ์ ๊ณ ๋ ค์ฌํญ 47
4.5.3 GPFS Cluster ๊ตฌ์ฑ 48
4.6 GPFS (GENERAL PARALLEL FILE SYSTEM) ์ด์ ๋ฐ ๊ด๋ฆฌ 50
4.6.1 GPFS Filesystem ํ์ธ ๋ฐ ๊ด๋ฆฌ 50
4.6.2 GPFS Node ๊ด๋ฆฌ 53
4.6.3 GPFS Cluster config๋ณ๊ฒฝ 54
4.7 GPFS(GENERAL PARALLEL FILE SYSTEM) ๊ตฌ์ฑ๋ณ๊ฒฝ ๋ฐ ์ฅ์ ๋ณต๊ตฌ 55
4.7.1 GPFS IP ๋ฐ host name ๋ณ๊ฒฝ 55
4.7.2 GPFS cluster configuration data ํ์ผ ๋ณต๊ตฌ 56
5. XEN 57
5.1 Xen 57
5.2 Xen ์์ ์ง์ํ๋ ๊ฐ์ํ ํํ 57
5.3 Xen ์ ๊ธฐ๋ณธ ๊ตฌ์กฐ ๋ฐ Memory Ballooning ์ด๋? 57
5.4 Xen ๊ตฌ์ฑ ์ ํ์ธ ์ฌํญ 58
5.5 virt-install ๋ช ๋ น์ผ๋ก Xen para-virtualized guest install 58
5.6 virt-manager ๋ช ๋ น์ผ๋ก Xen para-virtualized guest install 61
5.7 Virtual system Management 67
5.8 Command Base Management 70
IBM System x Enterprise Architecture Linux Advanced Management
- 4 -
๋ณธ ๋ฌธ์๋ IBM Residency Program ์ ์ฐธ์ฌํ์ฌ ์ฃผ์ Business Partner ๋ถ๋ค๊ป์ ๋ง
๋์ ์๋ฃ ์ ๋๋ค. ๋ฐ์์ ์๊ฐ์ค์๋ 5์ผ๊ฐ ๊ต์ก์ ์ฐธ์ ํด์ฃผ์ Engineer ๋ถ๋ค๊ป ๊ฐ
์ฌ ๋๋ฆฝ๋๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 5 -
1. xCAT (Extreme Cluster Administration Toolkit)
xCAT (Extreme Cluster Administration Toolkit)์ Linux Cluster์ ๊ฐ์ด ๋ง์
๋์ผํ ํ๋์จ์ด ์ปดํฌ๋ํธ๋ฅผ ์ฌ์ฉํ๋ ํ๊ฒฝ์์ ๊ด๋ฆฌ์๊ฐ Build, Configure,
Administer, ๊ทธ๋ฆฌ๊ณ Maintain ์์ ์ ์ค์ ์ง์คํ๋ ํ๊ฒฝ์์ ํจ์จ์ ์ผ๋ก ๊ด๋ฆฌ
๊ฐ๋ฅ์ผ ํ๋ Perl/Unix Shell Script Base์ Tool์ ๋๋ค. ์๋์ ๊ฐ์ ์์คํ ํ
๊ฒฝ์์ ๊ตฌํ์ด ๊ฐ๋ฅํ๋ค.
1. High Performance (HPC): such as computing physics, seismic, CFD, FEA, weather, bioinformatics and other simulations. 2. Horizontal Scaling (HS): such as Web farms. 3. Administrative: A very convenient platform, although non-traditional, to install and administer a number of Linux machines. 4. Microsoft Windows and other Operating Systems: With xCAT's cloning and imaging support, it can be used to rapidly deploy and conveniently manage clusters with compute nodes that run Windows or any other operating system.
1. OS/Distribution support Any OS on compute nodes via OS agnostic imaging support. 2. Hardware Control Remote Power control (on/off state) through IBM Management Processor Network, BMC, and/or APC Master Switch. 3. Hardware Control Remote software reset (rpower). 4. Hardware Control Remote Network BIOS/firmware update and configuration on IBM hardware. 5. Hardware Control Remote OS console with pluggable support for a number terminal servers. 6. Hardware Control Remote POST/BIOS console through the IBM Management Processor Network and with terminal servers. 7. Boot Control Ability to remotely change boot type (network or local disk) with syslinux. 8. Automated parallel install using scripted RedHat kickstart, SUSE Linux autoyast, on ia32, x86_64, ppc, and ia64. 9. Automated parallel install using imaging with other Linux distributions, Windows, and other operating systems. 10. Automated network installation with supported PXE NICs, with etherboot or BootP on supported NICs without PXE. 11. Monitoring hardware alerts and email notification with IBM's Management Processor Network and SNMP alerts. 12. Monitoring remote vitals such as fan speed, temperature, and more with IBM's Management Processor Network. 13. Monitoring remote hardware event logs with IBM's Management Processor Network/IPMI Interface. 14. Administration utilities such as parallel remote shell, ping, rsync, and copy. 15. Administration utilities such as remote hardware inventory with IBM's Management Processor Network. 16. Software Stack PBS and Maui schedulers to build scripts, documentation, automated setup, extra related utilities, and deep integration. 17. Software Stack Myrinet to automate setup and installation. 18. Software Stack MPI to build scripts, documentation, and automated setup for MPICH, MPICH-GM, and LAM. 19. Usability command line utilities for all cluster management functions. 20. Usability single operations can be applied in parallel to multiple nodes with very flexible and customizable group/range functionality. 21. Flexible support for various user defined node types. 22. Diskless support using warewulf.
IBM System x Enterprise Architecture Linux Advanced Management
- 6 -
<xCAT์ ์ฌ์ฉํ๊ธฐ ์ํ ๊ธฐ๋ณธ HPC ํ๊ฒฝ>
<HPC๋ฅผ ๊ตฌ์ฑํ๊ณ ์๋ ์ค์ ์ปดํฌ๋ํธ>
Management node -- Management node functionality can reside on a single server or multiple servers. In a single server environment, the management server operates in standalone mode. The management node is connected to the compute nodes over the Management VLAN on the switch. The management server is where the xCAT software is installed and is used exclusively to control the compute nodes using various xCAT functionalities: OS installation, remote power control, firmware updates, Serial-over-LAN, etc. In our conceptual cluster, there is one management node. User/login nodes -- Ideally, the compute nodes of a cluster should not accept external connections and should only be accessible to system administrators through the management server. System users can log in to user nodes (or login nodes) in order to run their workloads on the cluster. Each user node consists of an image with full editing capabilities, the required development libraries, compilers, and everything else required to produce a cluster-enabled application and retrieve results. Storage servers and disks -- You can connect several storage servers to a diskbased backend using various mechanisms. Connecting storage to the cluster can be direct or through a storage area network (SAN) switch, either by fiber, copper, or a mixture of the two. These servers provide shared storage access to the other servers within the cluster. If data backup is required, connect
xCAT Server
IBM System x Enterprise Architecture Linux Advanced Management
- 7 -
the backup device to the storage server using an extra copper or fiber link. For the example cluster, the storage back end is a single entity, providing shared file system access across the cluster. Compute nodes -- These nodes run the cluster workload, accepting jobs from the scheduler (if a job scheduler is used on the cluster). The compute nodes are the most disposable part of the cluster. The system administrator can easily reinstall or reconfigure them using the management server.
1.1. xCAT ์ค์น
http://www.alphaworks.ibm.com/tech/xCAT ์์ Download Link ์์ ๊ด๋ จ ํ์ผ Downloadํจ
- ๋ฐ์ ํ์ผ์ /opt ์ ํ์ด์ค
# cd /opt
# tar zxvpf /tmp/xcat-dist-core-1.2.0.tgz
# tar zxvpf /tmp/xcat-dist-oss-1.2.0.tgz
# tar zxvpf /tmp/xcat-dist-ibm-1.2.0.tgz (extract only if you have IBM xSeries nodes)
cp /opt/xcat/samples/etc/* /opt/xcat/etc
1.2. xCAT ํ๊ฒฝ ์ค์
#export XCATROOT=/opt/xcat
#cd $XCATROOT/sbin
#./setupxcat
#copycds ์ค์น ํ OS image๋ฅผ ์ ์ฅํจ.(xCAT์ค์น ํ ์ด๋ ๋จ๊ณ์์๋ ์งํ ๊ฐ๋ฅ)
[root@x305 sbin]# cat /root/.bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
PATH=$PATH:$HOME/bin
BASH_ENV=$HOME/.bashrc
USERNAME="root"
export USERNAME BASH_ENV PATH
# xCAT Profile
export XCATROOT=/opt/xcat
export XCATPREFIX=/opt/xcat
export PATH=$PATH:$XCATROOT/bin:$XCATROOT/sbin /etc/man.config ์ [ MANPATH /opt/xcat/man ] ์ถ๊ฐ
IBM System x Enterprise Architecture Linux Advanced Management
- 8 -
1.3. Time Service ๋ฑ๋ก
# mv -f /etc/ntp.conf /etc/ntp.conf.ORIG
# touch /etc/ntp.conf
# vim /etc/ntp.conf
-------------------------------------
server 127.127.1.0
fudge 127.127.1.0 stratum 10
driftfile /etc/ntp/drift
-------------------------------------
* Time์๋ฒ์์์ Timezone ์ค์
setup
setclock OR hwclock -w
chkconfig --add ntpd
service ntpd start
* NTP ํด๋ผ์ด์ธํธ ์ค์
server mgt.cluster.com
driftfile /etc/ntp/drift
multicastclient
broadcastdelay 0.008
authenticate no
keys /etc/ntp/keys
trustedkey 65535
requestkey 65535
controlkey 65535
ntp์๋ฒ์์ /etc/ntp๋๋ ํ ๋ฆฌ์์ ์๋ driftํ์ผ ๋ณต์ฌ
* NTP ๋ฐ๋ชฌ ํ ์คํธ
[root@blade329 STREAM]# ntpstat
synchronised to NTP server (172.20.0.1) at stratum 12
time correct to within 23 ms
polling server every 128 s
1.4. Compute Node SOL (Serial Over LAN) Enable
For IBM System x 3550, 3650, and 3455 Flash the Management Processor (BMC) to the latest version. Flash BIOS to the latest version. Remove the power cord for 10 seconds. Restore the power cord. Reboot and press F1 to enter the BIOS configuration. Configure the BIOS settings for optimum performance and then edit the Devices and I/O Ports as shown below: Devices and I/O Ports โข Serial port A: Port 3F8, IRQ 4 โข Serial port B: Disabled โข Remote Console Redirection o Remote Console Active: Enabled o Remote Console COM Port: COM 1 o Remote Console Baud Rate: 19200 To use Remote Console Text Emulation: VT100/VT220 Configure the text emulation settings as listed below:
IBM System x Enterprise Architecture Linux Advanced Management
- 9 -
โข Remote Console Keyboard Emulation: VT100/VT220 โข Remote Console After Boot: Enabled โข Remote Console Flow Control: Hardware Configure the โStartupโ settings as listed below: From the main menu, select Startup Sequence and configure the settings as follows: โข First Startup Device: CD ROM โข Second Startup Device: Diskette Drive 0 โข Third Startup Device: Network โข Forth Startup Device: Hard Disk โข Wale On LAN: Disabled โข Planer Ethernet PXE/DHCP: Planer Ethernet 1 43 โข Boot Fail Count: Disabled
For IBM System BladeCenter Server Flash the Management Processor (BMC) to the latest version. Flash BIOS to the latest version. Remove the power cord for 10 seconds. Restore the power cord. Reboot and press F1 to enter the BIOS configuration. Configure the BIOS settings for optimum performance and then edit the Devices and I/O Ports as shown below: Devices and I/O Ports โข Serial port A: Auto configured โข Serial port B: Auto configured โข Remote Console Redirection o Remote Console Active: Enabled o Remote Console COM Port: COM 2 o Remote Console Baud Rate: 19200 To use Remote Console Text Emulation: VT100/VT220 Configure the text emulation settings as listed below: โข Remote Console Keyboard Emulation: VT100/VT220 โข Remote Console After Boot: Enabled โข Remote Console Flow Control: Hardware Configure the โStartupโ settings as listed below: From the main menu, select Startup Sequence and configure the settings as follows: โข First Startup Device: CD ROM โข Second Startup Device: Diskette Drive 0 โข Third Startup Device: Network โข Forth Startup Device: Hard Disk โข Wale On LAN: Disabled โข Planer Ethernet PXE/DHCP: Planer Ethernet 1 43
โข Boot Fail Count: Disabled
1.5. xCAT Config File
Cluster ์ ์, ํ๊ฒฝ ๊ตฌ์ฑํ์ผ์ด ์๋ ๊ฒฝ๋ก๋ /opt/xcat/etc/* ์ ์์ด์ผ ํ๋๋ฐ ์์ถ์ ํ๋ฉด etc
Directory ๋ ์์ต๋๋ค. (์ด๋ /opt/xcat/samples/etc/* ์ ์์ ํ์ผ์ด ์์ผ๋ ์ฐธ๊ณ ํด์ ๋ง๋ค์ด ์ฌ์ฉ์
ํ๋ฉด ๋ฉ๋๋ค.) ํ๊ฒฝ์ค์ ์ ๋ ์์ธํ ๋ด์ฉ์ ์ํ๋ค๋ฉด ์๋์ Site ์ Redbook ์ ์ฐธ๊ณ ํ๋ฉด ๋ฉ๋๋ค.
ํ๊ฒฝ ๊ตฌ์ฑ Directory ์๋ ๊ฐ Node,Switch,Terminal server, Node NIC MAC ๋ฑ xCat ๋ด๋ถ ๋ ธ๋์ ๋ชจ
๋ ์ ๋ณด๋ค์ด ๋ค์ด ๊ฐ๊ฒ ๋ฉ๋๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 10 -
*๊ฐ ๊ตฌ์ฑ ํ์ผ ์ด๋ฆ ๋ชฉ๋ก
site.tab / nodehm.tab / nodelist.tab / nodepos.tab / noderes.tab / nodetype.tab / passwd.tab / postscripts.tab /
postdeps.tab / snmptrapd.conf / networks.tab
mac.tab (loaded with non-collectable MACs, e.g. terminal servers, switches, RSAs, etc...)
*Terminal server ๊ด๋ จ ๊ตฌ์ฑ Table ์ด๋ฆ ๋ชฉ๋ก conserver.tab
conserver.cf
*MAC Address ์ ๋ณด๋ฅผ Cisco Switch ์์ ์์ง์ ํ๊ธฐ ์ํ ๊ตฌ์ฑ ์ ๋ณด
cisco.tab
summit48i.tab
blackdiamond.tab
*IBM eServer xSeries Management Processor(์ RSA Card) mpa.tab
mp.tab
*APC Master Switch ๋ฅผ ์ํ ํ ์ด๋ธ apc.tab
*APC Master Switch Plus ๋ฅผ ์ํ ํ ์ด๋ธ apcp.tab
*xCAT flash support ๋ฅผ ์ํ ํ ์ด๋ธ nodemodel.tab
*EMP ์ง์ ๊ตฌ์ฑ ํ ์ด๋ธ emp.tab
*Baytech ์ง์ ๊ตฌ์ฑ ํ ์ด๋ธ baytech.tab
*xCat GPFS ์ง์ ๊ตฌ์ฑ ํ ์ด๋ธ gpfs.tab
*IPMI ์ง์ ๊ตฌ์ฑ ํ ์ด๋ธ (BMC๋ฅผ ์ด์ฉํ node management) ipmi.tab
*Blade์๋ฒ ์ฌ๋กฏ์์น์ switch port๋ฒํธ mapping ํ ์ด๋ธ bcnet.tab
1.6. xCAT Node Installation Process
[์ค์น ํ๋ก์ธ์ค ๋ค์ด์ด๊ทธ๋จ]
IBM System x Enterprise Architecture Linux Advanced Management
- 11 -
1.7. ๋ชจ๋ ๋ ธ๋์ ๊ตฌ์ฑ
IANS:
Update all firmware to latest levels.
Configure firmware/BIOS/CMOS to NEVER prompt for anything.
Configure network to boot before HD.
Enable management processor.
Redirect POST/BIOS out serial if possible.
* rbootseq ๋ช ๋ น์ผ๋ก Bladecenter boot order๋ณ๊ฒฝ
* rbootseq noderange n,c,hd0,f
1.8. /etc/hosts ํ์ผ ์ ์
[root@mgt pxelinux.cfg]# vi /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost ์ฌ๊ธฐ hostname์ด ๋ค์ด๊ฐ์ง ์๋๋ก ์ฃผ์
192.168.12.74 mgt mgt.cluster.com
192.168.70.125 bc1
192.168.70.127 sw1
192.168.70.128 sw2
192.168.12.1 blade1
192.168.12.2 blade2
192.168.12.3 blade3
192.168.12.4 blade4
1.9. Blade Center Node Installation
1) /opt/xcat/etc ์ ๊ตฌ์ฑํ์ผ ํธ์ง
/opt/xcat/etc/site.tab Cluster ์ ์ฒด ํ๊ฒฝ ๊ตฌ์ฑ ํธ์ง
/opt/xcat/etc/nodelist.tab ๊ฐ Node ์ Group ํธ์ง
/opt/xcat/etc/noderes.tab ๊ฐ ๋ ธ๋๋ค์ด ์ค์น ๋ ๋ tftp,nfs๋ฑ์ ์๋ฒ ๊ฒฝ๋ก์ง์
/opt/xcat/etc/nodetype.tab ๊ฐ Node ์ Type ์ค์
(node๋ฅผ group์ผ๋ก ์ ์ํ ๋, nodelist ๋ฐ nodetype์ ๋ฑ๋ก์ ํด์ผ ํ๋ค.)
/opt/xcat/etc/nodehm.tab Node Hardware Management ์ค์
/opt/xcat/etc/nodemodel.tab ๊ฐ ๋ ธ๋์ machine ์ ์
/opt/xcat/etc/passwd.tab ๊ฐ Management Node ์ Password ์ค์
/opt/xcat/etc/mac.tab ๊ฐ ๋ ธ๋์ Mac Address ์ค์
/opt/xcat/etc/conserver.cf ๊ฐ ๋ ธ๋์ conserver ์ค์
/opt/xcat/etc/conserver.tab conserver์ํด ๊ด๋ฆฌ๋ ๋ ธ๋๋ชฉ๋ก ์ค์
/opt/xcat/etc/mpa.tab Management processor Adapter ๋ฐ module ์ ์
IBM System x Enterprise Architecture Linux Advanced Management
- 12 -
/opt/xcat/etc/mp.tab Management processor Network์ ํ ํด๋ก์ง ์ ์
/opt/xcat/etc/bcnet.tab blade์๋ฒ slot number์ blade switch๋ฒํธ ์ ์
/opt/xcat/etc/networks.tab dhcp์์ ์ ์ํ๋ ๋ชจ๋ ๋คํธ์ํฌ๋ฅผ ์ ์
* /opt/xcat/etc/์์ ํ์ผ ์์ ํ setupxcat๋ช ๋ น์ ์คํํด์ผ ๋ณ๊ฒฝ๋ ์ค์ ์ด ๋ฐ์๋จ
[root@mgt etc]# cat site.tab sshkeyver 1
rsh /usr/bin/ssh
rcp /usr/bin/scp
gkhfile /opt/xcat/etc/gkh
tftpdir /tftpboot
tftpxcatroot xcat
domain cluster.com
dnssearch cluster.com
nameservers 192.168.12.74
forwarders NA
nets 192.168.12.0:255.255.255.0,192.168.70.0:255.255.255.0
dnsdir /var/named
dnsallowq NA
domainaliasip NA
mxhosts mailhosts.cluster.com
mailhosts mgt
master mgt
homefs mgt:/home
localfs mgt:/usr/local
pbshome /var/spool/pbs
pbsprefix /opt/pbs
pbsserver mgt
scheduler maui
xcatprefix /opt/xcat
keyboard us
timezone US/Eastern
offutc -5
mapperhost mgt
serialmac 0
serialbps 19200
snmpc public
snmpd 192.168.12.74
poweralerts Y
timeservers mgt
logdays 7
installdir /install
clustername wopr
dhcpver 3
dhcpconf /etc/dhcpd.conf
dynamicr eth0,ia32,192.168.12.74,255.255.255.0,192.168.12.1,192.168.12.254
usernodes NA
usermaster mgt
nisdomain NA
nismaster NA
nisslaves NA
homelinks NA
chagemin 0
chagemax 60
chagewarn 10
IBM System x Enterprise Architecture Linux Advanced Management
- 13 -
chageinactive 0
mpcliroot /opt/xcat/lib/mpcli
ipmimaxp 16
ipmitimeout 30
dpcliroot /opt/xcat/i686
ipmitool /opt/xcat/i686/sbin/ipmitool
myrimask 255.255.0.0
mpicli2root /opt/xcat/lib/mpicli2
ipmiretries 2
xcatdport 3001
[root@mgt etc]# cat nodelist.tab #node1 all,compute,opteron,rack1
blade1 all,compute,blade,box1
blade2 all,compute,blade,box1
blade3 all,compute,blade,box1
blade4 all,compute,blade,box1
sw1 sw
bc1 bc
[root@mgt etc]# cat noderes.tab all mgt,mgt,/install,1,N,N,N,N,N,N,N,eth0,eth0
[root@mgt etc]# cat nodetype.tab blade1 rhas4,x86_64,blade
blade2 rhas4,x86_64,blade
blade3 rhas4,x86_64,blade
blade4 rhas4,x86_64,blade
[root@mgt etc]# cat nodehm.tab #node1 openipmi,openipmi,NA,openipmi,NA,conserver,NA,openipmi,rcons,pxe,bcm5700,vnc,Y,openipmi,NA,9600
blade1 mp,mp,NA,mp,mp,conserver,mp,mp,bcmm,pxe,bcm5700,NA,N,mp,mp,NA Blade Center์ฉ
blade2 mp,mp,NA,mp,mp,conserver,mp,mp,bcmm,pxe,bcm5700,NA,N,mp,mp,NA
blade3 mp,mp,NA,mp,mp,conserver,mp,mp,bcmm,pxe,bcm5700,NA,N,mp,mp,NA
blade4 mp,mp,NA,mp,mp,conserver,mp,mp,bcmm,pxe,bcm5700,NA,N,mp,mp,NA
node001 ipmi,ipmi,ipmi,ipmi,ipmi,conserver,NA,ipmi,switch,pxe,bcm5700,vnc,Y,ipmi,NA,19200 BMC์ฉ
node01 mp,mp,mp,mp,mp,conserver,rcons,mp,rcons,pxe,eepro100,vnc,N RSA์ฉ
bc1 NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,NA,N,NA,NA
[root@mgt etc]# cat nodemodel.tab blade1 blade
blade2 blade
blade3 blade
blade4 blade
[root@mgt etc]# cat mac.tab blade1-eth0 00:11:25:9E:A7:BA
blade1-eth1 00:11:25:9E:A7:BB
blade2-eth0 00:11:25:9E:A7:B0
blade2-eth1 00:11:25:9E:A7:B1
IBM System x Enterprise Architecture Linux Advanced Management
- 14 -
blade3-eth0 00:11:25:9E:A7:DE
blade3-eth1 00:11:25:9E:A7:DF
blade4-eth0 00:11:25:9E:AA:A2
blade4-eth1 00:11:25:9E:AA:A3
[root@mgt etc]# cat conserver.cf LOGDIR=/var/log/consoles
blade1:|sol.bc blade1::&: Blade Center์ฉ
blade2:|sol.bc blade2::&:
blade3:|sol.bc blade3::&:
blade4:|sol.bc blade4::&:
node001:|sol.e326 node001::&: BMC์ฉ
node01:!ts01:3001:&: RSA์ฉ
%%
trusted: 127.0.0.1
[root@mgt etc]# cat conserver.tab # conserver.tab
#
# This table defines the relationship between nodes and console servers.
#
# <conserver> hostname of the console server
# <console> name of the console that corresponds to conserver.cf
#<node> <conserver>,<console>
blade1 localhost,blade1
blade2 localhost,blade2
blade3 localhost,blade3
blade4 localhost,blade4
conserver.tab~ mpa.tab nodehm.tab~ nodetype.tab site.tab.ORG
[root@mgt etc]# cat mpa.tab
# mpa.tab
#
# This table lists the Management Processor Adapters and Modules.
#
# <type> asma,rsa,rsa2,bc
# <name> internal name (*)
# <number> internal number,unique and >10000 (asma, rsa only)
# <command> telnet,mpcli,http(hawk only) (bc must be http)
# <reset> http(hawk only),mpcli,NA
# <rvid> telnet(asma only),NA
# <dhcp> Y/N (rsa only)
# <gateway> default gateway IP address or NA or using DHCP
# <dns> DNS server or NA if using DHCP
#
# NOTE: command and reset method should not be the same, if the
# command interface is locked of unavailable, a different
# interface must be used. Please read the
# managementprocessor-HOWTO.html
#
# (*)internal name should be the node name if the mpa is the
# primary management adapter for that node
IBM System x Enterprise Architecture Linux Advanced Management
- 15 -
#
#<node> <type>,<name>,<number>,<command>,<reset>,<rvid>,<dhcp>,<gateway>,<dns>
#
bc1 bc,bc1,NA,http,http,mpcli,NA,NA,NA
[root@mgt etc]# cat mpa.tab # mpa.tab
#
# This table lists the Management Processor Adapters and Modules.
#
# <type> asma,rsa,rsa2,bc
# <name> internal name (*)
# <number> internal number,unique and >10000 (asma, rsa only)
# <command> telnet,mpcli,http(hawk only) (bc must be http)
# <reset> http(hawk only),mpcli,NA
# <rvid> telnet(asma only),NA
# <dhcp> Y/N (rsa only)
# <gateway> default gateway IP address or NA or using DHCP
# <dns> DNS server or NA if using DHCP
#
# NOTE: command and reset method should not be the same, if the
# command interface is locked of unavailable, a different
# interface must be used. Please read the
# managementprocessor-HOWTO.html
#
# (*)internal name should be the node name if the mpa is the
# primary management adapter for that node
#
#<node> <type>,<name>,<number>,<command>,<reset>,<rvid>,<dhcp>,<gateway>,<dns>
#
bc1 bc,bc1,NA,http,http,mpcli,NA,NA,NA Blade Center์ฉ
bmc001 bmc,bmc001,NA,mpcli,mpcli,mpcli,NA,172.29.0.1,NA BMC์ฉ
rsa01 rsa,rsa01,10001,mpcli,mpcli,NA,N,NA RSA์ฉ
[root@mgt etc]# cat mp.tab # mp.tab
#
# This table describes the topology of the Management Processor Network. This
# enables xcat to contact the management processors via the mpa connected to
# the same chain.
#
# <mpa> name of the mpa connected to this node
# <name> internal name of the mp adapter (*)
#
# (*)this field should be NA if the mpa is the primary management
# adapter for that node
#
#<node> <mpa>,<name>
#node10 rsa1,node10
#
# This table maps nodes to node chassis.
#
# <bc> hostname of the node chassis management module.
# <bay> position of the node. DO NOT PAD WITH ZEROS.
#
IBM System x Enterprise Architecture Linux Advanced Management
- 16 -
#<node> <bc>,<bay>
blade1 bc1,1 Blade Center์ฉ
blade2 bc1,2
blade3 bc1,3
blade4 bc1,4
node001 bmc001,node001 BMC์ฉ
node01 rsa01,node01 RSA์ฉ
[root@mgt etc]# cat bcnet.tab blade1 sw1,1
blade2 sw1,2
blade3 sw1,3
blade4 sw1,4
[root@mgt etc]# cat networks.tab # networks.tab
#
#network mask,gateway,dns,dns,dns,...
192.168.12.0 255.255.255.0,NA,192.168.12.74
192.168.70.0 255.255.255.0,NA,192.168.12.74
169.254.0.0 255.255.0.0,NA,NA
2) blade์๋ฒ kickstart file ์์ฑ(kicstart templateํ์ผ์ blade.tmpl์ด๋ฆ์ผ๋ก ๋ณต์ฌํ์ฌ ์ฌ์ฉํ๋ค.)
[root@mgt base]# cd /opt/xcat/install/rhas4/x86_64/base
[root@mgt base]# cp all.tmpl blade.tmpl
3) makedns -- site.tab ๋ฐ hostํ์ผ์ ์ฐธ์กฐํ์ฌ named.confํ์ผ ์์ฑ
[root@mgt xcat]# makedns
Stopping named: [ OK ]
named: no process killed
Starting named: [ OK ]
4) makedhcp โ site.tab,networks.tab,hostsํ์ผ์ ์ฐธ์กฐํ์ฌdhcp.confํ์ผ ์์ฑ
[root@mgt xcat]# makedhcp โnew
updating existing /opt/xcat/etc/networks.tab
skipping 172.30.0.0 (entry exists)
skipping 172.29.0.0 (entry exists)
skipping 169.254.0.0 (entry exists)
skipping 172.20.0.0 (entry exists)
Saving orginal /etc/dhcpd.conf as /etc/dhcpd.conf.ORIG
added network eth0
added network eth1
updated /etc/sysconfig/dhcpd with DHCPD_INTERFACE or DHCPDARGS="eth0 eth1"
added network all
added subnet 172.20.0.0/255.255.0.0
added subnet 172.29.0.0/255.255.0.0
added subnet 172.30.0.0/255.255.0.0
added subnet 169.254.0.0/255.255.0.0
adding dynamic eth0
Shutting down dhcpd: [ OK ]
Starting dhcpd: [ OK ]
IBM System x Enterprise Architecture Linux Advanced Management
- 17 -
5) mkstage -- stage1
[root@mgt stage]# cd /opt/xcat/stage/
[root@mgt stage]# ./mkstage
- mkstage๋ช ๋ น์ผ๋ก /tftpboot/xcat๋๋ ํ ๋ฆฌ์์ pxelinux์ผ๋ก os๋ฅผ ์ค์นํ๊ธฐ ์ํ kernel๋ฐ ramdisk image, ์ค์ ํ์ผ๋ค์ด ๋ง๋ค
์ด์ง
6) getmacs <nodereange> -- stage2
* blade์๋ฒ์ mac address๋ฅผ ์์งํ์ฌ mac.tab์ ์ถ๊ฐํ๋ค.
[root@mgt stage]# getmacs box1
Please reset nodes: blade1 blade2 blade3 blade4 blade5 blade6 blade7 blade8 blade9
blade10 blade11 blade12 blade13 blade14
Press [Enter] when ready...
Saving output to mac-16754.lst in current directory /opt/xcat/stage.
blade1-eth0 00:14:5E:D5:D0:46
blade1-eth1 00:14:5E:D5:D0:48
blade10-eth0 00:14:5E:D5:E3:54
blade10-eth1 00:14:5E:D5:E3:56
blade11-eth0 00:14:5E:D5:E4:F2
blade11-eth1 00:14:5E:D5:E4:F4
blade12-eth0 00:14:5E:D5:CF:86
blade12-eth1 00:14:5E:D5:CF:88
blade13-eth0 00:14:5E:D5:D3:2E
blade13-eth1 00:14:5E:D5:D3:30
blade14-eth0 00:14:5E:D5:E2:28
blade14-eth1 00:14:5E:D5:E2:2A
blade2-eth0 00:14:5E:D5:DB:86
blade2-eth1 00:14:5E:D5:DB:88
blade3-eth0 00:14:5E:D5:D9:E8
blade3-eth1 00:14:5E:D5:D9:EA
blade4-eth0 00:14:5E:D5:DB:E6
blade4-eth1 00:14:5E:D5:DB:E8
blade5-eth0 00:14:5E:D5:D3:B2
blade5-eth1 00:14:5E:D5:D3:B4
blade6-eth0 00:14:5E:D5:E4:08
blade6-eth1 00:14:5E:D5:E4:0A
Auto merge mac-16754.lst with /opt/xcat/etc/mac.tab(y/n)? y
7) makedhcp --allmac
* ์ด์ ์ ๋ง๋ค์๋ dhcpd.confํ์ผ์ ๊ฐ host์ mac address๋ฅผ ์ถ๊ฐํ์ฌ ์ฌ ์์ฑ
[root@mgt stage]# makedhcp --allmac
updating existing /opt/xcat/etc/networks.tab
skipping 172.30.0.0 (entry exists)
skipping 172.29.0.0 (entry exists)
skipping 169.254.0.0 (entry exists)
skipping 172.20.0.0 (entry exists)
updated /etc/sysconfig/dhcpd with DHCPD_INTERFACE or DHCPDARGS="eth0 eth1"
8) mpacheck โl <mm range>(BladeCenter mm ์ฒดํฌ)
[root@mgt stage]# mpacheck -l bc1
bc1: Host IP Address: 172.30.101.5
bc1: Subnet mask: 255.255.0.0
IBM System x Enterprise Architecture Linux Advanced Management
- 18 -
bc1: Gateway IP Address: 0.0.0.0
bc1: Data Rate: Auto
bc1: Duplex Mode: Auto
bc1: SNMP Traps: Enabled
bc1: SNMP Agent: Enabled
bc1: SNMP Community Name: public
bc1: SNMP IP Address 1: 0.0.0.0
9) mpname <noderange> -- stage3
* ๊ฐ blade๋ค์ hardeware management processor๋ฅผ rename ํ๋ค.
[root@mgt stage]# mpname box1
blade1: blade bc1,1 renamed from blade1 to blade1
blade10: blade bc1,10 renamed from blade10 to blade10
blade11: blade bc1,11 renamed from blade11 to blade11
blade12: blade bc1,12 renamed from blade12 to blade12
blade13: blade bc1,13 renamed from blade13 to blade13
blade14: blade bc1,14 renamed from blade14 to blade14
blade2: blade bc1,2 renamed from blade2 to blade2
blade3: blade bc1,3 renamed from blade3 to blade3
blade4: blade bc1,4 renamed from blade4 to blade4
blade5: blade bc1,5 renamed from blade5 to blade5
blade6: blade bc1,6 renamed from blade6 to blade6
blade7: blade bc1,7 renamed from blade7 to blade7
blade8: blade bc1,8 renamed from blade8 to blade8
blade9: blade bc1,9 renamed from blade9 to blade9
10) mpascan <mm range>
* ๋ชจ๋ blade์๋ฒ ์ด๋ฆ๋ค์ด ์ค์ tab์ ์ ์๋์๋์ง๋ฅผ ํ์ธ
[root@mgt stage]# mpascan bc1
bc1: blade1 1
bc1: blade10 10
bc1: blade11 11
bc1: blade12 12
bc1: blade13 13
bc1: blade14 14
bc1: blade2 2
bc1: blade3 3
bc1: blade4 4
bc1: blade5 5
bc1: blade6 6
bc1: blade7 7
bc1: blade8 8
bc1: blade9 9
11) RHEL AS4 CD ๋ด์ฉ์ Management node์ ๋ณต์ฌํ๋ค.
[root@mgt etc]# copycds
Please insert CD 1 and press [Enter]...
- ์๋์ ์ผ๋ก /install/rhas4/x86_64 ๋๋ ํ ๋ฆฌ ์์ฑ๊ณผ ํจ๊ป CD๋ด์ฉ์ ๋๋ ํ ๋ฆฌ์ ๋ณต์ฌํ๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 19 -
12) post ๋๋ ํ ๋ฆฌ ๋ณต์ฌ
[root@mgt /]# cd /opt/xcat
[root@mgt xcat]# find post -print | cpio -dump /install
13) management node ssh key์์ฑ
[root@mgt xcat]# gensshkeys root
[root@mgt xcat]# cp /root/.ssh/* /install/post/.ssh/ -f
- * management node ์ ssh โ key ๋ฅผ ์์ฑํ์ฌ /install ์ ๋๊ณ ๊ฐ ๊ณ์ฐ ๋ ธ๋๋ค์ด ์ค์น๋ฅผ ํ ๋์
~/.ssh/๋๋ ํ ๋ฆฌ์์ ๋ณต์ฌ๋ฅผ ํด์ ์ฌ์ฉํ ์ ์๋๋ก ํจ
14) conserver ๋ฐ๋ชฌ ์์
[root@mgt /]# service conserver start
Starting Console Server: [ OK ]
15) NFS ์๋ฒ ์ค์
[root@mgt /]# vi /etc/exports
/opt/xcat *(ro,no_root_squash,sync)
/install *(ro,no_root_squash,sync)
/tftpboot *(ro,no_root_squash,sync)
[root@mgt /]# chkconfig nfs on
[root@mgt /]# service nfs start
Starting NFS services: [ OK ]
Starting NFS quotas: [ OK ]
Starting NFS daemon: [ OK ]
Starting NFS mountd: [ OK ]
[root@mgt /]# exportfs
/opt/xcat <world>
/tftpboot <world>
/install <world>
16) rinstall <node range>
* /tftpboot/pxelinux.cfg/์์ node์ด๋ฆ๋ณ๋ก pxelinux๊ด๋ จ ํ์ผ๋ค์ด ์์ฑ๋๋ฉด์
node์ค์น๊ฐ ์งํ๋๋ค.
[root@mgt /]# rinstall blade253
blade253: install rhas4-x86_64-blade-all
blade253: ********
[root@mgt pxelinux.cfg]# ls
AC14 AC147709 AC14770D AC147C02 AC147C06 blade256
AC140A08 AC14770A AC14770E AC147C03 AC147C07 blade243
AC14760A AC14770B AC147908 AC147C04 AC147C08 blade254
AC147708 AC14770C AC147C01 AC147C05 AC147C09 blade255 default
IBM System x Enterprise Architecture Linux Advanced Management
- 20 -
17) tty console๋ฅผ ์ฌ์ฉํ์ฌ node์ค์น ํ์ธ
[root@mgt ~]# wcons โt blade253 (console open)
[root@mgt ~]# wkill blade253 (console close)
- console font ๋ฐ size์กฐ์
* ctrol key + mouse right button ํด๋ฆญ
18) makesshgkh <noderange>
* ์ค์น ์๋ฃ ํ node๋ค์ ssh key๊ฐ์ ์ค์บํ์ฌ ์ ํฉ์ฑ์ ์ฒดํฌํ๋ค.
[root@mgt ~]# makesshgkh blade1-blade14
Scanning keys, please wait...
IBM System x Enterprise Architecture Linux Advanced Management
- 21 -
1.10 xCAT ์ค์ ๋ช ๋ น์ด
xCAT ๊ด๋ จํ ๋ชจ๋ ๋ช ๋ น์ด๋ค์ /opt/xcat/sbin ๋๋ /opt/xcat/bin ๋๋ ํ ๋ฆฌ ์์ ์ ์๋์ด ์๋ค.
ํ์ง๋ง ๋ช๋ช ๋ช ๋ น์ด๋ค์ xCAT ์คํฌ๋ฆฝํธ์์๋ง ์ฌ์ฉ๋๋ฉฐ, ๊ทธ ์ธ ๋ค๋ฅธ ๋ช ๋ น์ด๋ค์ ํด๋ฌ์คํฐ ํ๊ฒฝ์ ๊ด๋ฆฌ
ํ๋ ๋ด๋น์๋ ํด๋ฌ์คํฐ๋ฅผ ์ด์ฉํ์ฌ Job์ ์ํํ๊ณ ์ ํ๋ User์ ์ํด ์ฌ์ฉ๋ ์ ์๋ค. ์ฌ๊ธฐ์๋ ์ฃผ
๋ก ์ฌ์ฉ๋๋ ๋ช ๋ น์ด์ ๋ํด ์ค๋ช ํ๊ณ ์ ํ๋ค.
1. rpower - Remote power control
xCAT์ ์ค์ ํ์ผ์ธ nodelist.tab ํ์ผ์ ์ ์๋์ด ์๋ node๋ค์ ์ ์๊ด๋ฆฌ๋ฅผ ์๊ฒฉ์์ On/Off/Reset
ํ ์ ์๋๋ก ํจ
Synopsis rpower [noderange] [on|off|stat|state|reset|boot|cycle]
Options on Turn power on
off Turn power off
stat | state Return the current power state
reset Send a hardware reset
boot If off, then power on. If on, then hard reset
cycle Power off, then on
Examples [root@mgt ~]# rpower blade1-blade14 stat blade1~14๊น์ง ์ ์์ํ ํ์ธ
[root@mgt ~]# rpower blade7 on blade7 ์๋ฒ ์ ์์ On ์ํด
[root@mgt ~]# rpower box22 reset Chassis 22๋ฒ ์ ์๋ฒ์ ์ ์์ Reboot ์ํด
[root@mgt ~]# rpower all off ์ ์์คํ ์ ์ ์์ Off ์ํด
2. rinstall - Remote network install
xCAT์ ์ค์ ํ์ผ์ธ nodetype.tab ํ์ผ์ ์ ์๋์ด ์๋ ์ฌํญ์ ๋ง๊ฒ node๋ค์ ์ค์น๋ฅผ ์๊ฒฉ์์
์งํ ์ํด. (๋จ, ์ค์น ์งํ๋๋ ํ๋ฉด์ ํ์ธํ ์ ์์ผ๋ฉฐ, ์งํ์ฌํญ์ ๋ณด๊ณ ์ ํ ๊ฒฝ์ฐ console server๋ฅผ
ํตํด์ ๋ณผ ์ ์์.)
Synopsis rinstall [noderange]
Examples [root@mgt ~]# rinstall blade1-blade14 blade1~14๊น์ง ์๊ฒฉ ์ค์น ์งํ
[root@mgt ~]# rinstall box10 Chassis 11๋ฒ ์ ์๋ฒ์ ์๊ฒฉ ์ค์น ์งํ
3. wcons - Windowed remote console
xCAT์ ์ค์ ํ์ผ์ธ conserver.tab ํ์ผ์ ์ ์๋์ด ์๋ node๋ค์ Serial ์ฐ๊ฒฐ ํ๋ฉด์ ์ ๊ณตํ์ฌ ์ค.
Synopsis rpower [noderange] [on|off|stat|state|reset|boot|cycle]
Options -t|-tile|--tile n ์ฐฝ์ ์ผ์ชฝ ์์์๋ถํฐ ์ผ์ชฝ์์ ์ค๋ฅธ์ชฝ์ผ๋ก ํด๋น node๋ค์ xWindow
์ฐฝ์ ๋ณด์ฌ์ค๋ค. โnโ ์ ํ ํ์์ ๋ณด์ฌ์ค ์ ์๋ tile์ ์๋ฅผ ์ ์ํจ.
-f|-font|--font font wcons ํ๋ฉด๋ค์ font๋ฅผ ์ง์ ํจ. (์ฃผ๋ก ํ๋ฉด์ฐฝ์์ ctrl + right click์ผ
๋ก ์กฐ์ ์ด ๊ฐ๋ฅํ๋ค.)
wcons๊ฐ ์ง์ํ๋ font alias๋ ์๋์ ๊ฐ๋ค.
verysmall | vs = nil2
small|s = 5x8
medium | med|m = 6x13
IBM System x Enterprise Architecture Linux Advanced Management
- 22 -
large | l | big | b = 7x13
verylarge | vl | verybig | vb = 10x20
Examples [root@mgt ~]# wcons blade7 blade7์ Serial Consoleํ๋ฉด์ ๋ณด์ฌ์ค.
[root@mgt ~]# wcons โt 3 box1 Chassis 1๋ฒ์ Serial Consoleํ๋ฉด์ 3๊ฐ ๋จ์๋ก ๋ณด์ฌ์ค.
* ํ๋ฉด ํฌ๊ธฐ ์กฐ์ (wcons ํ๋ฉด์์ ctrl + mouse right click)
4. wkill - Windowed remote console kill
wcons ๋ช ๋ น์ด๋ฅผ ํตํด ๋์ด ์ฐฝ์ ์์ ๊ณ ์ ํ ๋ ์ฌ์ฉ.
Synopsis wkill [noderange]
Examples [root@mgt ~]# wkill blade1-blade14 blade1~14์ Console ํ๋ฉด์ ์์ค๋ค.
[root@mgt ~]# wkill box10 Chassis 10๋ฒ์ ํด๋นํ๋ Console ํ๋ฉด์ ์์ค๋ค.
5. winstall - Windowed remote network install
xCAT์ ์ค์ ํ์ผ์ธ nodetype.tab ํ์ผ์ ์ ์๋์ด ์๋ ์ฌํญ์ ๋ง๊ฒ node๋ค์ ์ค์น๋ฅผ ์๊ฒฉ์์
์งํ ์ํค๋ฉฐ, winstall ๋ช ๋ น์ด ์คํ ์ wcons ๋ช ๋ น์ด๋ฅผ ๋์์ ์คํ์์ผ ์ค์น ํ๋ฉด์ Serial
Consoleํ๋ฉด์ ํตํด์ ํ์ธ ๊ฐ๋ฅ์ผ ํจ.
Synopsis winstall [{-t|-tile|--tile} n | {-t|-tile|--tile}=n] [{-f|-font|--font} font | {-f|-font|-
IBM System x Enterprise Architecture Linux Advanced Management
- 23 -
-font}=font] noderange
Options -t|-tile|--tile n ์ฐฝ์ ์ผ์ชฝ ์์์๋ถํฐ ์ผ์ชฝ์์ ์ค๋ฅธ์ชฝ์ผ๋ก ํด๋น node๋ค์
xWindow ์ฐฝ์ ๋ณด์ฌ์ค๋ค. โnโ ์ ํ ํ์์ ๋ณด์ฌ์ค ์ ์๋ tile์
์๋ฅผ ์ ์ํจ.
-f|-font|--font font wcons ํ๋ฉด๋ค์ font๋ฅผ ์ง์ ํจ. (์ฃผ๋ก ํ๋ฉด์ฐฝ์์ ctrl + right
click์ผ๋ก ์กฐ์ ์ด ๊ฐ๋ฅํ๋ค.)
wcons๊ฐ ์ง์ํ๋ font alias๋ ์๋์ ๊ฐ๋ค.
verysmall | vs = nil2
small|s = 5x8
medium | med|m = 6x13
large | l | big | b = 7x13
verylarge | vl | verybig | vb = 10x20
Examples [root@mgt ~]# winstall blade1-blade14
blade1~14๊น์ง ์๊ฒฉ ์ค์น๋ฅผ ์งํํ๊ณ Serial Console ํ๋ฉด์ ๋์์ค
[root@mgt ~]# winstall box22
Chassis 22๋ฒ ์ ์๋ฒ์ ๋ํ ์ค์น๋ฅผ ์งํํ๊ณ Serial Console ํ๋ฉด์ ๋์์ค
6. psh - Parallel remote shell
Cluster User๋ค์ด ๊ฐ์ฅ ๋ง์ด ์ฌ์ฉํ๋ ๋ช ๋ น์ด๋ก, xCAT์ ์ค์ ๋์ด ์๋ node๋ค์ ๋์์ ๋์ผํ
๋ช ๋ น์ด๋ฅผ ์คํํ๊ณ ์ ํ ๋ ์ฌ์ฉ (rsh๋ฅผ ์ฌ์ฉํ ์ง ssh๋ฅผ ์ฌ์ฉํ ์ง๋ site.tab ํ์ผ์ ์ ์๋์ด์์)
Synopsis psh [-s] [noderange|me|pbs job id] [command]
Options -s Issues the commands serially.
Examples [root@mgt ~]# psh box1-box5 ls Chassis 1~5๋ฒ์ ํด๋น๋๋ ์๋ฒ๋ค์๊ฒ ๋์์ ls๋ช ๋ น์คํ
[root@mgt ~]# psh blade3,blade5 date Blade 3,5๋ฒ ์๋ฒ์๊ฒ ๋์์ date ๋ช ๋ น์คํ
7. pping - Parallel ping
xCAT์ ์ค์ ๋์ด ์๋ node๋ค์ ๋์์ ping ๋ช ๋ น์ด๋ฅผ ์คํํ๊ณ ์ ํ ๋ ์ฌ์ฉ
Synopsis pping [-s] [noderange]
Options -s Issues the commands serially.
Examples [root@mgt ~]# pping blade1-blade20 Blade 1~20๋ฒ์ ํด๋น๋๋ ์๋ฒ์ ping๋ช ๋ น ๋์์คํ
[root@mgt ~]# pping box25 Chassis 25๋ฒ ์๋ฒ์ ping๋ช ๋ น ๋์์คํ
8. prcp - Parallel remote copy
Cluster User๋ค์ด ๊ฐ์ฅ ๋ง์ด ์ฌ์ฉํ๋ ๋ช ๋ น์ด๋ก, xCAT์ ์ค์ ๋์ด ์๋ node๋ค์ ๋์์ ๋์ผํ
๋ช ๋ น์ด๋ฅผ ์คํํ๊ณ ์ ํ ๋ ์ฌ์ฉ (rsh๋ฅผ ์ฌ์ฉํ ์ง ssh๋ฅผ ์ฌ์ฉํ ์ง๋ site.tab ํ์ผ์ ์ ์๋์ด์์)
9. rinv - Remote hardware inventory
Onboard์ ์๋ ๊ด๋ฆฌ ํ๋ก์ธ์ค๋ฅผ ํตํด ํ๋์จ์ด ๊ตฌ์ฑ ์ ๋ณด๋ฅผ ํ์ธ.
Synopsis rinv [noderange] [pci|config|model|serial|asset|vpd|bios|mprom|all]
Options pci PCI bus ์ ๋ณด ์ถ์ถ.
config Processor ์๋, speed, total memory, DIMM locations ์ ๋ณด ์ถ์ถ
model model number ์ถ์ถ.
serial serial number ์ถ์ถ.
asset Eth0 MAC address ์ถ์ถ
vpd BIOS level, management processor, firmware level ์ถ์ถ
IBM System x Enterprise Architecture Linux Advanced Management
- 24 -
bios BIOS level ์ ๋ณด ์ถ์ถ.
mprom management processor firmware level ์ ๋ณด ์ถ์ถ
all ์์ ๋ชจ๋ ์ ๋ณด ์ถ์ถ
Examples [root@mgt ~]# rinv blade5 bios blade5์ BIOS ์ ๋ณด ์ถ์ถ
[root@mgt ~]# rinv box23 all Chassis 23๋ฒ์ ๋ชจ๋ ํ๋์จ์ด ๊ตฌ์ฑ ์ ๋ณด ์ถ์ถ
10. bwatch โ Blade Watch
๊ฐ Blade Server์ ๋ํ ๊ฐ๋จํ ์์คํ ์ฌ์ฉ ์ ๋ณด๋ฅผ GUIํ๋ฉด์ ํตํด ํ์ธ
Synopsis bwatch [noderange]
Examples [root@mgt ~]# bwatch box1 Chassis 1๋ฒ์ ํด๋น๋๋ ์๋ฒ๋ค์ ์์คํ ์ ๋ณด ํ์ธ
[root@mgt ~]# bwatch blade3 Blade 3๋ฒ ์๋ฒ์ ์์คํ ์ ๋ณด ํ์ธ
11. rbootseq - Remote boot sequence
BIOS์์์ boot sequence๋ฅผ ๋ณ๊ฒฝํ์ง ์๊ณ ๋ช ๋ น์ด๋ฅผ ํตํด boot priority๋ฅผ ๋ณ๊ฒฝ.
Synopsis Rbootseq [noderange] [{f|floppy,c|cdrom,n|network,hd{0,1}|harddisk{0,1}}|list]
Options f|floppy Floppy disk
c|cdrom CD-Rom
n|network PXE Network
hd{0,1}|harddisk{0,1} Hard Disk.
list ํ์ฌ boot sequence ํ์ธ
Examples [root@mgt ~]# rbootseq box1 n,c,hd0,f
Chassis 1๋ฒ์ Boot Sequence๋ฅผ ๋คํธ์ํฌ, CD-Rom, Hard Disk 0๋ฒ, Floppy Disk์ผ๋ก ๋ณ๊ฒฝ
[root@mgt ~]# rbootseq box23 list Chassis 23๋ฒ์ ๋ชจ๋ ์๋ฒ๋ค์ Boot Sequence ํ์ธ
IBM System x Enterprise Architecture Linux Advanced Management
- 25 -
2. HPC Software Stack Installation Guide
2.1 Intel C Compiler
intel CD๋ฅผ ์ฝ์ ํ๊ณ CD์ ์๋ ๋ฐ์ด๋๋ฆฌ๋ฅผ ํน์ ๋๋ ํ ๋ฆฌ๋ก ๋ณต์ฌํ๋ค. tar ์์ถ์ ํผํ ์ธ์คํจ ํ๋ก๊ทธ๋จ์ ์คํ์ํจ๋ค. [root@dmgt tmp]# tar xfz l_cc_c_9.1.045.tar.gz [root@dmgt tmp]# cd l_cc_c_9.1.045 [root@dmgt l_cc_c_9.1.045]# ./install.sh install ๋ฉ๋ด์์ 1๋ฒ์ ์ ํํ๋ค์, ๋ค์ ํ๋ฒ 1๋ฒ์ ์ ํํ๊ณ , ๋ผ์ด์ผ์คํ์ผ์ ์์น๋ฅผ ์ ์ด์ค๋ค. Please provide the license file name with full path (/<path>/<name>.lic) b. Go Back. x. Exit. License file path : /opt/intel/cpplicense.lic ์ดํ accept๋ฅผ ์ ๋ ฅํ๋ฉด ์ปดํ์ผ๋ฌ๊ฐ ์ค์น๋๋ค. ์ค์น๋ฅผ ๋ง์นํ, /opt/intel/cc๋ผ๋ ๋๋ ํ ๋ฆฌ๊ฐ ์ค์น๋์๋์ง ํ์ธํ ๋ค์ ์๋์ ๋ช ๋ น์ด๋ก ์ปดํ์ผ๋ฌ๊ฐ ์ ์์ ์ผ๋ก ์ค์น๋์๋์ง ํ์ธํ๋ค. [root@dmgt l_cc_c_9.1.045]source /opt/intel/cce/9.1.042/bin/iccvars.sh [root@blade329 ~]# icc icc: Command line error: no files specified; for help type "icc -help
2.2 Intel Fortran Compiler
intel CD๋ฅผ ์ฝ์ ํ๊ณ CD์ ์๋ ๋ฐ์ด๋๋ฆฌ๋ฅผ ํน์ ๋๋ ํ ๋ฆฌ๋ก ๋ณต์ฌํ๋ค. tar ์์ถ์ ํผํ ์ธ์คํจ ํ๋ก๊ทธ๋จ์ ์คํ์ํจ๋ค. [root@dmgt tmp]# tar xfz l_fc_c_9.1.040.tar.gz [root@dmgt tmp]# cd l_fc_c_9.1.040 [root@dmgt l_fc_c_9.1.040]# ./install.sh install ๋ฉ๋ด์์ 1๋ฒ์ ์ ํํ๋ค์, ๋ค์ ํ๋ฒ 1๋ฒ์ ์ ํํ๊ณ , ๋ผ์ด์ผ์คํ์ผ์ ์์น๋ฅผ ์ ์ด์ค๋ค. Please provide the license file name with full path (/<path>/<name>.lic)
b. Go Back. x. Exit.
License file path : /opt/intel/fclicense.lic ์ดํ accept๋ฅผ ์ ๋ ฅํ๋ฉด ์ปดํ์ผ๋ฌ๊ฐ ์ค์น๋๋ค. ์ค์น๋ฅผ ๋ง์นํ, /opt/intel/fc๋ผ๋ ๋๋ ํ ๋ฆฌ๊ฐ ์ค์น๋์๋์ง ํ์ธํ ๋ค์ ์๋์ ๋ช ๋ น์ด๋ก ์ปดํ์ผ๋ฌ๊ฐ ์ ์์ ์ผ๋ก ์ค์น๋์๋์ง ํ์ธํ๋ค. [root@dmgt tmp]source / source /opt/intel/cce/9.1.042/bin/iccvars.sh [root@ dmgt tmp]# ifc ifc: warning: The Intel Fortran driver is now named ifort. You can suppress this message with '-quiet' Ifort: Command line error: no files specified; for help type "ifort -help"
2.3 Intel MPI
intel CD๋ฅผ ์ฝ์ ํ๊ณ CD์ ์๋ ๋ฐ์ด๋๋ฆฌ๋ฅผ ํน์ ๋๋ ํ ๋ฆฌ๋ก ๋ณต์ฌํ๋ค. tar ์์ถ์ ํผํ ์ธ์คํจ ํ๋ก๊ทธ๋จ์ ์คํ์ํจ๋ค. [root@dmgt tmp]# tar xfz l_mpi_p_3.0.033.tar.gz [root@dmgt tmp]# cd l_mpi_p_3.0.033 [root@dmgt l_mpi_p_3.0.033]# ./install.sh install ๋ฉ๋ด์์ 1๋ฒ์ ์ ํํ๋ค์, ๋ค์ ํ๋ฒ 1๋ฒ์ ์ ํํ๊ณ , ๋ผ์ด์ผ์คํ์ผ์ ์์น๋ฅผ ์ ์ด์ค๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 26 -
Please provide the license file name with full path (/<path>/<name>.lic)
b. Go Back. x. Exit.
License file path : /opt/intel/mpilicense.lic ์ดํ accept๋ฅผ ์ ๋ ฅํ๋ฉด mpi๊ฐ ์ค์น๋๋ค. ์ค์น๋ฅผ ๋ง์นํ, /opt/intel/mpirun๋ผ๋ ๋๋ ํ ๋ฆฌ๊ฐ ์ค์น๋์๋์ง ํ์ธํ ๋ค์ ์๋์ ๋ช ๋ น์ด๋ก mpi๊ฐ ์ ์์ ์ผ๋ก ์ค์น๋์๋์ง ํ์ธํ๋ค. [root@dmgt tmp]source source /opt/intel/mpi/3.0/bin64/mpivars.sh [root@blade329 bin]# mpiexec | more usage: mpiexec [-h or -help or --help] # get this message
2.4 Intel MKL (Math Kernel Library)
intel CD๋ฅผ ์ฝ์ ํ๊ณ CD์ ์๋ ๋ฐ์ด๋๋ฆฌ๋ฅผ ํน์ ๋๋ ํ ๋ฆฌ๋ก ๋ณต์ฌํ๋ค. tar ์์ถ์ ํผํ ์ธ์คํจ ํ๋ก๊ทธ๋จ์ ์คํ์ํจ๋ค. [root@dmgt tmp]# tar xfz l_mkl_p_9.0.018.tar.gz [root@dmgt tmp]# cd l_mkl_p_9.0.018 [root@dmgt l_mkl_p_9.0.018]# ./install.sh install ๋ฉ๋ด์์ 1๋ฒ์ ์ ํํ๋ค์, ๋ค์ ํ๋ฒ 1๋ฒ์ ์ ํํ๊ณ , ๋ผ์ด์ผ์คํ์ผ์ ์์น๋ฅผ ์ ์ด์ค๋ค. Please provide the license file name with full path (/<path>/<name>.lic)
b. Go Back. x. Exit.
License file path : /opt/intel/mkllicense.lic ์ดํ accept๋ฅผ ์ ๋ ฅํ๋ฉด MKL์ด ์ค์น๋๋ค.
์ค์น๋ฅผ ๋ง์นํ /opt/intel/mkl์ด ์์ฑ๋์๋๋ฅผ ํ์ธํ๋ค.
2.5 PBS Pro
์ค์น๋ฅผ ์ํ๊ณ ์ํ๋ ๋ ธ๋์ dmgt์ /root/pspace/PBSPro_7.1๋ฅผ ๋ณต์ฌํด ์ค๋ค. root@dmgt#> scp /root/pspace/PBSPRo_7.1 blade1:/tmp ๋ณต์ฌํ ๋ ธ๋์ ๋ก๊ทธ์ธํํ ๋ณต์ฌํ ๋๋ ํ ๋ฆฌ๋ก ์ด๋ํ๋ค. root@dmgt#> ssh blade1 ๋ณต์ฌ๋ ๋๋ ํ ๋ฆฌ๋ก ์ด๋ํํ ์ค์น ๋ช ๋ น์ ์ํํ๋ค. root@blade1# PBSPro_7.1> ./INSTALL < install_mom ๊ฐ์ ๋๋ ํ ๋ฆฌ์ pbs.conf(๋๋ฒ๊ทธ ๋ ธ๋์ผ ๊ฒฝ์ฐ pbs_debug.conf )๋ฅผ /etc/์๋๋ก ๋ณต์ฌํํ pbs restart์์ผ์ค๋ค. root@blade1# PBSPro_7.1> cp pbs.conf /etc/pbs.conf root@blade1# PBSPro_7.1> service pbs restart
2.6 PBS Pro Check
Pbs server์์ ํต์ ํ์ธ
[root@blade328 scripts]# qstat -Bf
Server: schedule1
server_state = Active
server_host = schedule1
scheduling = True
total_jobs = 1
IBM System x Enterprise Architecture Linux Advanced Management
- 27 -
state_count = Transit:0 Queued:0 Held:1 Waiting:0 Running:0 Exiting:0 Begun
:0
acl_roots = root@schedule2,root@schedule1
default_queue = workq
log_events = 511
mail_from = adm
query_other_jobs = True
resources_default.ncpus = 1
default_chunk.ncpus = 1
scheduler_iteration = 600
FLicenses = 0
resv_enable = True
node_fail_requeue = 310
max_array_size = 10000
pbs_version = PBSPro_7.1.4.63140
pbs ๋ฐ๋ชฌ ์ํํ์ธ
[root@blade328 scripts]# pbsnodes blade328
blade328
Host = blade328
ntype = PBS
state = free
license = l
pcpus = 4
resources_available.arch = linux
resources_available.host = blade328
resources_available.mem = 8162496kb
resources_available.ncpus = 4
resources_assigned.mem = 0kb
resources_assigned.ncpus = 0
resv_enable = True
IBM System x Enterprise Architecture Linux Advanced Management
- 28 -
3. HPL Compile, Installation and Running BMT
3.1 HPC ์์คํ ์ ์ฑ๋ฅ์์น - FLOPS
์ํผ์ปดํจํฐ์์์ ์ฑ๋ฅ์ FLOPS(Floationg-point Operations Per Second : ์ด๋น ์ค์์ฐ์ฐ ํ์) 1์ด์
๋ง์ , ๋บ์ , ๊ณฑ์ , ๋๋์ ๋ฑ์ ์ค์ ๊ณ์ฐ์ ์ด ๋ช ๋ฒ ํ ์ ์๋์ง๋ฅผ ๋ํ๋ด๋ ๊ฐ์ด๋ค. ๋ง์ฝ 1์ด์ ์ค
์๋ผ๋ฆฌ ๊ณฑ์ ์ 2๋ฒ์ฉ ํ ์ ์๋ค๋ฉด ๊ทธ๋์ ๊ณ์ฐ ์๋๋ 2FLOPS๊ฐ ๋๋ ๊ฒ์ด๋ค.
3.2 ์ด๋ก ์ฑ๋ฅ vs ์ค์ ์ฑ๋ฅ ใ Rpeak vs Rmax
๊ทธ๋ผ ์ด์ ์ฑ๋ฅ์ ๋ํด ์์๋ดค์ผ๋ ์ด๋ป๊ฒ ์ฑ๋ฅ์ ์ธก์ ํ๋๊ฐ?์ ๋ํ ํด๋ต์ด ๋์์ผ ํ๋ค. ์ฑ๋ฅ์ ํฌ
๊ฒ ์ด๋ก ์ฑ๋ฅ๊ณผ ์ค์ ์ฑ๋ฅ์ผ๋ก ๋๋๋ค. ์ด๋ก ์ฑ๋ฅ(Rpeak)์ ๋ง ๊ทธ๋๋ก ์ด๋ก ์ ์ธ ์ฑ๋ฅ์ด๊ณ ์ค์ ์ฑ๋ฅ(Rmax)
์ ์ฌ๋ฌ๊ฐ์ง ํ ์คํธ๋ฅผ ํตํด ์ป์ด๋ธ ์ค์ ๋ก ์ธก์ ๋ ์ฑ๋ฅ์ด๋ค. ๊ทธ๋ผ ์ค์ ์ฑ๋ฅ์ ๊ตฌํ๊ธฐ ์ ์ ๋ด ํ๋์จ์ด
(CPU)๊ฐ ๋ผ ์ ์๋ ์ด๋ก ์ ์ธ ์ฑ๋ฅ์ ๊ณ์ฐํด ๋ณด๋๋ก ํ์. KIST ์ํผ์ปดํจํ ์ผํฐ์ QnA์ ์ฌ๋ผ์จ ๊ฒ์
์ธ์ฉํ์๋ฉด, ์ด๋ก ์ฑ๋ฅ์น, peak performance(Rpeak)๋ ์๋์ ์์ ํตํด ๊ตฌํ ์ ์๋ค.
Flop/s=(cycle/s)*(Flop/cycle)*(Number of pipes)
Pentium-IV 3GHz์ผ ๊ฒฝ์ฐ ia32(Itaium์ ์ ์ธํ intel, AMD์ ๋๋ถ๋ถ์ CPU) ์ํคํ ์ฒ ๊ณ์ด์ CPU๋ก
์ 1 cycle๋น (double precision) floating point ์ฐ์ฐ์ ์ต๋ 2๋ฒ ์ํํ ์ ์์ผ๋ฉฐ, vector ๊ณ์ด์ด ์๋
๋ฏ๋ก number of pipes๋ 1์ด๋ค. ๋ฐ๋ผ์ ์์์ ์ ์ฉํ๋ฉด
3(GHz/sec) * 2(Flop/Hz) * 1 = 6 GFlops
๋ฐ๋ผ์ ์์ ๊ฐ์ ๋ ธ๋๊ฐ 32๊ฐ ์ผ ๊ฒฝ์ฐ
32*6 = 192 Gflops ๊ฐ ๋์จ๋ค.
CPU๊ฐ Woodcrest ๋ชจ๋ธ์ผ ๋๋ 3(GHz/sec) * 4(Flop/Hz) * 1 = 12 GFlops๋ก ๊ณ์ฐ์ด ๋๋ค. ๋ง์ดํฌ๋ก ํ
๋ก์ธ์ค์ ์ํคํ ์ณ ๋ณํ๋ก ์ธํ์ฌ ํ ํด๋ญ๋น 4๊ฐ์ fp๋ช ๋ น์ด๋ฅผ ์ฒ๋ฆฌ ๊ฐ๋ฅํ๊ฒ ๋์๋ค.
1. ๋ช ๋ น์ด(instruction, mictor-op code)๋ฅผ 1Clock๋น 3๊ฐ์์ 4๊ฐ fetch, decode, issue, execution & retire 2. ๊ณผ๊ฑฐ์๋ fp ์ฐ์ฐ์ add or mul/div ์๋๋ฐ ์ง๊ธ์ add + mul/div ์ธ๊ตฌ์กฐ๋ก๋ณ๊ฒฝ๋์์ต๋๋ค. ์ฆ ๊ณผ๊ฑฐ์๋ add ์ mul/div ๋ฅผ ๋์์ ์ฒ๋ฆฌํ ์ ์์๋๋ฐ(๋์ค์ํ๋๋ง์ฒ๋ฆฌ), ์ง๊ธ์ add์ mul/div๋ฅผ ๋์์ ์ฒ๋ฆฌ ๊ฐ๋ฅํฉ๋๋ค. ๋ฐ๋ผ์ ํ๋ ฌ์ฐ์ฐ ๊ณผ ๊ฐ์ HPC application์์ 4๊ฐ์ fp ์ฒ๋ฆฌ๊ฐ ๊ฐ๋ฅํฉ๋๋ค.
3.3 HPL (High Performance Linpack)
ํํ ํด๋ฌ์คํฐ ์์คํ ์์ ๋ฒค์น๋งํฌ๋ LINPACK ์ ์ฌ์ฉํ๊ฑฐ๋ HPL(High-Performance Linpack
Benchmark)์ ํตํด์ ์์คํ ์ ์ค์ ์ฑ๋ฅ์ ์ธก์ ํ๊ฒ ๋๋ค. LINPACK ๋ฒค์น๋งํฌ ์์ ์ค์ ์ ์ผ๋ก
์ฌ์ฉ๋๋ ๋ฃจํด๋ค์ Gauss ์๊ฑฐ๋ฒ์ ์ด์ฉํ N ๊ฐ์ ์ ํ๋ฐฉ์ ์ ์ ํด๋ฅผ ๊ตฌํ๋ ๊ฒ์ผ๋ก BLAS (Basic
Linear Algebra Subprograms) ์ ํฌํจ๋์ด ์๋ค. BLAS ๋ LINPACK ๋ฒค์น๋งํฌ ์์ ๊ฐ์ฅ ๊ธฐ๋ณธ์ด ๋๋
๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ก์จ ๊ธฐ๋ณธ์ ์ธ ์ ํ๋์ ์ฐ์ฐํจ์ ๋ค์ ๊ตฌํํด๋์ ์งํฉ์ด๋ค. ์ด BLAS ๋ฅผ ์ด์ฉํด
๋ฒค์น๋งํน์ ํ ์๋ ์์ง๋ง ATLAS (Automatically Tuned Linear Algebra Software) ๋ฅผ ์ด์ฉํ์ฌ ํด๋น
ํ๋ซํผ์ ์ต์ ํ๋ ๋ฃจํด ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์์ฑ ํ ์๋ ์๋ค. HPL ์ ์ฌ์ฉํ๊ธฐ ์ํด์๋ MPI implementation
๊ณผ BLAS implementation ์ ํ์๋ก ํ๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 29 -
3.4 ์ ํ๋์ BLAS , ATLAS
BLAS (Basic Linear Algebra Subprograms)
์ ํ๋์(Linear Algebra) ๋ฌธ์ ์ ํด๋ฅผ ํจ์จ์ ์ผ๋ก ๊ตฌํ๊ธฐ ์ํ ๋ฐฉ๋ฒ์ ํ๋๋ Basic Linear Algebra
Subprograms(BLAS)๋ฅผ ์ด์ฉํ๋ ๊ฒ์ด๋ค. BLAS ๋ blocking ๊ธฐ๋ฒ์ ๋ฐํ์ผ๋ก ํ์ฌ ๊ธฐ๋ณธ์ ์ธ vector ์
matrix ์ฐ์ฐ์ ์ํํ๋ ์ญํ ์ ํ๋ค. BLAS ์๋ ์ฐ์ฐ์ ์ข ๋ฅ์ ๋ฐ๋ผ Level 1, 2, 3 BLAS ๋ก
๋๋์ด์ง๋ค. Level 1 BLAS ๋ vector-vector ์ฐ์ฐ์ ์ํํ๊ณ , Level 2 BLAS ๋ matrix-vector ์ฐ์ฐ,
Level 3 BLAS ๋ matrix-matrix ์ฐ์ฐ์ ํ๋๋ฐ ์ฌ์ฉ๋์ด์ง๋ค. BLAS ๋ ๋ฐ์ด๋ ํจ์จ๊ณผ ์ฐ์ํ
์ด์์ฑ์ ๋ฐํ์ผ๋ก LAPACK ๊ณผ ๊ฐ์ Linear Algebra Software ์ ๊ฐ๋ฐ์ ์ฌ์ฉ๋๊ณ ์๋ค. ํ์ฌ ๊ฐ๊ฐ์
architecture ์ hand-optimized BLAS ๊ฐ software vendor ๋ค์ ์ํด์ ๋ง๋ค์ด์ ธ ์๋ค. ๊ทธ๋ฌ๋ ์๋ก์ด
architecture ๋ง๋ค ์ต์ ํ๋ BLAS ๋ฅผ ๋ง๋๋ ์์ ์ ์๊ฐ์ด ๋ง์ด ๊ฑธ๋ฆด ๋ฟ๋ง ์๋๋ผ ๊ธ์ ์ ์ธ ๋ฌธ์ ๋
๊ฐ์ง๊ณ ์ ๋ค. ์ด๋ก ์ธํด Pentium/Linux architecture ๋ฅผ ์ํ ํจ์จ์ ์ธ matrix multiply ๋ฅผ ํ ์ ์๋
BLAS ๊ฐ ์์ง ๋ง๋ค์ด์ง์ง ์์๋ค. ๋ฐ๋ผ์ ์ค๋๋ ์ ๋ค์ํ Architecture ์์ ํจ์จ์ ์ผ๋ก ์ฌ์ฉ๋ ์
์๋ basic linear algebra routines ๋ฅผ ๋ง๋ค์ด์ฃผ๋ software ๊ฐ ํ์ํ๊ฒ ๋์๋ค. ์ด๋ฌํ ๋ชฉ์ ์
๋ฌ์ฑํ๊ธฐ ์ํ์ฌ ๋ง๋ ์ํํธ์จ์ด๊ฐ ๋ฐ๋ก ATLAS(Automatically Tuned Linear Algebra Software)์ด๋ค.
ATLAS (Automatically Tuned Linear Algebra Software)
ATLAS ๋ ๊ทธ ์ด๋ฆ์์๋ ์ ์ ์๋ฏ์ด ์ค๋๋ ์ microprocessor ์์ ๊ณ ๋์ ํจ์จ์ฑ์ ๋ฌ์ฑํ ์
์๋ basic linear algebra routine ์ ์ค์ค๋ก ๋ง๋ค ์ ์๋ software ์ด๋ค. ๋ฐ๋ผ์ ํ๋ก๊ทธ๋จ์ ํน์ฑ์
๋ฐ๋ผ, ๊ฐํ ์ด์์ฑ๊ณผ architecture ์ ํน์ฑ์ ๋ง๋ BLAS implementation ์ ์ ๊ณตํ๊ณ ์๋ค. ์ง๊ธ๋
๊พธ์คํ ์๋ก์ด ๋ฒ์ ์ ATLAS ๊ฐ ๋ง๋ค ์ด์ง๊ณ ์์ผ๋ฉฐ, C ์ Fortran77 interface ๋ฅผ ์ ๊ณตํ๊ณ ์๋ค.
ํ์ฌ ์์ ๋ฒ์ ์ 3.2.1 ๊น์ง, ๊ฐ๋ฐ์๋ฒ์ ์ 3.3.1 ๊น์ง ๋ง๋ค์ด์ ธ ์๋ค. ATLAS 3.2.1 ์์๋ Intel ์
SSE ์ AMD ์ 3DNOW ๋ฅผ ์ด์ฉํ์ฌ library ๋ฅผ ๋ง๋ค๊ณ ์์ผ๋ฉฐ, ATLAS 3.3.1 ์์๋ Intel ์ SSE,
SSE2 ์ AMD ์ 3DNOW, 3DNOW2 ๋ฅผ ๊ฐ๊ฐ ์ด์ฉํ๋๋ก ๋์ด์๋ค. ๋ฐ๋ผ์ ATLAS 3.2.1 ์ ์ฌ์ฉํ
Pentium III ์์๋ ๋จ์ ๋ ๋ถ๋์์์ (single precision floating point) ์ฐ์ฐ์ ์ฑ๋ฅ์ด ํ์ฐํ ์ข์์ง๊ณ ,
ATLAS 3.3.1 ์ ์ฌ์ฉํ Pentium4 ์์คํ ์์ SSE2 ๊ธฐ๋ฅ์ ํ์งํ์ฌ ์ฌ์ฉํจ์ผ๋ก์ ๋ฐฐ์ ๋
๋ถ๋์์์ (double precision floating point) ์ฐ์ฐ์์์ ์ฑ๋ฅ์ด ํ๊ธฐ์ ์ผ๋ก ๊ฐ์ ๋๋ ๊ฒ์ ํ์ธํ ์
์๋ค.
3.5 MPI (Message Passing Interface)
MPI ์ ์ข ๋ฅ์๋ ์ฌ๋ฌ ๊ฐ์ง๊ฐ ์์ง๋ง, Linux ์ฉ์ ํฌ๊ฒ ๋๊ฐ์ง ์ด๋ค. ๊ทธ ํ๋๊ฐ LAM/MPI ์ด๋ฉฐ, ๋
๋ค๋ฅธ ํ๋๋ MPICH ์ด๋ค. ์ด๋ฌํ MPI Library ์ ์ค์น๋ GNU Compiler ๋ฅผ ์ค์นํ ๋ ์ ๊ฐ์
configure , make, make install ์ ์ผ๋ จ์ ๊ณผ์ ์ ๊ฑฐ์น๋ฉฐ, ๋ค๋ฅธ ์ ์ configure ํ ๋์ option ์
์ฐจ์ด์ด๋ค. ํ 1 ์ ์ฌ์ฉ๋์ด์ง compiler ๊ทธ๋ฆฌ๊ณ ์ฌ์ฉ๋์ด์ง option ์ ๋ฐ๋ผ ์ค์น๋์ด์ง CUP ์ ๋ํ
MPI ๋ฅผ ๋ํ๋ด์๋ค.
MPI OPTION Compiler ๋น๊ณ
lam-gcc
(lam-6.5.6) --prefix=/usr/local/lam-gcc
gcc-
2.95.3
Smp machine:
--with-
IBM System x Enterprise Architecture Linux Advanced Management
- 30 -
lam-intel
(lam-6.5.6)
--prefix=/usr/local/lam --with-cc=icc --
with-fc=ifc --with-cflags=โ-unroll -axW -
tpp7 -alignโ --with-fflags=โ-unroll -axW -
tpp7 -alignโ
Intel
Compiler
rpi=usysv
์ถ๊ฐ
mpich-gcc
(mpich-
1.2.4)
--prefix=/usr/local/mpich-gcc gcc-
2.95.3
mpich-intel
(mpich-
1.2.4)
export CC=icc
export FC=ifc
export F90=ifc
--prefix=/usr/local/mpich-intel โwith-
comm=shared
Intel
Compiler
ํ 1 MPI Library
3.6 MPICH and LIbrary Installation
3.6.1 ์ฌ์ ์์คํ ๊ตฌ์ฑ ํ๊ฒฝ
์์คํ ์ด์ํ๊ฒฝ์ x86_64๋ฅผ ๊ธฐ๋ฐ์ผ๋ก ํ๋ ๋ฆฌ๋ ์ค ์์คํ ์ผ๋ก MPI์ฉ ๋คํธ์์ ๊ธฐ๊ฐ๋นํธ ์ด๋๋ท์
์ฌ์ฉํ์ฌ ์ด์์ฒด์ ๋ Redhat Enterprise Linux Update 4๋ฅผ ์ด์ฉํ์ฌ ์์คํ ์ ๊ตฌ์ฑํ์๋ค. ์์คํ
์ด์ํ๊ฒฝ์ ๋ํ ๊ตฌ์ฑ์ ๋ค์๊ณผ ๊ฐ๋ค.
3.6.2 MPICH Installation
GNU Compiler์ธ GCC ์ปดํ์ผ๋ฌ์ ๋ํ ํ๊ฒฝ๋ณ์ ๋ฐ ์ค์น์์น Path๋ฑ์ ๋ํ ํ๊ฒฝ๋ณ์๊ฐ
์ ์ ํ๊ฒ ๊ตฌ์ฑ๋์ด ์๋์ง ํ์ธํ์ฌ MPICH ์ ๋ํ ์ค์น๋ฅผ ์งํํ๋ค
# gcc โv Reading specs from /usr/lib/gcc/x86_64-redhat-linux/3.4.6/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --
IBM System x Enterprise Architecture Linux Advanced Management
- 31 -
enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=x86_64-redhat-linuxThread model: posix gcc version 3.4.6 20060404 (Red Hat 3.4.6-3)
* ์ปดํ์ผ๋ฌ์ ๋ํ ๊ธฐ๋ณธํ๊ฒฝ ๊ตฌ์ฑ ๋ฐ ํ๊ฒฝ๋ณ์ ํญ๋ชฉ๋ค์ด ์ ์์ ์ผ๋ก ํ์ธ๋์์ผ๋ฉด ์๋์ ๊ฐ์ด
MPICH ๋ณ๋ ฌ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ๊ธฐ๋ณธํ๊ฒฝ ๋ณ์๋ฅผ ๊ตฌ์ฑํด ์ค๋ค
# vi ~/.bashrc ...... # .bashrc # User specific aliases and functions alias rm='rm -i' alias cp='cp -i' alias mv='mv -i' # Source global definitions if [ -f /etc/bashrc ]; then . /etc/bashrc fi export MPICH="/usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh" export MPICH_PATH="${MPICH}/bin" export MPICH_LIB="${MPICH}/lib" export PATH="${MPICH_PATH}:${PATH}" export LD_LIBRARY_PATH="${MPICH_LIB}:${LD_LIBRARY_PATH}" MPICH ๋ณ๋ ฌ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ๊ธฐ๋ณธํ๊ฒฝ ๊ตฌ์ฑ * xCAT ๊ธฐ๋ณธ์ค์น ๋๋ ํ ๋ฆฌ์ธ /opt/xcat/build/mpi์ mpich tar๋ฅผ ํ์ผ์ ๋ณต์ฌํ์ฌ ์์ถ์ ํด์ (ex: NFS๋ก ๊ณต์ ๋ /opt/xcat/build/mpi์ mpimaker ๋ช ๋ น์ด๋ฅผ ์ด์ฉ, ํ๊ฒฝ๋ณ์ ์๋๊ตฌ์ฑ ๊ฐ๋ฅ) # source ~/.bash_profile [ํ๊ฒฝ ํ๋กํ์ผ ์ ์ฉ]
๋ค์ด๋ก๋ ๋ฐ์ mpich์์ค์ ์์ถ์ ํ๊ณ , ํด๋น ์์ค์ ๋ฃจํธ๋ก ์ด๋ํฉ๋๋ค. ์๋์ ์ฌ๋ณผ๋ฆญ ๋งํฌ๋ฅผ ์ฌ์ฉํ๋ ์ด์ ๋, ํน ๋ค๋ฅธ ๋ฒ์ ์ mpich๋ก ๋ณ๊ฒฝํ๋๋ผ๋ ๋งํฌ๋ง ๋ณ๊ฒฝํด์ฃผ๋ฉด, ์ฌ์ฉ์๋ค์ ํ๊ฒฝ๋ณ์๋ฅผ ๋ณ๊ฒฝํ ํ์์์ด ์ฌ์ฉํ๊ธฐ ์ํด์ ์ ๋๋ค. # wget http://wwwโunix.mcs.anl.gov/mpi/mpich/downloads/mpich.tar.gz
์ค์น
# cd /usr/local
# tar xvfz mpich.tar.gz
# cd mpich
# ./configure --with-device=ch_p4 -prefix=/usr/local/mpich-1.2.7p1 -c++=pgCC โฉ
-cc=pgcc -fc=pgf77 -clinker=pgcc -flinker=pgf77 -c++linker=pgCC โฉ
-f90=pgf90 -f90inc=/usr/pgi/linux86/6.0/include -f90linker=pgf90 โฉ
-f90libpath=/usr/pgi/linux86/6.0/lib -opt="-fast" -rsh=ssh
# make
# make install
# ln -s /usr/local/mpich-1.2.7p1 /usr/local/mpich
mpich/util/machines/machines์ hostname์ ๋ฃ์ด์ค๋ค. ๋๋ mpirun โmachinefile filename๋ก ๊ฐ๋ฅ.
MPICH ํ ์คํธ
# cd mpich/examples/basic
# make cpi
# mpich/bin/mpirun โnp 4 cpi
(e.g. mpicc โg โo matrix matrix.c)
IBM System x Enterprise Architecture Linux Advanced Management
- 32 -
path๋ /etc/profile.d/mpi.sh ์ ๋ค์๊ณผ ๊ฐ์ด ์ ๋ ฅํด๋๋ฉด ๋ณ๋์ ํ๊ฒฝ๋ณ์ ์ ํ ์์ด ์ฌ์ฉ์ด ๊ฐ๋ฅํ๋ค.
export MPICH=/usr/local/mpich
export PATH=$PATH:$MPICH/bin
mpimaker ๋ฅผ ์ด์ฉํ MPICH ์ปดํ์ผ ๋ฐฉ๋ฒ
./mpimaker mpich-1.2.7p1.tar.gz smp gnu64 ssh
* mmpimaker๋ tar์์ถํด์ ๋ฐ Configure, make, make install๊น์ง ์๋์ผ๋ก ์คํ์์ผ์ค๋ค
์ค์น ํ์ธ
# mpicc -V mpicc for 1.2.7 (release) of : 2005/11/04 11:54:51 Reading specs from /usr/lib/gcc/x86_64-redhat-linux/3.4.6/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=x86_64-redhat-linuxThread model: posix gcc version 3.4.6 20060404 (Red Hat 3.4.6-3) /usr/libexec/gcc/x86_64-redhat-linux/3.4.6/collect2 --eh-frame-hdr -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 /usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../../../lib64/crt1.o /usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../../../lib64/crti.o /usr/lib/gcc/x86_64-redhat-linux/3.4.6/crtbegin.o -L/usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh/lib -L/usr/lib/gcc/x86_64-redhat-linux/3.4.6 -L/usr/lib/gcc/x86_64-redhat-linux/3.4.6 -L/usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../../../lib64 -L/usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../.. -L/lib/../lib64 -L/usr/lib/../lib64 -lmpich -lpthread -lrt -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/lib/gcc/x86_64-redhat-linux/3.4.6/crtend.o /usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../../../lib64/crtn.o /usr/lib/gcc/x86_64-redhat-linux/3.4.6/../../../../lib64/crt1.o(.text+0x21): In function `_start': : undefined reference to `main'
collect2: ld returned 1 exit status
๊ฐ ๊ณ์ฐ ๋ ธ๋์๋ ๊ฐ์ ์์น์ ์ธ์คํจ ํ๊ฑฐ๋, NFS๋ฑ์ ์ด์ฉํ์ฌ ๊ฐ์ ์์น์
mpich๋ฐ PGI๊ฐ ์์นํ ์ ์๋๋ก ํด์ผ ํฉ๋๋ค.
์์ ์คํ
# cd /usr/local/mpich/examples # make cpi # ./cpi Process 0 on master pi is approximately 3.1416009869231254, Error is 0.0000083333333323
wall clock time = 0.000105
mpirun์ ํตํ์ฌ ์คํ
๋จผ์ ๋ ธ๋๋ฅผ ์ง์ ํ๊ธฐ ์ํด, ๋จธ์ ํ์ผ์ ์์ฑํฉ๋๋ค. ๋จธ์ ํ์ผ์ ์ง์ ์ ๋ค์๊ณผ ๊ฐ์ผ๋ฉฐ CPU์
์ง์ ํ์ ์ hostname:n (n์ ๋ฌผ๋ฆฌ์ ์ธ CPU์ ๊ฐฏ์๋ฅผ ์ง์ ํ๋ค)
# vi /usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh/share/machines.LINUX -------------------------------------------------------------------
IBM System x Enterprise Architecture Linux Advanced Management
- 33 -
node001:2 ๊ฐ ๋ ธ๋๋ค์ ๋ํ ๋ฌผ๋ฆฌ์ ์ธ CPU์ ๊ฐ์๋ฅผ ์ง์ ํด ํ๋ค. node002:2 node003:2 node004:2
๊ฐ ๋ ธ๋๋น cpu๊ฐ์ 2๊ฐ, ์ด4๊ฐ์ CPU๋ฅผ ๋จธ์ ํ์ผ ๋ง์คํฐ๋ ธ๋์์๋ ์คํํ์ง ์๋ ์ต์ ์ผ๋ก
mpirun์ ์คํํฉ๋๋ค.
# mpirun -np 4 -machinefile ./share/machines.LINUX -nolocal ./cpi Process 0 on node001 Process 1 on node002 Process 2 on node003 pi is approximately 3.1416009869231241, Error is 0.0000083333333309
wall clock time = 0.000546
IBM System x Enterprise Architecture Linux Advanced Management
- 34 -
3.6.3 ATLAS Installation
ATLAS ( Auto Tuning Linear Algebra Subprogram)๋ ์์น ์ฐ์ฐ์ ์์ด ์ฌ์ฉ๋์ด์ง๊ณ ์๋ BLAS
(Basic Linear Algebra Subroutine )์ ๊ทธ ํด๋น Computer ์ ๋ง๊ฒ ์๋์ผ๋ก Tuning ํ์ฌ BLAS
Library ๋ฅผ ๋ง๋ค์ด ์ฃผ๋ Program ์ด๋ค. ์ด๊ฒ์ผ๋ก ๋ง๋ค์ด์ง BLAS Library ๋ Standard BLAS
Library ๋ณด๋ค ์ฑ๋ฅ์ด ์๋ฑํ๊ธฐ ๋๋ฌธ์ Linpack Benchmarking Test ๋ฅผ ํ ๊ฒฝ์ฐ์๋ ์ด ๊ฒ์ Link ํ์ฌ
์ฌ์ฉํ๋ค. ATLAS ๋ฅผ Install ํ๊ธฐ ์ ์ ์ฐ์ ์ ์ผ๋ก ๊ณ ๋ คํด์ผ ํ ๊ฒ์ด Compiler ์ ์ข ๋ฅ์ด๋ค. ์ด๋ค
Compiler ๋ก Library ๋ฅผ ๋ง๋ค๊ธฐ ์ฌ์ด ๋ฐ๋ฉด์, ์ด๋ค Compiler ์ ๊ฒฝ์ฐ์์๋ Compile ์ด ์ฝ๊ฒ ๋์ง ์๋
๊ฒฝ์ฐ๊ฐ ์๋ค. ๋ฐ๋ผ์ ๋๋๋ก์ด๋ฉด, gcc-2.95 version ์ ์ฌ์ฉํ ๊ฒ์ ๊ถ์ฅํ๋ค.
BLAS Library ๋ฅผ ๋ง๋ค๊ธฐ ์ํ ์ผ๋ จ์
๊ณผ์ ์ ์๋์ ๋ํ๋ด์๋ค.
๊ฐ ์ง๋ฌธ๋ค์ ์์ธํ ๋ด์ฉ์
www.netlib.org ๋ฅผ ์ฐธ๊ณ ํ๊ธฐ ๋ฐ๋๋ค.
3.6.4 Cache Size
ATLAS ์ ์ฑ๋ฅ์ ๋์ด๊ธฐ ์ํ ํ๋์
๋ฐฉ๋ฒ์ผ๋ก๋ Cache Edge Size ๋ฅผ
๋ณ๊ฒฝํ๋ ๊ฒ์ด์๋ค. ๋ณดํต Pentium 4 ์
๊ฒฝ์ฐ Cache Edge Size ๊ฐ 209K ๋ก
๋์ด์ ธ ์๋๋ฐ, ์ด๊ฒ์ ํฌ๊ธฐ๋ฅผ ๋ณ๊ฒฝํ๋ฉด
Cluster ์ ์ฑ๋ฅ์ ๋์ผ ์ ์๋ค.
~ /ATLAS/inc lude/<arch>/a tlas_cacheedge .h F ile ์ ์
# ifndef ATLAS_CACHEED G E_H #define ATLAS_CACHEEDG E_H #define CacheEdge 210944 -> 393216 (384K )# end if
~ /ATLAS/b in /<arch>/ : m ake xs l3b lasts t, xd l3b lastst, xc l3b lastst, xz l3b lasts t ์ค ํ
~ /ATLAS/b in /l3b last.c F ile ์ ์
* * By defau lt the m ono- th readed ATLAS rou tines a re tested. To test the * m u lti- th readed ATLAS rou tines, define the fo llow ing m acro : * USE_L3_PTHREAD S : m u lti- th readed ATLAS im p lem enta tion . *///# define USE _F77_BLAS# define USE_L3_REFERENCE // L ine 79
IBM System x Enterprise Architecture Linux Advanced Management
- 35 -
3.6.5 GotoBLAS Installation
GotoBLAS ์ฝ๋๋ ํ์ฌ ์ ํ๋์ ์๊ณ ๋ฆฌ์ฆ์ ์๋ธ๋ฃจํด์ ๊ฐ์ฅ ๋น ๋ฅด๊ฒ ๊ตฌํํ๊ณ ๋ค์ํ ์ํคํ ์ณ๋ฅผ ์ง
์ํ๋ ์๊ณ ๋ฆฌ์ฆ ์์ค ์ฝ๋์ด๋ค.
down load http://www.tacc.utexas.edu/resources/software/
GotoBLAS-1.10.tar.gz ๋ค์ด๋ก๋ํ /opt/ํด๋์ ์์ถํด์
[root@mgt01 opt]# tar xzvf GotoBLAS-1.10.tar.gz [root@mgt01 opt]# cd GotoBLAS [root@mgt01 opt]# vi Makefile.rule ใ GotoBLAS ์ ํ์๊ณ ๋ฆฌ์ฆ ์ํคํ ์ณ ๋ฃฐ์ ์ ์ Configuration File ์์ # # Beginning of user configuration # # This library's version REVISION = -r1.06 # Which do you prefer to use for C compiler? Default is gcc. # I recommend you to use GCC because inline assembler is required. C_COMPILER = GNU ## C compiler ์ ์ ๋ฆฌ๋ ์ค GNU ์ปดํ์ผ๋ฌ ์ ์ 64๋นํธ # C_COMPILER = INTEL # Which do you prefer to use for Fortran compiler? Default is GNU G77. F_COMPILER = G77 ## FORTRAN compiler ์ ์ # F_COMPILER = G95 # F_COMPILER = GFORTRAN # F_COMPILER = INTEL # F_COMPILER = PGI # F_COMPILER = PATHSCALE # F_COMPILER = IBM # F_COMPILER = COMPAQ # F_COMPILER = SUN # F_COMPILER = F2C # If you want to build threaded version. # You can specify number of threads by environment value # "OMP_NUM_THREADS", otherwise, it's automatically detected. # SMP = 1 โ> ์์คํ ํ๊ฒฝ์ด SMP ํ๊ฒฝ์ด๊ฑฐ๋ Thread Library๋ฅผ ์๊ตฌํ ๋ ์ต์ ์ค์ # You may specify Maximum number of threads. It should be minimum. # MAX_THREADS = 4 Maximum threads ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๊ฐ์๋ฅผ ์ ์ํจ # If you need 64bit binary; some architecture can accept both 32bit and # 64bit binary(EM64T, Opteron, SPARC and Power/PowerPC). # BINARY64 = 1 # If you want to drive whole 64bit region by BLAS. Not all Fortran # compiler supports this. It's safe to keep comment it out if you # are not sure. INTERFACE64 = 1 ## 64bit binary only # If you need Special memory management; # Using HugeTLB file system(Linux / AIX / Solaris) # CCOMMON_OPT += -DALLOC_HUGETLB # Using static allocation instead of dynamic allocation
IBM System x Enterprise Architecture Linux Advanced Management
- 36 -
# You can't use it with ALLOC_HUGETLB together # CCOMMON_OPT += -DALLOC_STATIC # If you want to use CPU affinity # CCOMMON_OPT += -DUSE_CPU_AFFINITY # If you want to use memory affinity (for NUMA) # You can't use it with ALLOC_STATIC together # NUMA_AFFINITY = 1 # If you want to use pure thread server model. # Default is only OMP_NUM_THREADS - 1 threads are spawned to reduce # thread overhead. This is not implemented yet. # CCOMMON_OPT += -DALL_THREADED # Use busy wait instead of pthread_lock implemenation # BLAS perforamnce should be better, but total performance would be # worse due to extra usage of CPU # CCOMMON_OPT += -DUSE_BUSYWAIT # If you have special compiler to run script to determine architecture. GETARCH_CC = gcc GETARCH_FLAGS = # End of user configuration [root@mgt01 GotoBLAS]# make # generating normal library [root@mgt01 GotoBLAS]# make prof # generating profile enabled library (linux only) [root@mgt01 GotoBLAS]# make clean [root@mgt01 GotoBLAS]# cd exports; make so # Shared library ์์ฑ [root@mgt01 GotoBLAS]# ls libgoto.a, libgoto_core2-r1.06.a, libgoto_core2-r1.06.so ํ์ผ ์์ฑ ํ์ธ
Sample Installation Script
#!/bin/bash export CC=gcc export FC=g77 rm -rf *.log rm -rf *.so tar xfz GotoBLAS-1.14.tar.gz echo "Complete .. Unarchive" cp Makefile.rule GotoBLAS/ cd GotoBLAS make -j4 1>../make.log 2>../make_err.log echo "Complete .. Make" make prof -j4 1>../prof.log 2>../prof_err.log echo "Complete .. Profile" cd exports make so 1>../../so.log 2>../../so_err.log echo "Complete .. Build Dynamic Library" cd .. cp *.so ../ cd .. #rm -rf GotoBLAS echo "Complete .. Build GotoBLAS"
IBM System x Enterprise Architecture Linux Advanced Management
- 37 -
3.6.7 HPL Installation HPL์ ๋ง์ ์ฌ์ฉ์์ฉ option์ด ์๊ธฐ ๋๋ฌธ์ ์ด option์ ๋ฐ๋ผ์๋ ์ฑ๋ฅ์ ์ฐจ์ด๊ฐ ๋ง์ด ๋ ์๋ ์๋ค. ๋ํ Network์ ์ฑ๋ฅ์ฐจ์ด ๋ํ Cluster Computer์ ์ฑ๋ฅ์ ์ฃผ์ํ ์์ธ์ด ๋๋ค. HPL์ Installํ๋ค๋ ์ด์ผ๊ธฐ๋ ๊ณณ Compileํ๋ค๋ ์ด์ผ๊ธฐ์ ๊ฐ๋ค. ์ฆ hpl์ Compileํ์ฌ execution file์ ๋ง๋ค๊ณ ์ด๊ฒ์ input file์ธ HPL.dat file ์ ์์ ํ์ฌ Cluster Super Computer์ ์ฑ๋ฅ์ ํ๊ฐ ํ ์ ์๋ค. hpl Compile์ ATLAS์ Compile๊ณผ ์ ์ฌํ๊ฒ ~/hpl/setup Directory์ ์๋ ์ ๋นํ Make.<arch> file์ ์ ํํ์ฌ, ์์ ํ ํ์, make arch=<arch> ๋ช ๋ น์ ์คํ ์ํค๋ฉด ~/hpl/bin/<arch> Directory์ HPL.dat file ๊ณผ execution file (xhpl)์ด ์๊ธด๋ค. ๋ค์์ Make.<arch>file์ ์์ด๋ค.
MPI PATH & Compile OPTION
BLAS LIBRARY PATH & Link
IBM System x Enterprise Architecture Linux Advanced Management
- 38 -
HPL์ ์ค์น์ ๊ด๋ จ๋ ํญ๋ชฉ๋ค์ ์์๋จ์ธ ๋ณ๋ ฌ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ธ MPICH๊ฐ ์ ์์ ์ผ๋ก ์ค์น๋์์์ ๊ฐ์ ํ
๊ณ ์งํํ๋ค.
Step 1.
HPL์ ์์ค์ฝ๋๋ฅผ ๋ค์ด๋ก๋ ๋ฐ์ ์ค์นํ๊ณ ์ ํ๋ Path์ ์์นํ์ฌ ์์ถํ์ผ์ ํด์ ํด ์ค๋ค
http://www.netlib.org/benchmark/hpl/hpl.tgz
์ผ๋ฐ์ ์ธ HPL์ ์์ค์ฝ๋์ ์์ถํด์ ์ ์์น๋ /opt์์ ์ค์นํ๋ค.
Step 2.
์์ถํด์ ๋ HPL ๋๋ ํ ๋ฆฌ ์ด๋ํ์ฌ Machine config ํ์ผ์ ๋ณต์ฌํ์ฌ ์์๋๋ ํ ๋ฆฌ์ ์์นํ์
Config๋ฅผ ์ค์ ํ๋ค. /opt/hpl/setup ๋๋ ํ ๋ฆฌ์ Make.Linux_PII_FB_LAS๋ฅผ Make.Linux๋ก Rename
ํ์ฌ ์์๋๋ ํ ๋ฆฌ์ ๋ณต์ฌํด ๋ฃ์๋ค.
[root@hpl/setup]cp Make.Linux_PII_FBLAS ./make.Linux
Step 3.
๋ณต์ฌํ Make.Linux config ํ์ผ์ ์์คํ ์ ์ค์ ์ ๋ง๊ฒ ์ฌ๊ตฌ์ฑ ํ๋ค. HPL์ ์ค์ ์ GotoBLAS
๋ผ์ด๋ธ๋ฌ๋ฆฌ๊ฐ ์ ์์ ์ผ๋ก ์ค์น๊ฐ ์๋ฃ๋์๋ค๋ ๊ฐ์ ํ์ ์งํํ๋ค
* HPL ๋ผ์ด๋ธ๋ฌ๋ฆฌ ์ ์ ---------------------------------------------------------------------- # - HPL Directory Structure / HPL library # ---------------------------------------------------------------------- # TOPdir = /opt/hpl hpl์ด ์ค์น๋ ๋๋ ํ ๋ฆฌ์์น ์ ์ INCdir = $(TOPdir)/include BINdir = $(TOPdir)/bin/$(ARCH) LIBdir = $(TOPdir)/lib/$(ARCH) # HPLlib = $(LIBdir)/libhpl.a /opt/hpl/lib ๋๋ ํ ๋ฆฌ๋ฅผ ํ์ธํ์ฌ ํ์ผ์กด์ฌ ํ์ธ * MPICH ๋ผ์ด๋ธ๋ฌ๋ฆฌ ์ ์ # ---------------------------------------------------------------------- # - Message Passing library (MPI) # ---------------------------------------------------------------------- # MPinc tells the C compiler where to find the Message Passing library # header files, MPlib is defined to be the name of the library to be # used. The variable MPdir is only used for defining MPinc and MPlib. # MPdir = /usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh MPICH ๋๋ ํ ๋ฆฌ ์ ์ MPinc = -I$(MPdir)/include MPlib = $(MPdir)/lib/libmpich.a # *Goto ๋ผ์ด๋ธ๋ฌ๋ฆฌ ์ ์ ----------------------------------------------------------------------
IBM System x Enterprise Architecture Linux Advanced Management
- 39 -
# - Linear Algebra library (BLAS or VSIPL) # ---------------------------------------------------------------------- # LAinc tells the C compiler where to find the Linear Algebra library # header files, LAlib is defined to be the name of the library to be # used. The variable LAdir is only used for defining LAinc and LAlib. # LAdir = /home/Goto/GotoBLAS GotoBLAS ๋๋ ํ ๋ฆฌ ์ ์ LAinc = LAlib = -L$(LAdir)/libgoto.a $(LAdir)/libgoto.a *GNU Compiler ์ ์ ---------------------------------------------------------------------- # - Compilers / linkers - Optimization flags --------------------------- # ---------------------------------------------------------------------- # CC = /usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh/bin/mpicc
mpicc ์ปดํ์ผ๋ฌ์ ๋ํ ์ ์ CCNOOPT = $(HPL_DEFS) CCFLAGS = $(HPL_DEFS) -fomit-frame-pointer -O3 -funroll-loops # # On some platforms, it is necessary to use the Fortran linker to find # the Fortran internals used in the BLAS library. # LINKER = /usr/local/mpich/1.2.7p1/ip/x86_64/smp/gnu64/ssh/bin/mpif77
mpi Fortran77์ ๋ํ ์ ์๋ฅผ ์ง์ LINKFLAGS = $(CCFLAGS) -lm # ARCHIVER = ar ARFLAGS = r RANLIB = echo # # ---------------------------------------------------------------------- # - Platform identifier ------------------------------------------------ # ---------------------------------------------------------------------- # ARCH = Linux ๋ฆฌ๋ ์ค ํ๋ซํผ์ ๋ํ ์ ์๋ฅผ ์ง์ ํ์ฌ ์ค๋ค.
Step4.
๋ชจ๋ ์ค์ ์ด ์๋ฃ๋ ํ์ make arch=Linux ๋ช ๋ น์ ์ด์ฉํ์ฌ ์ง์ ๋ GotoBLAS ๋ผ์ด๋ธ๋ฌ๋ฆฌ์
HPL ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋ํ ์ปดํ์ผ์ ์งํํ๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 40 -
3.7 Run HPL
3.7.1 Compile Linpack Benchmarking ์ ์์์๋ ์ค๋ช ํ๋ ๊ฒ๊ณผ ๊ฐ์ด Cluster์ ์ฑ๋ฅ์ ํ๊ฐ ํ ์ ์๋ค. MPICH๋ฅผ ์ด์ฉํ์ฌ MPI Job์ ์คํ์ํค๊ธฐ ์ํด์๋ ๋จผ์ Compile์ mpich์ mpicc Command๋ฅผ ์ฌ์ฉํ์ฌ์ผ ํ๋ค. ๊ทธ ์ด์ธ์ Compile ๊ณผ์ ์ ๋์ผํ๋ค. 3.7.2 Send the Execution file Linpack Benchmarking์์ ๊ฐ Node์์ ํ์๋ก ํ๋ execution file์ xhpl๋ฟ์ด๋ค. ๋ฐ๋ผ์ scp๋ psh๋ช ๋ น์ด๋ฅผ ์ด์ฉํ์ฌ ๊ฐ Node์ ๋์ผ Directory๋ก ๋ณต์ฌ๋ฅผ ํ๋ค. 3.7.3 Preparation for MPI Job Linpack Benchmarking test๋ฅผ ํ๊ธฐ ์ํด์๋ HPL์ input file์ธ HPL.dat file์ ๊ฐ parameter๋ค์ ๋ํด์ ์์์ผ ํ๋๋ฐ, ์์ธํ ๋ด์ฉ์ hpl Directory๋ด์ TUNING file์ ์ ์ ํ์ ธ ์์ผ๋ฏ๋ก ์ฌ๊ธฐ์๋ Linpack Benchmarking test์ ์ฑ๋ฅ์ ์ฃผ์ํ๊ฒ ์ํฅ์ ์ฃผ๋ ๋ช ๊ฐ์ง ์์์ ๋ํ์ฌ๋ง ์ค๋ช ํ๋๋ก ํ๊ฒ ๋ค. ๋ค์์ HPL.dat ์ ์์ด๋ค.
HPL.dat file์ parameter ๋ค์ Linpack Benchmarking์ ์ฑ๋ฅ์ ์ง๋ํ ์ํฅ์ ์ค๋ค. ๋ฐ๋ผ์ User๊ฐ ๊ฐ์ง๊ณ ์๋ Cluster์ ํ๊ฒฝ์ ๋ง๊ฒ ์ ์์ ํด ์ฃผ์ด์ผ๋ง ์ข์ ์ฑ๋ฅ์ ๋ผ ์ ์๋ค. MPICH๊ฐ LAM/MPI์ ๋ค๋ฅธ ์ ์ค์ ํ๋๋ lamd๋ฅผ ์คํ์ํค๊ธฐ ์ํด lamboot๋ฅผ ์คํ ์ํฌ ํ์๊ฐ ์์ผ๋ฉฐ, ์ฌ์ฉ๋ Node์ ์ ๋ณด๋ lamhosts file์ ์ด์ฉํ๋ ๊ฒ์ด ์๋๋ผ mpi Directory/share/machines.LINUX file์ ์ด์ฉํ๋ค. ์๋๋ ๊ทธ file์ ์์ด๋ค.
Matrix Size์ ๊ดํด์ test ํ ํ์ : ์ด ๊ฒฝ์ฐ 10000์ ๋ํด์ 1๋ฒ
๊ฐ Node๋ฅผ ์ํด Partition ๋์ด์ง Sub Matrix Block์ Size : ์ด ๊ฒฝ์ฐ 104 ์ ๋ํด์ 1๋ฒ test
Network์ ๊ด๋ จ๋ parameter๋ก์ Broad Casting ๋ฐฉ๋ฒ์ ์ ํํ๋ค.: ์ด ๊ฒฝ์ฐ์ 0๋ฒ ๋ฐฉ๋ฒ์ ์จ์ 1๋ฒ test
์ฌ์ฉ๋์ด์ง CPU์ ๊ฐ์ (P*Q=CPU ๊ฐ์): ์ด ๊ฒฝ์ฐ 2*2 ์ ๋ํด 1๋ฒ test ( cpu 4๊ฐ ์ฌ์ฉ)
IBM System x Enterprise Architecture Linux Advanced Management
- 41 -
3.7.4 xhpl ์คํ
# mpirun -np 7 xhpl ==================================================================== HPLinpack 1.0 -- High-Performance Linpack benchmark -- September 27, 2000 Written by A. Petitet and R. Clint Whaley, Innovative Computing Labs., UTK ==================================================================== An explanation of the input/output parameters follows: T/V : Wall time / encoded variant. N : The order of the coefficient matrix A. NB : The partitioning blocking factor. P : The number of process rows. Q : The number of process columns. Time : Time in seconds to solve the linear system. Gflops : Rate of execution for solving the linear system. The following parameter values will be used: N : 10000 NB : 85 P : 1 Q : 7 PFACT : Crout NBMIN : 4 NDIV : 2 RFACT : Right BCAST : 1ringM DEPTH : 1 SWAP : Mix (threshold = 64) L1 : transposed form U : transposed form EQUIL : yes ALIGN : 8 double precision words ============================================================================ T/V N NB P Q Time Gflops ---------------------------------------------------------------------------- W11R2C4 10000 85 1 7 70.49 9.460e+00 ---------------------------------------------------------------------------- ||Ax-b||_oo / ( eps * ||A||_1 * N ) = 0.0646673 ...... PASSED ||Ax-b||_oo / ( eps * ||A||_1 * ||x||_1 ) = 0.0153022 ...... PASSED ||Ax-b||_oo / ( eps * ||A||_oo * ||x||_oo ) = 0.0034203 ...... PASSED ============================================================================ ์์ ๊ฒฐ๊ณผ๋ N = 10000 , NB = 85 ์ผ๋ 9.46Gflops ๊ฐ ๋์๋ค. LINPACK ๊ณผ ๋ง์ฐฌ๊ฐ์ง๋ก ์ฌ๋ฌ๋ถ์ ์์คํ ํ๊ฒฝ์ ๋ง๊ฒ problem size ์ NB ๋ฅผ ์ ์ ํ ์์ ํด ๊ฐ๋ฉด์ ์์คํ ์ด ์ํํ ์ ์๋ ์ต๊ณ ์ฑ๋ฅ์
IBM System x Enterprise Architecture Linux Advanced Management
- 42 -
์ด๋์ด ๋ด๋ณด์. HPL.dat ํ์ผ์ ์์ ํ ๋ค์ ์ปดํ์ผ์ ๋ค์ ํ๋ค. # rm -f ./xhpl # cd ../../ # make clean # make all
IBM System x Enterprise Architecture Linux Advanced Management
- 43 -
4. GPFS (General Parallel File System)
4.1 GPFS ๊ฐ์
GPFS(General Parallel File System)๋?
General Parallel File System(GPFS)์ ํด๋ฌ์คํฐ ๋ด์ ๋ชจ๋ ๋ ธ๋๋ก ๋ถํฐ ๋ฐ์ดํฐ ์ ๊ทผ์ ๊ฐ๋ฅํ๊ฒ ํ๋
๊ณ ์ฑ๋ฅ ๊ณต์ ๋์คํฌ ํ์ผ ์์คํ ์ด๋ค. ๋ณ๋ ฌ ๋๋ ์ง๋ ฌ ๋ฑ ์ด๋ค ์ ํ์ ์ดํ๋ฆฌ์ผ์ด์ ์ ์ฌ์ฉํ๋๋ผ๋ ํ
์ค ์ ๋์ค ํ์ผ ์์คํ ์ธํฐํ์ด์ค๋ฅผ ํตํด ๊ณต์ ํ์ผ
์ ์ฝ๊ฒ ์ ๊ทผํ ์ ์์ผ๋ฉฐ, ๋ณต์ ๋ ธ๋ ์์๋ ๊ฐ์ ํ
์ผ์ ๋์์ ์ ๊ทผํ ์ ์๋ค. GPFS๋ ๋ก๊น (logging)๊ณผ
๋ณต์ ๋ฟ๋ง ์๋๋ผ, failover ๊ตฌ์ฑ์ ํตํด ๋์คํฌ ๋๋
์๋ฒ ์ค์๋ ์์๋ ๊ณ ๊ฐ์ฉ์ฑ์ ๋ณด์ฅํ๋ค.
๊ณต์ ํ์ผ ์์คํ ์๋ฃจ์
๋ณต์๊ฐ์ ๋ ธ๋๊ฐ ํ์ผ์์คํ ์ ํ์ผ์ ๊ณต์ ํ ์ ์๋
๋ก ์ง์
Shared SAN Filesystem
Shared SAN์ ํตํด ๊ณต์ ๋ ธ๋๋ค์ด ๋ฐ์ดํ์ ๋ฌผ๋ฆฌ์
์ผ๋ก ์ง์ ์ฐ๊ฒฐ ํจ์ผ๋ก์จ ๋์ ์ฑ๋ฅ๊ณผ ์์ ์ฑ ์ ๊ณต ๊ฐ
๋ฅ
ํ์ค UNIXยฎ ํ์ผ ์์คํ ์ธํฐํ์ด์ค ์ ๊ณต
๊ธฐ์กด ์ ๋์ค ํ์ผ์์คํ ๊ณผ ๋์ผํ๊ฒ ํ์ผ์ ์์ฑ/๋ณ๊ฒฝ
/์ญ์ . GPFS๋ด์ ํ์ผ์ ๊ด๋ฆฌํ๊ธฐ ์ํด ๋ณ๋ ๋ฐฉ๋ฒ์
์ต๋ํ ํ์ ์์.
4.2 GPFS ํ๊ฒฝ
GPFS short history & evolution
1996๋ Tiger Shark File system โ ๋ฉํฐ๋ฏธ๋์ด video server๋ก ๊ตฌํ๋จ
1998๋ GPFS 1.1 ์ถ์ โ IBM SP switch์ด์ฉํ ๊ณ ์ ์ค์์น ๋คํธ์ํฌ์ ๊ตฌํ
2001๋ ์ต๋ 32 ๋ ธ๋ ์ง์, ๋ฆฌ๋ ์ค ์ง์ํ๋ Linux์ฉ GPFS 1.1 ์ถ์
2002๋ GPFS 2.1 ์ถ์ , GPFS 1.3 for Linux ์ถ์
2003๋ 12์ GPFS 2.2 ์ถ์ - xSeries Linux, pSeries Linux, pSeries AIX
2004๋ 12์ GPFS 2.2 ๊ธฐ๋ฅํฅ์ โ AIX-Linux interoperability ๊ธฐ๋ฅ ์ถ๊ฐ
2004๋ ์๋ก์ด ํ๋์จ์ด ์ง์๊ณผ ๊ธฐ๋ฅ ํฅ์๋ GPFS 2.3 ์ถ์
2006๋ GPFS V3.1 ์ถ์
IBM System x Enterprise Architecture Linux Advanced Management
- 44 -
AIX์ Linux system์ Concurrent Sharing ์ง์
GPFS architecture๋ AIX์ Linux ์๋ฒ๊ฐ SAN based storage์ ๋์ ์ฐ๊ฒฐํ์ฌ ํ์ผ ๊ณต์ ํ๋๋ก ์ง์
ํ๋์จ์ด์ ์ผ๋ก Linux์ AIX์์ ๋์ ์ ์/๊ณต์ ๊ฐ ๊ฐ๋ฅํ ๊ฒฝ์ฐ ์ ์ฉ ๊ฐ๋ฅ
GPFS for AIX
- H/W
IBM system p5 server, IBM eServer JS20 BladeCenter server JS21 BladeCenter server.
- S/W
GPFS V3.1.0.1 : AIX V5.3 or later
GPFS V2.3.0.12 : AIX V5.2 or later
GPFS for Linux
- H/W
IBM x86 xSeriesยฎ server, IBM BladeCenter server, IBM for AMD processor-based
Server Linux on POWERโข product ( System p5 servers, BladeCenter server, OpenPowerโข server)
- S/W
๊ตฌ์ถํ๊ณ ์ ํ๋ system type (POWER, x86_64, IA_32)์ ๋ฐ๋ผ ์ง์ ๊ฐ๋ฅ ์ปค๋ ๋ ๋ฒจ ๊ฒฐ์ ๋จ.
Red Hat EL 4.0 (Update 3), Red Hat EL 3.0 (Update 7)
SUSE LINUX ES 9.0 (SP3), SUSE LINUX ES 8.0 (SP4)
4.3 GPFS ํน์ฑ
High Scalable File system ์๋ฐฑ๊ฐ์ ๋ ธ๋ ๋์ ์ ์๊ณผ 1000๊ฐ ์ด์์ ๋์คํฌ๋ก ๊ตฌ์ฑ๋ ์๋ฐฑ TB
์ฉ๋์ ์ง์ ์ด๋ก ์ ์ต๋ ์ฉ๋ 2^99 bytes๊น์ง ์ง์ ๊ฐ๋ฅํ๋ฉฐ ํ์ฌ 200
Terabytes๊น์ง ๊ฒ์ฆ Filesystem๋น ์ต๋ 2,147,483,648๊ฐ ํ์ผ๊น์ง ์์ฑ
๊ฐ๋ฅ(๊ตฌ์ฑ์ ๋ฐ๋ผ ์์ด)
High availability ์ผ๋ถ ๋ ธ๋ ์ฅ์ ์์๋ ๋ค์ดํ์ ์์ด ํ์ผ์์คํ ๊ณต์ ๋ก ์ง์์ ์ผ๋ก ์๋น
์ค ๊ฐ๋ฅ
High performance Shared SAN์ ํตํด ๊ณต์ ๋ ธ๋๋ค์ด ๋ฐ์ดํ์ ๋ฌผ๋ฆฌ์ ์ผ๋ก ์ง์ ์ฐ๊ฒฐ ํจ์ผ
๋ก์จ ๋์ ์ฑ๋ฅ๊ณผ ์์ ์ฑ ์ ๊ณต ๊ฐ๋ฅ
High Flexibility NSD (Network Shared Disk)๊ธฐ๋ฐ์ ๋์คํฌ ์ ๊ณต์ผ๋ก, ์ง์ ์ ์ธ SAN ์ฐ
๊ฒฐ ์์ด๋ GPFS ๊ธฐ๋ฐํ์ ํ์ผ์์คํ ๊ณต์ ๊ฐ๋ฅ. ๋ฐ๋ผ์ ์๋ฒ ํ์ฅ์ด ์ฉ
์ดํ๋ฉฐ, ์ฉ๋๋ณ, I/O ์ฉ๋๋ณ ์ ์ฐํ ๊ตฌ์ฑ ๊ฐ๋ฅ
High stability HACMP ํ์์์ด GPFS ์๋ฃจ์ ๋ง์ผ๋ก ํ์ผ์์คํ ๊ณต์ ๊ฐ ๊ฐ๋ฅํด ์ง์ผ
๋ก์จ, ๊ตฌ์ฑ์ ๋จ์ํ, ๊ด๋ฆฌ์ ๋จ์ํ๋ก ์ธํ ์์ ์ฑ ํฅ์ (GPFS v2.3์ด
์)
Automatic
Journaling(Logging)
of Metadata
ํ์ผ์์คํ ๋ฉํ๋ฐ์ดํ๋ฅผ ๊ฐ ๊ณต์ ๋์คํฌ์ ์ ์ฅํ๊ณ , ์ฅ์ ์ ์ ์ํ ๋ณต
๊ตฌ๊ฐ ๊ฐ๋ฅํ๋๋ก ์ง์
Concurrent File Access ๋ฐ ์ ๊ตํ Lock ๊ด๋ฆฌ๋ก ๋ฐ์ดํ ์ ๊ทผ ์ถฉ๋/์์ถฉ์ ์๋ฐฉํ๊ณ , ํ๋์ ํ์ผ ์ฌ
IBM System x Enterprise Architecture Linux Advanced Management
- 45 -
Block Level Locking ์ ๊ณต ๋ฌ ํด๋ผ์ด์ธํธ๊ฐ ๋์์ ์ ๊ทผํ ์ ์๋๋ก ํจ. Byte range Lock๊ด๋ฆฌ๋ก,
ํ ํ์ผ๋ด ๊ฒน์น์ง ์๋ ๋ถ๋ถ์ ๋ํ ๋์ ์ ๋ฐ์ดํธ ๊ฐ๋ฅ. ๊ฒน์น๋ ์์ญ์
๋ํ write/update์์ฒญ์ ์์ฒญ ์์์ ๋ฐ๋ผ serializing ํ์ฌ Lock ๊ถํ
์ ๊ณต GPFS๋ ์ต๋ 300,000๊ฐ์ ํ ํฐ์ ๋์์ ๊ด๋ฆฌํ ์ ์์.
Data Protection GPFS ํ์ผ์์คํ ๊ณผ metadata์ ๋ํ ๋ฏธ๋ฌ๋ง ๊ธฐ๋ฅ ์ ๊ณต์ผ๋ก ์์ ์ฑ ํ๋ณด
Application์ ์ต์ ํ๋
block-size ์ง์ ๊ฐ๋ฅ
์ด์ ์ดํ๋ฆฌ์ผ์ด์ ์ ํน์ฑ์ ๋ง๋๋ก 16K ~ 1024K๊น์ง ๋ค์ํ block
size๋ฅผ ์ง์ ํ์ฌ ์ต์ ํ ํ ์ ์์
Block Level striping ํ์ผ์์คํ ์์ฑ์ ์ง์ ํ block size๋จ์๋ก ์๋ Stripingํจ์ผ๋ก์จ I/O
์ฑ๋ฅ ์ต๋ํ ์ ๊ณต
Online ์์์์ Disk add /
remove ๊ฐ๋ฅ
์์คํ ์ด์์ค์ ๋์คํฌ ์ถ๊ฐ/์ญ์ ๊ฐ ๊ฐ๋ฅํ๊ณ , ์ถ๊ฐ/์ญ์ ์ ๋์ ์ผ๋ก ๋ฐ
์ดํ๋ฅผ ์ฌ๋ถ๋ฐฐ ํด ์ค์ผ๋ก์จ, I/O balancing์ ์ ์ง
ํ์ค UNIXยฎ ํ์ผ ์์คํ
์ธํฐํ์ด์ค ์ ๊ณต
๊ธฐ์กด ์ ๋์ค ํ์ผ์์คํ ๊ณผ ๋์ผํ๊ฒ ํ์ผ์ ์์ฑ/๋ณ๊ฒฝ/์ญ์ . GPFS๋ด์ ํ
์ผ์ ๊ด๋ฆฌํ๊ธฐ ์ํด ๋ณ๋ ๋ฐฉ๋ฒ์ ์ต๋ํ ํ์ ์์
4.4 GPFS ์ค์น
4.4.1 GPFS ์ค์น ์ ์ค๋น์ฌํญ
GPFS์ ํฌํจ๋ ๋ชจ๋ nodes ์ Linux OS ์ค์น
๊ฐ node๋ค /etc/hostsํ์ผ ์์ฑ
root ์ฌ์ฉ์๊ฐ ๊ฐ nodes์๊ฒ password prompt ์์ด ์ ์ ๊ฐ๋ฅํ๊ฒ SSH ๊ตฌ์ฑ
GPFS nodes ์๊ฐ ๋๊ธฐํ๋ฅผ ์ํด NTP์๋ฒ ๊ตฌ์ฑ ๊ถ์ฅ
GPFS nodes์ ์ธ์ฅ ์คํ ๋ฆฌ์ง ๋ณผ๋ฅจ ์ธ์
4.4.2 GPFS ์ค์น ๋ฐ Portability layer ๋น๋
GPFS ์ค์น ๋๋ ํ ๋ฆฌ ์์ฑ
mkdir /gpfslpp
CD-ROM์ผ๋ก๋ถํฐ GPFS ์ ํ ์ด๋ฏธ์ง ๋ณต์ฌ gpfs_install-3.1*
[root@blade1 gpfslpp]# ./gpfs_install-3.1.* [root@blade1 gpfslpp]# ls gpfs.base-3.1*.rpm gpfs.gpl-3.1*.noarch.rpm gpfs.msg.en_US-3.1*.noarch.rpm gpfs.docs-3.1*.noarch.rpm
[root@blade1 gpfslpp]# rpm โivh gpfs*
IBM System x Enterprise Architecture Linux Advanced Management
- 46 -
node profile ์ ํ๊ฒฝ ๋ณ์ ์ถ๊ฐ
PATH=$PATH:$HOME/bin:/usr/lpp/mmfs/bin
MANPATH=$MANPATH:/usr/lpp/mmfs/messages
Portability layer Build ํ๊ธฐ
cd /usr/lpp/mmfs/src
export SHARKCLONEROOT=/usr/lpp/mmfs/src
cd /usr/lpp/mmfs/src
make Autoconfig
make World
make InstallImages
[root@blade1 ~]# make InstallImages cd gpl-linux; /usr/bin/make InstallImages; make[1]: Entering directory `/usr/lpp/mmfs/src/gpl-linux' mmfslinux mmfs26 lxtrace dumpconv tracedev make[1]: Leaving directory `/usr/lpp/mmfs/src/gpl-linux'
๊ฐ GPFS nodes์ ์์ฑ๋ ํ์ผ ๋ณต์ฌ
[root@blade1 ~]# cd /usr/lpp/mmfs/bin [root@blade1 bin]# scp mmfslinux mmfs26 lxtrace dumpconv tracedev gpfs2:/usr/lpp/mmfs/bin /* Copy to all the other nodes */
4.5 GPFS ๊ตฌ์ฑ
4.5.1 GPFS Test ์์คํ ๊ตฌ์ฑ๋
IBM System x Enterprise Architecture Linux Advanced Management
- 47 -
4.5.2 GPFS๊ตฌ์ฑ ์ ๊ณ ๋ ค์ฌํญ
GPFS node ์ ์
NodeName:NodeDesignations:AdminNodeName
optional, โณ-โณ node roles ๊ตฌ๋ถ
manager | client โ GPFS node ๋ฅผ ์ ์ ํ ๋ manager node ํน์ client node์ ๋ํ node pool์
์ ์ํ๋ค.
quorum | nonquorum โ Node pool์์ node๊ฐ quorum ์๋๋ฉด non-quorum node๋ก ๋์ ํ ๊ฒ์ธ์ง
์ ๋ํ node role ์ ์. ์ ์ ํ์ง ์์ผ๋ฉด non-quorum node๋ก ๋์
GPFS Cluster primary์ secondary node๋ ๋ฐ๋์ quorum nodes ๊ตฌ์ฑ ํ ๊ฒ์ ๊ถ์ฅํ๋ค.
GPFS NSD ์์ฑ ์ต์ ํ์ธ
DiskName:PrimaryServer:BackupServer:DiskUsage:FailureGroup:DesiredName:StoragePool
DiskName โ NSD๋ก ์ ์๋ block device ์ด๋ฆ ex) /dev/sdb, /dev/hdisk1
PrimaryServer โ Primary NSD ์๋ฒ ์ด๋ฆ
BackupServer โ Backup NSD ์๋ฒ ์ด๋ฆ
DiskUsage โ Disk Usage ์ ์
- dataAndMetadata โ disk๊ฐ data์ metadata ๋ ๋ค ๊ฐ์ง๋ค. default๊ฐ
- dataOnly โ disk๊ฐ data๋ง ๊ฐ์ง๋ค.
- metadataOnly โ disk๊ฐ metadata๋ง ๊ฐ์ง๋ค
- descOnly โ disk๊ฐ data ๋ฐ metadata ๋ชจ๋๋ฅผ ๊ฐ์ง์ง ์๊ณ ๋จ์ง file system descriptor์ ๋ณต์ฌ๋ณธ๋ง
๊ฐ์ง๋ค. DR ๊ตฌ์ฑ์์ third failure group์ผ๋ก ์ฌ์ฉ๋จ
FailureGroup โ disk replication์ ์ํ failureGroup number ์ง์
DesiredName โ NSD disk ์ด๋ฆ ์ง์ ์ง์ ํ์ง ์์ผ๋ฉด gpfsNNnsdํ์์ผ๋ก ์๋์์ฑ
StoragePool โ NSD๊ฐ ํ ๋น๋ Storage Pool ์ด๋ฆ ์ง์
ex) /dev/sdb:gpfs_primary:gpfs_secondary:dataAndMetadata:1::stgpool01
GPFS file system ์์ฑ ์ต์ ํ์ธ
File System ์์ฑ options Default value -F DiskDesc ํ์ผ ์์คํ ๋์คํฌ์ ์ none -A {yes | no | automount} yes โ gpfs ๋ฐ๋ชฌ์ด ์์๋ ๋ ์๋ ๋ง์ดํธ no โ ์๋ ๋ง์ดํธ automount โ ํ์ผ์์คํ ์ฒ์์ผ๋ก access๋ ๋ ๋ง์ดํธ
yes
-B BlockSize 16K,64K,256K,512K,1024K or 1M data block size
256K
-E {yes | no} mtime ๊ฐ ๊ธฐ๋ก yes -m DefaultMetadataReplicas 1
IBM System x Enterprise Architecture Linux Advanced Management
- 48 -
metadata replication ๊ฐ {1 | 2} 1 โ metadata replication ํ์ง ์์ 2 โ metadata replication -M MaxMetadataReplicas metadata replication ๊ฐ {1 | 2}
1 โ metadata replication ํ์ง ์์ 2 โ metadata replication
1
-n NumNodes ๋ง์ดํธ ๋๋ nodes ์ซ์ 32 -o MountOptions none -Q {yes | no} to active quota no -r DefaultDataReplicas data replication ๊ฐ {1 | 2}
1 โ data replication ํ์ง ์์ 2 โ data replication
yes
-R MaxDataReplicas data replication ๊ฐ {1 | 2}
1 โ metadata replication ํ์ง ์์ 2 โ metadata replication
yes
-v {yes | no} disk usage ๊ฒ์ฆ yes
4.5.3 GPFS Cluster ๊ตฌ์ฑ
GPFS Cluster ์์ฑ ๋ฐ ํ์ธ
[root@blade1 gpfs]# mmcrcluster โn nodefile โp blade1 โs blade2 โr /usr/bin/ssh โR /usr/bin/scp โC gpfs_test ! -p primary server โs secondary server nodefile ์ ๋ด์ฉ > blade1:manager-quorum blade2:manager-quorum blade3:manager-quorum
blade4:client [root@gpfs1 gpfslpp]# mmlscluster GPFS cluster information ======================== GPFS cluster name: test.gpfs GPFS cluster id: 13882422822655908522 GPFS UID domain: test.gpfs Remote shell command: /usr/bin/ssh Remote file copy command: /usr/bin/scp GPFS cluster configuration servers: ------------------------------------------- Primary server: gpfs1 Secondary server: blade2.cluster.net Node Daemon node name IP address Admin node name Designation ----------------------------------------------------------------------------------------------------------------------- 1 blade1 192.168.70.1 blade1 quorum-manager 2 blade2.cluster.net 192.168.70.2 blade2.cluster.net quorum-manager 3 blade3.cluster.net 192.168.70.3 blade3.cluster.net quorum-manager 4 blade4.cluster.net 192.168.70.4 blade4.cluster.net
IBM System x Enterprise Architecture Linux Advanced Management
- 49 -
NSD Disk ์์ฑ ๋ฐ ํ์ธ
[root@blade1 gpfslpp]# mmcrnsd -F diskfile -v no diskfile ์ ๋ด์ฉ > /dev/sdb:blade1:blade2:dataAndMetadata:1:: /dev/sdc:blade1:blade2:dataAndMetadata:1:: /dev/sdd:blade1:blade2:dataAndMetadata:1:: /dev/sde:blade1:blade2:dataAndMetadata:1:: /dev/sdf:blade2:blade1:dataAndMetadata:2:: /dev/sdg:blade2:blade1:dataAndMetadata:2:: /dev/sdh:blade2:blade1:dataAndMetadata:2:: /dev/sdi:blade2:blade1:dataAndMetadata:2:: [root@blade1 gpfslpp]# mmlsnsd File system Disk name Primary node Backup node --------------------------------------------------------------------------- (free disk) gpfs1nsd blade1 blade2.cluster.net (free disk) gpfs2nsd blade1 blade2.cluster.net (free disk) gpfs3nsd blade1 blade2.cluster.net (free disk) gpfs4nsd blade1 blade2.cluster.net (free disk) gpfs5nsd blade2.cluster.net blade1 (free disk) gpfs6nsd blade2.cluster.net blade1 (free disk) gpfs7nsd blade2.cluster.net blade1 (free disk) gpfs8nsd blade2.cluster.net blade1 * ์์ง filesystem ์ด ๋ง๋ค์ด ์ง์ง ์์ File system๋ถ๋ถ์ด free disk๋ก ๋ํ๋๋ค
File System ์์ฑ ๋ฐ mount
file system์ ์์ฑ ํ๊ธฐ ์ ์ ๋จผ์ mmstartup โa ๋ช ๋ น์ผ๋ก gpfs ๋ฐ๋ชฌ์ ์์ํด์ผ ํ๋ค.
nsd ๋์คํฌ ์์ฑ ์ดํ diskfile ์ ๋ด์ฉ > # /dev/sdb:blade1:blade2:dataAndMetadata:1:: gpfs1nsd:::dataAndMetadata:1:: # /dev/sdc:blade1:blade2:dataAndMetadata:1:: gpfs2nsd:::dataAndMetadata:1:: # /dev/sdd:blade1:blade2:dataAndMetadata:1:: gpfs3nsd:::dataAndMetadata:1:: # /dev/sde:blade1:blade2:dataAndMetadata:1:: gpfs4nsd:::dataAndMetadata:1:: # /dev/sdf:blade2:blade1:dataAndMetadata:2:: gpfs5nsd:::dataAndMetadata:2:: # /dev/sdg:blade2:blade1:dataAndMetadata:2:: gpfs6nsd:::dataAndMetadata:2:: # /dev/sdh:blade2:blade1:dataAndMetadata:2:: gpfs7nsd:::dataAndMetadata:2:: # /dev/sdi:blade2:blade1:dataAndMetadata:2:: # mmcrnsd๋ก nsd์์ฑ ํ diskfile ๋ด์ฉ์ด ํ์ผ์์คํ ์์ฑ์ ํ์ ๊ฐ์ผ๋ก ๋ฐ๋๋ค. [root@blade1 gpfslpp]# mmcrfs /gpfs1 gpfs1 -F diskfile -B 1024K -m1 -M1 -r1 -R1 # replication ๊ธฐ๋ฅ์ ์ฌ์ฉ ํ๊ธฐ์ํด์๋ -m2 โM2 โr2 โR2 ๋ก ์ต์ ์ ๋ณ๊ฒฝํด์ผ ํ๋ค. [root@blade1 gpfslpp]# mmmount gpfs1 โa [root@blade1 gpfslpp]# mmlsmount all -L File system gpfs1 is mounted on 4 nodes: 192.168.70.1 blade1 192.168.70.2 blade2.cluster.net 192.168.70.3 blade3.cluster.net 192.168.70.4 blade4.cluster.net
IBM System x Enterprise Architecture Linux Advanced Management
- 50 -
File system gpfs2 is mounted on 4 nodes: 192.168.70.2 blade2.cluster.net 192.168.70.3 blade3.cluster.net 192.168.70.1 blade1
192.168.70.4 blade4.cluster.net
[[root@blade1 gpfslpp]# mmlsnsd File system Disk name Primary node Backup node --------------------------------------------------------------------------- gpfs1 gpfs1nsd blade1 blade2.cluster.net gpfs1 gpfs2nsd blade1 blade2.cluster.net gpfs1 gpfs3nsd blade1 blade2.cluster.net gpfs1 gpfs4nsd blade1 blade2.cluster.net (free disk) gpfs5nsd blade2.cluster.net blade1 (free disk) gpfs6nsd blade2.cluster.net blade1 (free disk) gpfs7nsd blade2.cluster.net blade1 (free disk) gpfs8nsd blade2.cluster.net blade1
4.6 GPFS (GENERAL PARALLEL FILE SYSTEM) ์ด์ ๋ฐ ๊ด๋ฆฌ
4.6.1 GPFS ํ์ผ์์คํ ํ์ธ ๋ฐ ๊ด๋ฆฌ
ํ์ผ์์คํ ์์ฑ ํ์ธ ๋ช ๋ น mmlsdisk, mmlsfs
[root@blade1 gpfslpp]# mmlsdisk gpfs1 disk driver sector failure holds holds storage name type size group metadata data status availability pool ------------ -------- ------ ------- -------- ----- ------------- ------------ ------------ gpfs1nsd nsd 512 1 yes yes ready up system gpfs2nsd nsd 512 1 yes yes ready up system gpfs3nsd nsd 512 1 yes yes ready up system gpfs4nsd nsd 512 1 yes yes ready up system [root@blade1 gpfslpp]# mmlsfs gpfs1 flag value description ---- -------------- ----------------------------------------------------- -s roundRobin Stripe method -f 32768 Minimum fragment size in bytes -i 1024 Inode size in bytes -I 32768 Indirect block size in bytes -m 1 Default number of metadata replicas -M 1 Maximum number of metadata replicas -r 1 Default number of data replicas -R 1 Maximum number of data replicas -j cluster Block allocation type -D posix File locking semantics in effect -k posix ACL semantics in effect -a 1048576 Estimated average file size -n 32 Estimated number of nodes that will mount file system -B 1048576 Block size -Q none Quotas enforced none Default quotas enabled -F 417792 Maximum number of inodes -V 9.03 File system version. Highest supported version: 9.03 -u yes Support for large LUNs? -z no Is DMAPI enabled?
IBM System x Enterprise Architecture Linux Advanced Management
- 51 -
-E yes Exact mtime mount option -S no Suppress atime mount option -K whenpossible Strict replica allocation option -P system Disk storage pools in file system -d gpfs8nsd;gpfs9nsd;gpfs10nsd;gpfs11nsd Disks in file system -A yes Automatic mount option -o none Additional mount options -T /gpfs1 Default mount point
File System ์ฌ์ฉ๊ณต๊ฐ ํ์ธํ๊ธฐ
mmdf ๋ช ๋ น์ด๋ฅผ ์ด์ฉํ์ฌ ๋ชจ๋ GPFS ๋์คํฌ๋ค์ ์ฉ๋ ํ์ธ
ex) mmdf gpfs1
file system mount ๋ฐ umount
GPFS ํ์ผ์์คํ ์ ์์ฑํ ๋ ์๋์ผ๋ก ๋ง์ดํธ๋๋ ์ต์ (๋ํดํธ๊ฐ)์ผ๋ก ์์ฑํ๋ฉด GPFS ๋ฐ๋ชฌ์ด ์์๋
๋ ์๋์ผ๋ก ๋ง์ดํธ๋๋ค.
mmmount gpfs1 โa (์ nodes์ mount ํ ๋ -a์ต์ ์ฌ์ฉ)
mmumount gpfs1 -a
File System ์ ๊ฑฐํ๊ธฐ
GPFS ํ์ผ์์คํ ์ ์ ๊ฑฐํ๊ธฐ ์ํด์๋ ๋จผ์ ํ์ผ์์คํ ์ unmountํด์ผ ํ๋ค.
GPFS ํ์ผ์์คํ ์ mmdelfs ๋ช ๋ น์ด๋ก ์ ๊ฑฐํ ์ ์๋ค.
mmdelfs ๋ช ๋ น์ด
mmdelfs gpfs1 โp (์ฌ๊ธฐ์ p ์ต์ ์ ํ์ผ์์คํ ์ ๋ณด๊ฐ ์๋ชป๋์๊ฑฐ๋ ๋์คํฌ๊ฐ availableํ ์ํ๊ฐ ์
๋๋ผ๋ ๊ฐ์ ๋ก ์ญ์ ํ ์ ์๋ค.)
File System ์ค๋ฅ ์ฒดํฌ ๋ฐ ๋ณต๊ตฌํ๊ธฐ
gpfs์ mmfsck ๋ช ๋ น์ online, offline ๋๊ฐ์ง ๋ชจ๋์์ ์ฌ์ฉํ ์ ์๋ค.
ํ์ผ์์คํ ์ด ๋ง์ดํธ๋์ด ์๋ online์ํ์์๋ โo ์ต์ ์ ์ฌ์ฉํ์ฌ ํ์ผ์์คํ ์ ์ฒดํฌํ ์ ์๋ค. ๋ฐ
๋๋ก ํ์ผ์์คํ ์ด unmount๋ ์ํ์์๋ offline์ผ๋ก ํ์ผ์์คํ ์ ์ฒดํฌํ ์ ์๋ค.
Online ๋ชจ๋๋ ํ์ผ์์คํ ์ด ๋ง์ดํธ๋ ์ํ์์ ๋ฐฐ์น๋์ง ๋ชปํ ๋ธ๋ญ๋ค์ ์ฒดํฌํ๊ณ ๋ณต๊ตฌํ๋ค. ์ด์ธ์
๋ฌธ์ ๋ ์ฒดํฌํ์ฌ ๋ณด๊ณ ๋ง ํ๊ณ ๋ณต๊ตฌ๋ ํ์ง ์๋๋ค.
์์ ๋ค๋ฅธ ์ค๋ฅ๋ค์ ํด๊ฒฐํ๊ธฐ ์ํด์๋ ํ์ผ์์คํ ์ด unmount๋ offline๋ชจ๋์์ mmfsck๋ช ๋ น์ ์คํ
ํ์ฌ์ผ ํ๋ค.
Disk์ํ๊ฐ down์ํ๋ผ๋ฉด mmfsck ๋ช ๋ น์ ์ฌ์ฉํ ์ ์๋ค. ๋จผ์ mmlsdisk๋ช ๋ น์ด๋ก ๋์คํฌ ์ํ๋ฅผ ํ
์ธํ๊ณ down๋ ๋์คํฌ๊ฐ ์์ผ๋ฉด mmchdisk๋ช ๋ น์ผ๋ก unrecovered ๋ up์ํ๋ก ๋ง๋ ๋ค.
mmfsck ๋ช ๋ น์ด
ex) mmfsck gpfs1 โn (n์ต์ ์ ํ์ผ์์คํ ๋ณต๊ตฌ๋ฅผ ์๋ํ์ง ์๊ณ ์ฒดํฌ๋งํ๋ค.)
File System ์์ฑ ๋ณ๊ฒฝํ๊ธฐ
mmchfs ๋ช ๋ น์ด๋ฅผ ์ฌ์ฉํ์ฌ GPFS ํ์ผ์์คํ ์ ์์ฑ์ ๋ฐ๊ฟ ์ ์๋ค.
Usage:
IBM System x Enterprise Architecture Linux Advanced Management
- 52 -
mmchfs Device [-A {yes | no | automount}] [-D {posix | nfs4}] [-E {yes | no}]
[-F MaxNumInodes] [-k {posix | nfs4 | all}]
[-K {no | whenpossible | always}]
[-m DefaultMetadataReplicas] [-o MountOptions]
[-Q {yes | no}] [-r DefaultDataReplicas] [-S {yes | no}]
[-T Mountpoint] [-V] [-z {yes | no}]
or
mmchfs Device [-W NewDeviceName]
File System Restriping ํ๊ธฐ
GPFS๋ ํ์ผ์ writeํ๋ฉด์ striping์ ํ๋ค. ๊ทธ๋ฐ๋ฐ ๋์คํฌ๋ฅผ ์ถ๊ฐํ ํ์ performance๋ฅผ ํฅ์์ํค๊ธฐ
์ํด์๋ mmrestripefs ๋ช ๋ น์ด๋ฅผ ์ด์ฉํ์ฌ ํ์ผ์ restripeํ ์ ์๋ค. ๋์คํฌ ๋ณต์ (replication)๋ฅผ ํ
์ง ์์ ์ํ๋ผ๋ฉด โm ์ต์ ์ ์ฌ์ฉํ์ฌ fail๋ ๋์คํฌ๋ก๋ถํฐ ๋ฐ์ดํฐ๋ฅผ ์์ ํ๊ฒ ๋ณต๊ตฌํ ์ ์๋ค. ๋ง์ฐฌ๊ฐ
์ง๋ก โr ์ต์ ๋ ๊ฐ์ ํจ๊ณผ๋ฅผ ๋ผ ์ ์๋ค. ๋์คํฌ ๋ณต์ (replication)๋ฅผ ํ ์ํ๋ผ๋ฉด โb(rebalance) ์ต์ ์ผ
๋ก replication data๋ restripeํ ์ ์๋ค.
mmrestripefs ๋ช ๋ น์ด
ex) mmrestripefs gpfs1 โr
File System ๋จํธํ ์ ๋ณด ๋ณด๊ธฐ ๋ฐ ์ต์ ํ
ํ์ผ์์คํ ์ ๋ฐ์ดํฐ๋ฅผ ๊ธฐ๋กํ ๋ fragmented block์ผ๋ก ์กฐ๊ฐ๋๋ ๊ฒ์ ํผํ ์ ์๋ค. ๊ทธ๋ฌ๋ ์ด๋ฐ ์กฐ
๊ฐ๋ค์ค์ ๋ฐ์ดํฐ๋ฅผ ๊ฐ๋์ฑ์ฐ์ง ๋ชปํ๊ณ block์ ์ผ๋ถ๋ง ์ฌ์ฉํ๋ ๋จํธ๋ค๋ ์๊ธฐ๊ฒ ๋๋ค. ์ด๋ฐ ๋จํธ๋ค์
๋์คํฌ ๊ณต๊ฐ์ ๋ญ๋นํ๊ฒ ๋๋ ์์ธ์ค์ ํ๋๊ฐ ๋๋ค. ์ด๋ ๊ฒ ๋์คํฌ ๊ณต๊ฐ์ ๋ญ๋นํ๋ fragmented block
์ ์กฐ๊ฐ๋ชจ์์ ํ์ฌ ๋์คํฌ ๊ณต๊ฐ์ ํจ์จ์ ๋์ด๊ธฐ ์ํด mmdefragfs ๋ช ๋ น์ด๋ฅผ ์ฌ์ฉํ๋ค.
ํ์ผ์์คํ ์ ๋จํธํ ์ ๋๋ฅผ ์๊ธฐ ์ํด์๋ mmdefragfs ๋ช ๋ น์ด์ โi ์ต์ ์ ์ฌ์ฉํ๋ค.
File System ์ต์ ํ
Block์ ์ฌ์ฉ์จ์ ๋์ด๊ธฐ ์ํ ์กฐ๊ฐ๋ชจ์์ ํ๊ธฐ ์ํด์๋ mmdefragfs ๋ช ๋ น์ด๋ฅผ ์คํํ๋ค.
-u ์ต์ ์ผ๋ก ๋ชฉํ๋ก ํ๋ block ์ฌ์ฉ์จ (Block utilization )์ ์ง์ ํ ์ ์๋ค.
mmdefragfs ๋ช ๋ น์ด
ex) mmdefragfs gpfs1
File System ๋์คํฌ ์ถ๊ฐ
ํ์ผ์์คํ ์ ํ์ผ๋ค์ด ์ฆ๊ฐํ์ฌ ํ์ผ์์คํ ๊ณต๊ฐ์ ๋๋ ค์ผ ํ ๋ GPFS๋ ๋น ๋ฅด๊ฒ ๋์คํฌ๋ฅผ ์ถ๊ฐํ์ฌ
ํ์ผ์์คํ ๊ณต๊ฐ์ ๋๋ฆด ์ ์๋ค. ์ด๋ mmadddisk ๋ช ๋ น์ด๋ฅผ ์ฌ์ฉํ๋ค.
root@blade1 gpfslpp]# mmlsnsd -F File system Disk name Primary node Backup node --------------------------------------------------------------------------- (free disk) gpfs5nsd blade2.cluster.net blade1 (free disk) gpfs6nsd blade2.cluster.net blade1 (free disk) gpfs7nsd blade2.cluster.net blade1 (free disk) gpfs8nsd blade2.cluster.net blade1
IBM System x Enterprise Architecture Linux Advanced Management
- 53 -
* free disk ๋ก ๋จ์์๋ gpfs5nsd ๋์คํฌ๋ฅผ gpfs1 ํ์ผ ์์คํ ์ ์ถ๊ฐ ํ ์์ [root@blade1 gpfslpp]# mmadddisk gpfs1 gpfs5nsd:::dataAndMetadata:1:: -r -v no * ์ฌ๊ธฐ์ r ์ต์ ์ ๋์คํฌ๋ฅผ ์ถ๊ฐํ ๋ค์ rebalance ํ๋ผ๋ ์ต์ ์ [root@blade1 gpfslpp]# mmlsnsd File system Disk name Primary node Backup node --------------------------------------------------------------------------- gpfs1 gpfs1nsd blade1 blade2.cluster.net gpfs1 gpfs2nsd blade1 blade2.cluster.net gpfs1 gpfs3nsd blade1 blade2.cluster.net gpfs1 gpfs4nsd blade1 blade2.cluster.net gpfs1 gpfs5nsd blade2.cluster.net blade1 (free disk) gpfs6nsd blade2.cluster.net blade1 (free disk) gpfs7nsd blade2.cluster.net blade1 (free disk) gpfs8nsd blade2.cluster.net blade1 * mmlsnd ๋ช ๋ น์ผ๋ก gpfs1 ํ์ผ ์์คํ ์ ๋์คํฌ๊ฐ ์ถ๊ฐ ๋ ๊ฒ์ ํ์ธ ํ ์ ์๋ค.
File System์์ ๋์คํฌ ์ ๊ฑฐ
๋์คํฌ๋ฅผ ์ ๊ฑฐํ๊ธฐ ์ ์ mmdf ๋ช ๋ น์ด๋ก ๋์คํฌ๋ฅผ ์ญ์ ํด๋ ํ์ผ์์คํ ์ ์ฌ์ ๊ณต๊ฐ์ด ๋จ๋์ง ํ์ผ์์ค
ํ ์ ๋จ์์๋ ์ฉ๋์ ํ์ธํด์ผ ํ๋ค. ๋์คํฌ๋ฅผ ์ญ์ ํ๋ ค๋ฉด ๋จ์์๋ ์ฉ๋์ด ์ญ์ ํ ๋์คํฌ ์ฉ๋์
150%์ด์์ด์ด์ผ ํ๋ค.
* ์์์ ์ถ๊ฐํ gpfs5nsd๋์คํฌ๋ฅผ gpfs1 ํ์ผ ์์คํ ์์ ์ ๊ฑฐ [root@blade1 gpfslpp]# mmdeldisk gpfs1 gpfs5nsd โr [root@blade1 gpfslpp]# mmlsnsd File system Disk name Primary node Backup node --------------------------------------------------------------------------- gpfs1 gpfs1nsd blade1 blade2.cluster.net gpfs1 gpfs2nsd blade1 blade2.cluster.net gpfs1 gpfs3nsd blade1 blade2.cluster.net gpfs1 gpfs4nsd blade1 blade2.cluster.net (free disk) gpfs5nsd blade2.cluster.net blade1 (free disk) gpfs6nsd blade2.cluster.net blade1 (free disk) gpfs7nsd blade2.cluster.net blade1 (free disk) gpfs8nsd blade2.cluster.net blade1 * gpfs5nsd ๋์คํฌ๊ฐ free disk๋ก ๋ณ๊ฒฝ ๋ ๊ฒ ์ ํ์ธ ํ ์ ์๋ค.
4.6.2 GPFS Node ๊ด๋ฆฌ
GPFS Cluster์ nodes ์ถ๊ฐ ๋ฐ ์ ๊ฑฐ
mmaddnoe๋ช ๋ น์ผ๋ก gpfs cluster์ ์๋ก์ด node๋ฅผ ์ถ๊ฐ ์ํฌ ์๋ ์๊ณ mmdelnode ๋ช ๋ น์ผ๋ก ์ญ์ ํ
์ ๋ ์๋ค.
ex) mmaddnode blade4
mmdelnode blade4
mmlsnode โa ๋ช ๋ น์ผ๋ก cluster nodes ํ์ธ
File System ๊ด๋ฆฌ nodes ๋ณ๊ฒฝ ๋ฐ ํ์ธ
ํ์ผ์์คํ ์ ๊ด๋ฆฌํ๋ ๋ ธ๋ ์ ๋ณด๋ mmlsmgr ๋ช ๋ น์ด๋ก ๋ณผ ์ ์๋ค.
mmlsmgr
mmlsmgr gpfs1
IBM System x Enterprise Architecture Linux Advanced Management
- 54 -
์ ๋ช ๋ น์ด๋ฅผ ์คํํ๋ฉด ์๋์ ๊ฐ์ด ํ์ผ์์คํ ์ device name๊ณผ ํด๋น ํ์ผ์์คํ ์ ๊ด๋ฆฌํ๋ ๋ ธ๋๊ฐ
์ด๋ค ๋ ธ๋์ธ์ง๋ฅผ ๋ณด์ฌ์ค๋ค.
๋ํ ํ์ผ์์คํ ์ ๊ด๋ฆฌํ๋ ๋ ธ๋๋ฅผ mmchmgr ๋ช ๋ น์ด๋ก ์ํ๋ ๋ ธ๋๋ก ๋ฐ๊ฟ ์ ์๋ค.
mmchmgr
mmchmgr gpfs1 blade3
์ ๋ช ๋ น์ด๋ฅผ ์คํํ๋ฉด ์๋์ ํด๋น ํ์ผ์์คํ ์ ๊ด๋ฆฌํ๋ ๋ ธ๋๊ฐ blade1์์ blade2๋ก ๋ฐ๋ ๊ฒ์ ์
์ ์๋ค.
GPFS Daemon ์์ ๋ฐ ์ค์ง
GPFS๋ mmstartup ๋ช ๋ น์ด๋ฅผ ์ฌ์ฉํ์ฌ ์์ํ ์ ์๋ค.
mmstartup โa
์ ๋ช ๋ น์ด๋ฅผ ์คํํ๋ฉด cluster์ ์๋ ๋ชจ๋ ๋ ธ๋์์ GPFS ๋ฐ๋ชฌ์ด ์์๋๋ค.
mmstartup โN NodeName
์ ๋ช ๋ น์ด ์คํ๋๋ฉด ๋ช ๋ น์ ์คํํ ๋ ธ๋์ GPFS ๋ฐ๋ชฌ๋ง ์ฌ๋ผ์จ๋ค.
GPFS๋ mmshutdown ๋ช ๋ น์ด๋ก ์ค์ง์ํฌ ์ ์๋ค.
mmshutdown โa
์ ๋ช ๋ น์ด๋ฅผ ์คํํ๋ฉด ๋ชจ๋ ๋ ธ๋์์ GPFS ๋ฐ๋ชฌ์ด ์ค์ง๋๋ค.
mmshutdown โN NodeName
์ ๋ช ๋ น์ด๋ฅผ ์คํํ๋ฉด ํด๋น ๋ ธ๋์ GPFS ๋ฐ๋ชฌ๋ง ์ค์ง๋๋ค.
mmgetstate ๋ช ๋ น์ผ๋ก gpfs ์๋น์ค๋ฅผ ํ์ธ ํ ์ ์๋ค.
mmgetstate โa ๋ช ๋ น์ผ๋ก ์ ์ฒด nodes ์๋น์ค ํ์ธ
mmgetstate โaL ๋ช ๋ น์ผ๋ก quorum nodeํ์ธ
4.6.3 GPFS Config ๋ณ๊ฒฝ
GPFS Cluster configuration์ ๋ณ๊ฒฝ ํ ๋๋ gpfs ๋ฐ๋ชฌ์ ๋ด๋ฆฌ๊ณ ์์ ํด์ผ ํ๋ค.
GPFS Cluster configuration data์ ๋ณ๊ฒฝ
mmchcluster
usage : mmchcluster -p ngstfe1_gpfs ( primary server๋ฅผ ๋ฐ๊ฟ๋ ์ฌ์ฉ )
mmchcluster -s ngdtfe1_gpfs ( secondary server๋ฅผ ๋ฐ๊ฟ๋ ์ฌ์ฉ )
mmchcluster -C cluster_name ( cluster name์ ๋ฐ๊ฟ๋ ์ฌ์ฉ )
mmchcluster -p LATEST ( primary server config ์ ๋ณด๋ฅผ ๋๊ธฐํ ํ ๋)
GPFS cluster configuration parameter ์ ๋ณ๊ฒฝ
mmchconfig
usage : mmchconfig attribute=value -i ( ์คํํ ์ฆ์ ๋ฐ์๋๊ณ restartํ์๋ ์ง์๋จ )
mmchconfig attribute=value -I ( ์คํํ ์ฆ์ cluster์ ๋ฐ์๋จ restartํ ์ ์ฉ ์๋จ )
IBM System x Enterprise Architecture Linux Advanced Management
- 55 -
Attribute
autoload - cluster node๊ฐ rebooting ์ ์๋์ผ๋ก GPFS start
maxFilesToCache - ์ต๊ทผ์ ์ฌ์ฉํ inode ๊ฐ์ default ( 1000 )
maxMBpS - Data ์ ์ก์๋ default ( 150MB/s )
maxStatCache - stat cache์ ์ ์งํ inode๊ฐ์
pagepool - cache on each node default ( 64MB ) > 500M
tiebreakerDisks - node quorum๊ณผ ๊ฐ์ด ์ฌ์ฉ
umountOnDiskFail - disk์ ์ฅ์ ๊ฐ ๋ฐ์ํ์ ๋ ๊ฐ์ ๋ก file system์ umount ์ํด ( yes or no )
* GPFS test ์๋ฒ์ Configuration ๊ฐ ํ์ธ [root@blade1 gpfslpp]# mmlsconfig Configuration data for cluster gpfstest.blade1: ----------------------------------------------- clusterName gpfstest.blade1 clusterId 13882422822655914773 clusterType lc autoload no useDiskLease yes maxFeatureLevelAllowed 906 maxMBpS 512 maxblocksize 2048k pagepool 256M [blade1] takeOverSdrServ yes File systems in cluster gpfstest.blade1: ---------------------------------------- /dev/gpfs1
4.7 GPFS(GENERAL PARALLEL FILE SYSTEM) ๊ตฌ์ฑ๋ณ๊ฒฝ ๋ฐ ์ฅ์ ๋ณต๊ตฌ
4.7.1 GPFS cluster IP ๋ฐ host name ๋ณ๊ฒฝ
GPFS IP address์ hostnames์ ๋ณ๊ฒฝํ๋ ค๋ฉด ์๋์ ๋จ๊ณ๋ฅผ ๋ฐ๋ผ์ผ ํ๋ค.
์ ์ฒด nodes IP addresses ์ hostnames ๋ณ๊ฒฝ
IP addresses ์ hostnames ๋ณ๊ฒฝ ์ ์ 1.primary GPFS cluster ์๋ฒ์์ /var/mmfs/gen/mmsdrfs file๋ฐฑ์ 2.configuration parameter์ค์ ์ ๊ธฐ๋กํ๋ค. 3.mmshutdown โa ๋ช ๋ น์ผ๋ก ์ nodes gpfs ๋ฐ๋ชฌ ์ค์ง ex) [root@blade1 gpfslpp]# mmexportfs all โo gpfs_backup Usage: mmexportfs {Device | all} -o ExportfsFile 4.mmexportfs all ๋ช ๋ น์ผ๋ก file system ์ ๋ณด๋ฅผ outfile๋ก ๋ง๋ค์ด ๋ด๋ณด๋ธ๋ค. ! mmexportfs ๋ช ๋ น์ ์คํํ๋ฉด ๊ธฐ์กด cluster์์ filesystem ๋ฐ disk์ ๋ณด๊ฐ ์ฌ๋ผ์ง 5.IP addresses ์ hostnames ๋ณ๊ฒฝ 6.mmcrcluster ๋ช ๋ น์ผ๋ก cluster ์ฌ์์ฑ 7.mmchconfig ๋ช ๋ น์ผ๋ก configuration parameter ๋ณต๊ตฌ 8.mmimportfs all ๋ช ๋ น์ผ๋ก file system ๋ฐ disk ์ ๋ณด๋ฅผ ๋ณต๊ตฌ ex) [root@gpfs1 gpfslpp]# mmimportfs all โi gpfs_backup Usage: mmimportfs {Device | all} -i ImportfsFile [-S ChangeSpecFile]
Client nodes IP addresses ์ hostnames ๋ณ๊ฒฝ
IP addresses ์ hostnames ๋ณ๊ฒฝ ์ ์
IBM System x Enterprise Architecture Linux Advanced Management
- 56 -
1.primary GPFS cluster ์๋ฒ์์ /var/mmfs/gen/mmsdrfs file๋ฐฑ์ 2.mmshutdown โa ๋ช ๋ น์ผ๋ก ์ nodes gpfs ๋ฐ๋ชฌ ์ค์ง 3.mmdelnode ๋ช ๋ น์ผ๋ก ๋ณ๊ฒฝ๋ node ์ ๊ฑฐ 4.mmaddnode ๋ช ๋ น์ผ๋ก ๊ธฐ์กด cluster์ ํฌํจ ์ํจ๋ค primary or secondary configuration์๋ฒ IP addresses ์ hostnames ๋ณ๊ฒฝ 5.mmchcluster ๋ช ๋ น์ผ๋ก primary or secondary ์๋ฒ role ๋ณ๊ฒฝ mmchcluster โp PrimaryNode primary๋ก ๋ณ๊ฒฝ ๋ node๋ช mmchcluster โs SecondaryNode secondary๋ก ๋ณ๊ฒฝ ๋ node๋ช ip addresses ๋ฐ hostnames ๋ณ๊ฒฝ ํ configuration ์๋ฒ role ๋ณ๊ฒฝ
primary or backup NSD ์๋ฒ IP addresses ์ hostnames ๋ณ๊ฒฝ
1.mmchnsd ๋ช ๋ น์ผ๋ก primary or backup NSD ์๋ฒ ์์ด directly-attached NSD๋ก ๋ณ๊ฒฝ [root@blade1 /]# mmchnsd โgpfs1nsd;gpfs2nsd;gpfs3nsd;gpfs4nsdโ 2.ip addresses ๋ฐ hostnames ๋ณ๊ฒฝ ํ mmchnsd๋ณ๊ฒฝ์ผ๋ก ๋ณต๊ตฌ [root@gpfs1 /]# mmchnsd "gpfs1nsd:blade1:blade2:::" 3.mmlsnsd ๋ช ๋ น์ผ๋ก primary or backup NSD ์๋ฒ ํ์ธ [root@gpfs1 /]# mmlsnsd -d "gpfs1nsd" File system Disk name Primary node Backup node ---------------------------------------------------------------------------
gpfs1 gpfs1nsd blade1 blade2
4.7.2 GPFS cluster configuration data ํ์ผ ๋ณต๊ตฌ
GPFS cluster configuration data ํ์ผ์ /var/mmfs/gen/mmsdrfs ํ์ผ์ ์ ์ฅ๋๋ค. ์์คํ ์ฅ์ ๋ก ์ธ
ํ ์๋ฒ ์ฌ ์ค์น๋, ์ฌ์ฉ์ ์ค์๋ก ์ธํ์ฌ mmsdrfsํ์ผ์ด ์ญ์ ๋๋ ๊ฒฝ์ฐ ๋ค๋ฅธ ์๋ฒ์ ์๋ mmsdrfsํ
์ผ๋ก ๊ตฌ์ฑ์ ๋ณด๋ฅผ ๋ณต๊ตฌ ํ ์ ์๋ค. ํ์ง๋ง ์ต์ level๋ก ํ์ผ์ ๋๊ธฐํ ํ๊ธฐ ์ํด์ primary or
secondary ํ์ผ๋ก ๋ณต๊ตฌ ํ ๊ฒ์ ๊ถ์ฅ ํ๋ค. GPFS cluster ๊ตฌ์ฑ ํ ๋ชจ๋ nodes mmsdrfs ํ์ผ์ ๋ฐฑ์
๋ฐ๋ ๊ฒ์ ๊ถ์ฅ ํ๋ค.
1.mmshutdown โa ๋ช ๋ น์ผ๋ก ๋ชจ๋ nodes์์ gpfs ๋ฐ๋ชฌ ์ค์ง 2.mmsdrfs ํ์ผ์ด ์ญ์ ๋ node์์ mmsdrrestore ๋ช ๋ น ์คํ [root@blade2 /]# mmsdrrestore โp blade1 โF /var/mmfs/gen/mmsdrfs โR /usr/bin/scp Usage: mmsdrrestore โp remoteNode โF remoteFile โR RemoteFileCopyCommand 3.mmchcluster โp LATEST๋ช ๋ น์ผ๋ก ์ต์ level๋ก ๋๊ธฐํ [root@blade2 /]# mmchcluster โp LATEST 4.mmstartup โa ๋ช ๋ น์ผ๋ก ์ฅ์ ์๋ฒ๊ฐ ์ ์์ ์ผ๋ก ๋์ํ๋์ง ํ์ธ
IBM System x Enterprise Architecture Linux Advanced Management
- 57 -
5. XEN
5.1 Xen
์๋ฒ์ ์์์ ๊ฐ์ํ ํ์ฌ, ํ๋์ ๋ฌผ๋ฆฌ์ ์ธ ์๋ฒ์ ์ฌ๋ฌ ๊ฐ์ง OS๋ฅผ ์ค์นํ ์ ์๋ ๊ฐ์๋จธ์ ์ ํ
๊ฒฝ์ ๋ง๋ค์ด ์ฃผ๋ ์๋ฃจ์ ์ผ๋ก, Intel Server ์ ์ฌ์ฉํ๋ Vmware ์, IBM System p ์ ์ฌ์ฉํ๋
LPAR ์ ์ ์ฌํ๋ค.
5.2 Xen ์์ ์ง์ํ๋ ๊ฐ์ํ ํํ
A) Para Virtualization
System์ ๋ชจ๋ ์์์ ๊ฐ์ํ ํ๋ ๊ฒ์ด ์๋๋ผ, ์ค์น๋๋ ๊ฐ์๋จธ์ ์ด Xen Kernel ๊ณผ
Communicationํ๊ธฐ ์ํ API๊ฐ ์์ด์ผ ํ๋๋ฐ ์ด ๊ฒฝ์ฐ์๋ Virtual Machine ์ ์ค์น๋๋ OS ์
Kernel ์ด ์์ ๋์ด์ผ ํ๋ค. ๊ทธ
๋ฌ๋ Full Virtualization ์ ๋นํด
์ฑ๋ฅ์ ์ข์ ํธ์ด๋ฉฐ, Memory
Ballooning ์ ์ง์ํ์ฌ ์์คํ
์ Memory๋ฅผ ์ข๋ ํจ์จ์ ์ผ๋ก
๊ด๋ฆฌ ๊ฐ๋ฅํ๋ค.
B) Full Virtualization
Intel ๋ฐ AMD ์์ ์ ๊ณตํ๋
Virtualization ๊ธฐ๋ฅ์ด ์๊ณ ,
BIOS ์์ ๋ณธ ๊ธฐ๋ฅ์ Enableํด
์ผ๋ง ์ฌ์ฉ ๊ฐ๋ฅํ๋ค.
5.3 Xen ์ ๊ธฐ๋ณธ ๊ตฌ์กฐ ๋ฐ Memory Ballooning ์ด๋?
์์ ๋ด์ฉ๊ณผ ๊ฐ์ด Xen ์ ๊ธฐ๋ณธ ๊ตฌ์กฐ๋ฅผ ์ดํด ๋ณด๋ฉด, HW ์์ Hypervisor ๊ฐ ์ฌ๋ผ๊ฐ ์์ผ๋ฉฐ, ์ค์
Virtual Domain ์ ๊ด๋ฆฌ ํ๊ธฐ ์ํ Domain0 ๊ฐ ์๊ณ , Domain 1,2,โฆ ์ด๋ฐ ๊ฐ์ ๋จธ์ ์ Hypervisor ๋ฅผ
ํตํ์ฌ ์ค์ ํ๋์จ์ด๋ฅผ Access ํ๊ฒ ๋์ด ์์ต๋๋ค. ๋ํ Full Virtualization ์์๋ ๊ฐ์ ๋จธ์ ์ด
Operation ์ค์ ์์คํ Memory Size๋ฅผ ํ์ฅ ํ ์ ์์ง๋ง, Para-Virtualization ํ๊ฒฝ์์๋ ์์
Memory Ballooning ์ ๊ทธ๋ฆผ์ฒ๋ผ, ์์คํ OS ๋ฅผ Operation ์ค์ ์์คํ ๋ฉ๋ชจ๋ฆฌ์ ์์ญ์ ํ์ฅ์ด ๊ฐ๋ฅ
ํ๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 58 -
5.4 Xen ๊ตฌ์ฑ ์ ํ์ธ ์ฌํญ
Para-virtualized guest installํ๊ธฐ ์ํด์๋
CPU๊ฐ PAE๋ฅผ ์ง์ํด์ผ ํจ. x86_64, ia64๋
PAE๋ฅผ ์ง์ํ์ง๋ง i386์ ๊ฒฝ์ฐ๋ ์๋์ ๊ฐ์ด
PAE๋ฅผ ์ง์ํ๋์ง ํ์ธํด์ผ ํ๋ค.
# grep pae /proc/cpuinfo flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall nx lm constant_tsc pni monitor ds_cpl vmx est tm2 cx16 xtpr lahf_lm
Full-virtualized guest installํ๊ธฐ ์ํด์๋ CPU๊ฐ Intel-VT ๋๋ AMD-V๋ฅผ ์ง์ํด์ผ ํ๋ค.
ํ์ธํ๋ ๋ฐฉ๋ฒ์ ์๋์ ๊ฐ๋ค.
# egrep -e 'vmx|svm' /proc/cpuinfo flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe constant_tsc pni monitor vmx est tm2 xtpr
5.5 virt-install ๋ช ๋ น์ผ๋ก Xen para-virtualized guest install
1. virt-install ๋ช ๋ น ์คํํ์ full virtualized guest๋ก ์ธ์คํจํ ๊ฒ์ธ๊ฐ๋ฅผ ๋ฌผ์ผ๋ฉด no๋ฅผ ์ ๋ ฅ. ๋ง์ฝ
Full-virtualized guest๋ก install ํ๋ ค๋ฉด yes๋ฅผ ์ ๋ ฅ
2. virtual machine name๋ฅผ ์ ๋ ฅ(์ด๋ฆ์ ์์๋ก) : rhel5b_pv1
3. virtual machine์ด ์ฌ์ฉํ ๋ฉ๋ชจ๋ฆฌ์์ ์ ๋ ฅ(megabyte) : 500
4. guest๊ฐ ํ์ผ์์คํ ์ผ๋ก ์ฌ์ฉํ guest image ์ด๋ฆ์ ์ ๋ ฅ(์ ๋๊ฒฝ๋ก ํฌํจ) :
/xen/rhel5b_pv1.img
5. guest๊ฐ ์ฌ์ฉํ ๋์คํฌ ์ฉ๋์ ์ ๋ ฅ(gigabyte): 6
6. guest OS install source๋ฅผ ์ ๋ ฅ : nfs:192.168.12.57:/install ๋๋ http://192.168.12.57/install
7. Para-virtualization์ network intall๋ง ์ง์ํจ. ๋ฐ๋ผ์ NFS๋ http๋ก OS source๋ฅผ ๋ฏธ๋ฆฌ
exportํด ๋์์ผ ํจ.
8. installation์ด ์งํ๋จ.
IBM System x Enterprise Architecture Linux Advanced Management
- 59 -
xwindow์์ virt manager๋ฅผ ํตํด install์ ๊ณ์ ์งํํ ์ ์์.(graphics support๋ฅผ yes๋ก ํ
๊ฒฝ์ฐ, no๋ก ํ์ ์๋ test mod๋ก install์ด ์งํ๋จ.)
Virtual machine ์คํ guest domain running ํ์ธ
IBM System x Enterprise Architecture Linux Advanced Management
- 60 -
Guest domain์ ์ ํํ์ฌ open์ ํ๋ฉด ํด๋น guest domain์ ์ฝ์์ฐฝ์ด ๋ธ.
๊ณ์ ์ค์น ์งํ
IBM System x Enterprise Architecture Linux Advanced Management
- 61 -
5.6 virt-manager๋ช ๋ น์ผ๋ก Xen para-virtualized guest install
A) xwindows ์ฝ์์ฐฝ์์ virt-manager ๋ช ๋ น์ ์ ๋ ฅํ๊ฑฐ๋ ์๋์ ๊ฐ์ด X์๋์ฐ application ๋ฉ๋ด์์
์ ํ
B) Virtual Machine Manager ๊ธฐ๋ณธ์ฐฝ์ด ํ์ ๋๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 62 -
C) ์๋จ ๋ฉ๋ด์์ ์๋์ ๊ฐ์ด new machine์ ์ ํ
D) ์๋์ ๊ฐ์ ์ฐฝ์ด ํ์ ๋๋ฉด Forward ์ ํ
IBM System x Enterprise Architecture Linux Advanced Management
- 63 -
E) virtual system ์ด๋ฆ์ ์ ํ์ฌ ์ ๋ ฅ
F) paravirtualized๋ฅผ ํ ์ง Fully virtualized๋ฅผ ํ ์ง ์ ํ ํ Forward ์ ํ
IBM System x Enterprise Architecture Linux Advanced Management
- 64 -
G) paravirtualized๋ฅผ ์ ํํ์ ๊ฒฝ์ฐ๋ ์๋์ ๊ฐ์ด network install source ์ฃผ์๋ฅผ ์ ๋ ฅํ๋ ๋ฉ๋ด๋ก ๋
์ด๊ฐ๋ค. ๋ฏธ๋ฆฌ ๊ตฌ์ฑํ NFS, HTTP ์๋ฒ ์ฃผ์๋ฅผ ์ ๋ ฅํ๊ณ kickstart ํ์ผ์ด ์ค๋น๋์ด ์์ผ๋ฉด ๊ทธ ์ฃผ์๋ฅผ
์ ๋ ฅํ๋ค.
H) virtual system์ ์ค์นํ ์คํ ๋ฆฌ์ง ์์ญ์ ์ค์ ํ๋ค. ๋ฌผ๋ฆฌ์ ํํฐ์ ์ด ์ค๋น๋์ด ์์ผ๋ฉด ์ฒซ๋ฒ์งธ
Normal Disk Partition์ ํด๋น ํํฐ์ ์ ๋๋ฐ์ด์ค๋ช ์ ์ ๋ ฅํ๊ณ ์ด๋ฏธ์งํ์ผ์ ์ค์น๋ฅผ ํ๋ ค๋ฉด Simple
file์ ์ ๋๊ฒฝ๋ก/name.img ํ์์ผ๋ก ์ ๋ ฅ์ ํด์ค๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 65 -
I) ๋ค์ ํ๋ฉด์์ vitual system์ ํ ๋นํ ๋ฉ๋ชจ๋ฆฌ์ CPU ๊ฐ์์ ์ต๋ ํ์ฉ๋์ ์ ํ
J) ๋ค์ ํ๋ฉด์์ ์ต์ข ์ค์ ์ ๋ณด๋ค์ ํ์ธํ ํ์ Finish๋ฅผ ์ ํ
IBM System x Enterprise Architecture Linux Advanced Management
- 66 -
K) ์ค์ ์์ ์ ๋๋ด๋ฉด virtual machine ์์ฑ์์ ์ด ์คํ๋๋ค
L) OS ์ค์นํ๋ฉด์ด ํ์ ๋๋ฉด ์ผ๋ฐ OS์ ๋์ผํ๊ฒ install์ ์งํํ๋ค
IBM System x Enterprise Architecture Linux Advanced Management
- 67 -
5.7 Virtual system Management
A) Virtual Machine Manager ๊ธฐ๋ณธ ํ๋ฉด
B) Virtual Machine Manager ๊ธฐ๋ณธ ํ๋ฉด์์ ํด๋น virtual system์ ์ ํํ ํ์ ์๋ Details๋ฅผ ํด๋ฆญํ
๋ฉด ์๋์ ๊ฐ์ ๊ด๋ฆฌ์ฐฝ์ด ํ์ ๋๋ค. ์๋จ ํญ์์๋ virtual system์ shutdown/Pause ํ ์ ์๋ ํญ์ด
์๋ค.
IBM System x Enterprise Architecture Linux Advanced Management
- 68 -
C) Hardware ํญ์ ์ ํํ๋ฉด virtual system์ ํ ๋น๋ CPU, memory, disk, network ์ ๋ณด ํ์ธ ๋ฐ ์ค์
๋ณ๊ฒฝ์ ํ ์ ์๋ค.
D) ๋ฉ๋ชจ๋ฆฌ ๊ด๋ฆฌ ํญ
IBM System x Enterprise Architecture Linux Advanced Management
- 69 -
E) ๋์คํฌ ๊ด๋ฆฌ ํญ
F) Network ๊ด๋ฆฌํญ
IBM System x Enterprise Architecture Linux Advanced Management
- 70 -
5.8 Command ๊ธฐ๋ฐ Management
A. xm create [virtual system name] : ์ด๋ฏธ ์์ฑ์ด ๋์ด ์๊ฑฐ๋ ์์ฑํ virtual system์ ์์ํ๋ค.
B. xm console [virtual system name] : virtual system์ ์ฝ์์ ๋์ด๋ค.(para-virtualized์ ๊ฒฝ์ฐ ์ ์ฉ
ํจ)
C. xm destory [virtual system name] : virtual system์ ์ ๊ฑฐํ๋ค.
D. xm shutdown [virtual system name] : virtual system์ shutdown(full-virtualized์ ๊ฒฝ์ฐ๋ hard
poweroff๋ฅผ ํ๋ค)
E. xm top [virtual system name] : top๊ณผ ๋น์ทํ ์์คํ ๋ชจ๋ํฐ๋ง์ ํ ์ ์๋ค.
F. xm mem-set [virtual system name] [value] : para-virtualized guest์ ๋ฉ๋ชจ๋ฆฌ ์ฌ์ด์ฆ๋ฅผ ์กฐ์ ํ๋ค.
G. xm vcpu-set [virtual system name] [value] : : para-virtualized guest์ CPU ๊ฐ์๋ฅผ ์กฐ์ ํ๋ค.