Jump to content
Sign in to follow this  

Raid 1 Root Filesystem On X86/x64

Recommended Posts

raid 1 ni guna solaris volume manager atau di kenali dgn nama disksuite. buat masa tgh2 bosan di ofis , guna virtualbox. ada 2 disk dalam system ni ada 2 disk, c0d0 dgn c0d1.

1 - create slice c0d1s0
# format /dev/rdsk/c0d1

2 - create metadb in slice 7
# metadb -a -f -c 3 /dev/dsk/c0d0s7 /dev/dsk/c0d1s7

3 - Create metadevices for mirroring

# metainit -f d30 1 1 c0d0s0
# metainit d20 1 1 c0d1s0

4 - Create (one-way) mirrored device

# metainit d50 -m d30

5 - Change /etc/vfstab and /etc/system by executing metaroot command

# metaroot d50

6 - reboot the system

# init 6

7 - Attach d20 to mirror

# metattach d50 d20

8 - configure grub commented findroot (rootfs0,0,a)

#---------- ADDED BY BOOTADM - DO NOT EDIT ----------
title Solaris 10 5/09 s10x_u7wos_08 X86
#findroot (rootfs0,0,a)
kernel /platform/i86pc/multiboot
module /platform/i86pc/boot_archive
#---------------------END BOOTADM--------------------
#---------- ADDED BY BOOTADM - DO NOT EDIT ----------
title Solaris failsafe
findroot (rootfs0,0,a)
kernel /boot/multiboot kernel/unix -s
module /boot/x86.miniroot-safe
#---------------------END BOOTADM--------------------

9 - configure MBR on second disk

# installgrub \
> /boot/grub/stage1 \
> /boot/grub/stage2 \
> /dev/rdsk/c0d1s0

10 - reboot

## uname -a;uptime;metastat -a
SunOS unknown 5.10 Generic_139556-08 i86pc i386 i86pc
4:11pm up 13 min(s), 1 user, load average: 0.04, 1.54, 2.79
d50: Mirror
Submirror 0: d30
State: Okay
Submirror 1: d20
State: Resyncing
Resync in progress: 0 % done
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 14626816 blocks (7.0 GB)

d30: Submirror of d50
State: Okay
Size: 14626816 blocks (7.0 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c0d0s0 0 No Okay Yes

d20: Submirror of d50
State: Resyncing
Size: 18763920 blocks (8.9 GB)
Stripe 0:
Device Start Block Dbase State Reloc Hot Spare
c0d1s0 0 No Okay Yes

Device Relocation Information:
Device Reloc Device ID
c0d1 Yes id1,cmdk@AVBOX_HARDDISK=VBd799ae29-da999860
c0d0 Yes id1,cmdk@AVBOX_HARDDISK=VBe478ec6a-851e59c1

# df -h
Filesystem size used avail capacity Mounted on
/dev/md/dsk/d50 6.9G 3.3G 3.5G 49% /
/devices 0K 0K 0K 0% /devices
ctfs 0K 0K 0K 0% /system/contract
proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
swap 1.3G 912K 1.3G 1% /etc/svc/volatile
objfs 0K 0K 0K 0% /system/object
sharefs 0K 0K 0K 0% /etc/dfs/sharetab
fd 0K 0K 0K 0% /dev/fd
swap 1.3G 36K 1.3G 1% /tmp
swap 1.3G 20K 1.3G 1% /var/run

p/s: selamat pengantin baru abang fryshadow.

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...