Solaris進階系統管理授課筆記 第三天

來源:互聯網
上載者:User

SA-299 第三天
-------------

===================================================
建立狀態資料庫State Database Replica

看現有磁碟分割
-------------

format

建立狀態資料庫
-------------
 
metadb -a -f c0t0d0s4 c0t0d0s5 c0t0d0s6 c0t0d0s7

metadb

===================================================
從現有系統建立Install Flash

flarcreate -n flash_root_archive -c -R / -e root_archive -x /flash /
-a admin_operator /flash/flash_archive1

===================================================
從CD-ROM/DVD建立Install Image

mkdir /export/install

cd /cdrom/cdrom0/s0/Solaris_9/Tools

./setup_install_server /export/install

cd /

eject cdrom

 

===================================================
Custom JumpStart Installation

vi /etc/vfstab

mkdir /export/install

# mountall

mount /dev/dsk/c0t0d0s7 /export/install/

cd /cdrom/cdrom0/s0/Solaris_9/Tools

./setup_install_server /export/install

#./setup_install_server -b /export/install

cd /cdrom/cdrom0/Solaris_9/Tools

./add_to_install_server /export/install

root_password=NyN4lId2b2SQQ

cd /export/config

vi sysidcfg
Type:
network_interface=primary {protocol_ipv6=no
netmask=255.255.255.0
default_route=10.1.101.1}
security_policy=none
name_service=none
timezone=Asia/Chongqing
system_locale=zh.GBK
timeserver=10.1.101.1
root_password=NyN4lId2b2SQQ

vi rules
Type:
hostname sun10 - profile10 -
hostname sun99 - profile10 -

vi profile10
Type:
install_type initial_install
system_type standalone
partitioning explicit
filesys c0t0d0s0 2048 /
filesys c0t0d0s1 512 swap
cluster SUNWCXall

cd /export/install/Solaris_9/Misc/JumpStart_sample

cp check /export/config

cd /export/config

./check

vi /etc/ethers
Type:
0:3:ba:e:26:66 sun10
8:0:20:fe:68:57 sun99

vi /etc/hosts
Type:
10.1.101.10 sun10
10.1.101.99 sun99

share -o ro /export/config
share -o ro /export/install

vi /etc/dfs/dfstab
Type:
share -o ro /export/config
share -F nfs -o ro,anon=0 /export/install

shareall

share

cd /cdrom/cdrom0/s0/Solaris_9/Tools/

#cp add_install_client /export/install/

cd /export/install/Solaris_9/Tools

./add_install_client -c 10.1.101.70:/export/config -p 10.1.101.70:/export/config sun10 sun4u
./add_install_client -c 10.1.101.70:/export/config -p 10.1.101.70:/export/config sun99 sun4u

mkdir /tftpboot
bc
obase=16
# 10.1.101.10 0A01650A
# 10.1.101.99 0A016563

#ln -s inetboot.SUN4U.Solaris_9 0A01650A
#ln -s inetboot.SUN4U.Solaris_9 0A016563

===================================================
Boot Client from JumpStart Server

boot net - install

# 選擇是否開放節電?
# 選擇安裝其他語言套件。

===================================================
Wrapper: 重用Custom JumpStart Install

cd /export

#壓縮

tar -cvf sol9install.tar ./install
gzip sol9install.tar

tar -cvf sol9config.tar ./config
gzip sol9config.tar

# 解壓縮
gzip sol9install.tar.gz
tar -xvf sol9install.tar

gzip sol9config.tar.gz
tar -xvf sol9config.tar

# 修改配置

===================================================
參考

pkill -KILL vold

===================================================
Flash Installation

newfs /dev/dsk/c0t0d0s6

mkdir /flash

mount /dev/dsk/c0t0d0s6 /flash/install

# 建立Flash Archive

flarcreate -n flash_root_archive -c -R / -e root_archive -x /flash -x /export/install -x /export/config -a admin_operator /flash/install/flarsol9

mkdir /flash/config

# cp -R /export/config /flash

vi /etc/ethers
Type:
8:0:20:f8:ef:b4 sun80

vi /etc/hosts
Type:
10.1.101.80 sun80

cd /flash/config

vi rules
Type:
hostname sun80 - profile -

vi profile
Type:
install_type flash_install
archive_location nfs 10.1.101.70:/flash/install/flarsol9
partitioning explicit
filesys c0t0d0s0 2048 /
filesys c0t0d0s1 512 swap

vi /etc/dfs/dfstab
Type:
share -o ro /flash/config
share -F nfs -o ro,anon=0 /flash/install

shareall

share

./check

cd /flash/install

# ./add_install_client -p 10.1.101.70:/flash/config -c 10.1.101.70:/flash/config sun80 sun4u

# ./add_install_client -p 10.1.101.70:/flash/config -c 10.1.101.70:/flash/config sun10 sun4u

# Boot Client

boot net - install

===================================================
Volume Management

# 初始卷 d11

/usr/sbin/metainit -f d11 1 1 c0t0d0s0

# SMC

/usr/sbin/metainit d10 -m d11

# Delete d10

/usr/sbin/metainit d10 -m d11

metaroot d10

tail /etc/system

init 6

metattach d10 d12

主/從引導分區
-------------

ls -l /dev/dsk/c0t0d0s3

進PROM:
ok: nvalias backup_root /pci@1f,0/pci@1,1/ide@3/dad@0,0:d

eeprom setenv boot-device disk backup_root net

ok: boot backup_root

===================================================

/usr/sbin/metainit -f d21 1 1 c0t0d0s4

/usr/sbin/metainit -f d22 1 1 c0t0d0s5

# /usr/sbin/metaclear d20

/usr/sbin/metainit d20 -m d21

metattach d20 d22

newfs /dev/md/dsk/d20

vi /etc/vfstab
Type:
/dev/md/dsk/d20 /dev/md/rdsk/d20        /volume       ufs     1       no      -

/usr/sbin/metastat d20

# 卸載

/usr/sbin/metadetach d20 d22

umount /volume

/usr/sbin/metaclear d20

/usr/sbin/metaclear d21

===================================================
RAID 0+1

# submirror 1 (RAID 0)
/usr/sbin/metainit -f d21 1 1 c0t0d0s4
/usr/sbin/metattach d21 c0t0d0s5

# submirror 2 (RAID 0)
/usr/sbin/metainit -f d22 1 1 c0t0d0s6
/usr/sbin/metattach d22 c0t0d0s7

# mirror (RAID 1)
/usr/sbin/metainit d20 -m d21
/usr/sbin/metattach d20 d22

# growfs device

===================================================
RAID 5

/usr/sbin/metainit -f d50 c0t0d0s4 c0t0d0s5 c0t0d0s6 c0t0d0s7

===================================================
Hot Spare

===================================================
X86 Boot 設定引導分區(命令) ??
 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.