- 论坛徽章:
- 0
|
The following is an example to install our application and informix database on the same 72G disk on Sun V210, then mirror the rootdisk with the second . Also I listed the procedure to create the raw devices for informix data, which has taken me lots of time to mirror it. (although the soft partition and submirror are metadevice , they can't be as a unit the valid unit to setup)
#Partition the rootdisk
Slice mountpoint size start-cyl end-cyl
0 / 5120
1 swap 8193
2 overlap entire-disk
3 258
4 Free
5 /opt 8193
6 /var 9899
7 /app_log 12288
#Set the same Partition layout for the second disk with the first disk
prtvtoc /dev/rdsk/c1t0d0s2 > boot-vtoc.tab
fmthard -s boot-vtoc.tab /dev/rdsk/c1t1d0s2
#Create the metadb on Slice 3
metadb -afc 3 c1t0d0s3
metadb -afc 3 c1t1d0s3
#Create the metadevice for the OS filesystem
metainit -f d1 1 1 c1t0d0s0
metainit d2 1 1 c1t1d0s0
metainit -f d11 1 1 c1t0d0s1
metainit d12 1 1 c1t1d0s1
metainit -f d21 1 1 c1t0d0s5
metainit d22 1 1 c1t1d0s5
metainit -f d31 1 1 c1t0d0s6
metainit d32 1 1 c1t1d0s6
metainit -f d41 1 1 c1t0d0s7
metainit d42 1 1 c1t1d0s7
#Configure the mirror with submirror for OS filesystem
metainit d0 -m d1
metainit d10 -m d11
metainit d20 -m d21
metainit d30 -m d31
metainit d40 -m d41
#Create the RAW devices for the informix data
metainit -f d47 1 1 c1t0d0s4
metainit d48 1 1 c1t1d0s4
metainit d46 -m d47
RAW_DEVS="d61 d64 d71 d74 d81 d84 d91 d94 d101 d104"
for i in $RAW_DEVS; do metainit $i -p d46 4193680b; done
#Create an empty hotspare pool, to suppress warning message at boot.
metainit hsp001
#Configure the metadevice d0 as the boot /
metaroot d0
#Attache the submirror
metattach d0 d2
metattach d10 d12
metattach d20 d22
metattach d30 d32
metattach d40 d42
metattach d46 d48
#Update the /etc/vfstab
cat /etc/vfstab
#device device mount FS fsck mount mount
#to mount to fsck point type pass at boot options
#
fd - /dev/fd fd - no -
/proc - /proc proc - no -
/dev/md/dsk/d10 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no logging
/dev/md/dsk/d30 /dev/md/rdsk/d30 /var ufs 1 no logging
/dev/md/dsk/d40 /dev/md/rdsk/d40 /namp_log ufs 2 yes logging
/dev/md/dsk/d20 /dev/md/rdsk/d20 /opt ufs 2 yes logging
swap - /tmp tmpfs - yes size=2560m
Antje
#reboot the system
init 6
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/832/showart_1686428.html |
|