You are on page 1of 18

1 - change `1' partition

2 - change `2' partition


3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks


0 root wm 395 - 1301 6.95GB (907/0/0) 14570955
1 swap wu 1 - 131 1.00GB (131/0/0) 2104515
2 backup wm 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 279 - 394 909.93MB (116/0/0) 1863540
4 home wm 163 - 278 909.93MB (116/0/0) 1863540
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 146 - 162 133.35MB (17/0/0) 273105
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> ^C
bash-3.00#
bash-3.00#
bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1303 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1303 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): 1
selecting c0t3d0
[disk formatted]

FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
fdisk - run the fdisk program
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
!<cmd> - execute <cmd>, then return
quit
format> p
WARNING - This disk may be in use by an application that has
modified the fdisk table. Ensure that this disk is
not currently in use before proceeding to use fdisk.
format> f
`f' is ambiguous.
format> fdisk
No fdisk table exists. The default partition for the disk is:

a 100% "SOLARIS System" partition

Type "y" to accept the default partition, otherwise type "n" to edit the
partition table.
y
format>
format> p

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks


0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wu 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> ^C
bash-3.00# Current partition table (original):
bash: syntax error near unexpected token `('
bash-3.00# Total disk cylinders available: 1302 + 2 (reserved cylinders)
bash: syntax error near unexpected token `('
bash-3.00#
bash-3.00# Part Tag Flag Cylinders Size Blocks
wu 1 - 131 1.00GB (131/0/0) 2104515
2 backup wm 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 279 - 394 909.93MB (116/0/0) 1863540
4 home wm 163 - 278 909.93MB (116/0/0) 1863540
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 146 - 162 133.35MB (17/0/0) 273105
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition>
bash: Part: command not found
bash-3.00# 0 root wm 395 - 1301 6.95GB (907/0/0) 14570955
bash: syntax error near unexpected token `('
bash-3.00# 1 swap wu 1 - 131 1.00GB (131/0/0) 2104515
bash: syntax error near unexpected token `('
bash-3.00# 2 backup wm 0 - 1301 9.97GB (1302/0/0) 20916630
bash: syntax error near unexpected token `('
bash-3.00# 3 unassigned wm 279 - 394 909.93MB (116/0/0) 1863540
bash: syntax error near unexpected token `('
bash-3.00# 4 home wm 163 - 278 909.93MB (116/0/0) 1863540
bash: syntax error near unexpected token `('
bash-3.00# 5 unassigned wm 0 0 (0/0/0) 0
bash: syntax error near unexpected token `('
bash-3.00# 6 unassigned wm 0 0 (0/0/0) 0
bash: syntax error near unexpected token `('
bash-3.00# 7 unassigned wm 146 - 162 133.35MB (17/0/0) 273105
bash: syntax error near unexpected token `('
bash-3.00# 8 boot wu 0 - 0 7.84MB (1/0/0) 16065
bash: syntax error near unexpected token `('
bash-3.00# 9 unassigned wm 0 0 (0/0/0) 0
bash: syntax error near unexpected token `('
bash-3.00#
bash-3.00# partition>
bash: syntax error near unexpected token `newline'
bash-3.00#
Display all 1450 possibilities? (y or n)
bash-3.00#
bash-3.00#
bash-3.00#
bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1303 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): ^C
bash-3.00# prtvtoc /dev/rdsk/c0t2d0s2 | fmthard -s - /dev/rdsk/c0t3d0s2
fmthard: New volume table of contents now in place.
bash-3.00#
bash-3.00#
bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1303 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): 1
selecting c0t3d0
[disk formatted]

FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
fdisk - run the fdisk program
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
!<cmd> - execute <cmd>, then return
quit
format> p

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)
Part Tag Flag Cylinders Size Blocks
0 root wm 395 - 1301 6.95GB (907/0/0) 14570955
1 swap wu 1 - 131 1.00GB (131/0/0) 2104515
2 backup wm 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 279 - 394 909.93MB (116/0/0) 1863540
4 home wm 163 - 278 909.93MB (116/0/0) 1863540
5 unassigned wu 0 0 (0/0/0) 0
6 unassigned wu 0 0 (0/0/0) 0
7 unassigned wm 146 - 162 133.35MB (17/0/0) 273105
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wu 0 0 (0/0/0) 0

partition> ^C
bash-3.00#
bash-3.00#
bash-3.00# metadb -a -f -c 3 c0t2d0s7 c0t3d0s7
bash-3.00#
bash-3.00#
bash-3.00# metainit -f d10 1 1 c0t2d0s0
d10: Concat/Stripe is setup
bash-3.00# metainit -f d20 1 1 c0t3d0s0
d20: Concat/Stripe is setup
bash-3.00#
bash-3.00# metainit d0 -m d10
d0: Mirror is setup
bash-3.00#
bash-3.00#
bash-3.00# metaroot d0
bash-3.00#
bash-3.00# metainit -f d11 1 1 c0t2d0s1
d11: Concat/Stripe is setup
bash-3.00# metainit -f d21 1 1 c0t3d0s1
d21: Concat/Stripe is setup
bash-3.00#
bash-3.00# metainit d1 -m d11
d1: Mirror is setup
bash-3.00#
bash-3.00# metainit -f d13 1 1 c0t2d0s3
d13: Concat/Stripe is setup
bash-3.00# metainit -f d23 1 1 c0t3d0s3
d23: Concat/Stripe is setup
bash-3.00# metainit d3 -m d13
d3: Mirror is setup
bash-3.00#
bash-3.00# 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/dsk/c0t2d0s1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/dsk/c0t2d0s4 /dev/rdsk/c0t2d0s4 /export/home ufs 2 yes
-
/dev/dsk/c0t2d0s3 /dev/rdsk/c0t2d0s3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
bash-3.00# cd /etc/
bash-3.00#
bash-3.00# ls -ltrh | grep vfstab
-rw-r--r-- 1 root sys 515 Nov 8 18:12 vfstab
bash-3.00# cp vfstab vfstab.081117
bash-3.00# ls -ltrh | grep vfstab
-rw-r--r-- 1 root sys 515 Nov 8 18:12 vfstab
-rw-r--r-- 1 root root 515 Nov 8 18:17 vfstab.081117
bash-3.00# metastat -ac
d3 m 909MB d13
d13 s 909MB c0t2d0s3
d1 m 1.0GB d11
d11 s 1.0GB c0t2d0s1
d0 m 6.9GB d10
d10 s 6.9GB c0t2d0s0
d23 s 909MB c0t3d0s3
d21 s 1.0GB c0t3d0s1
d20 s 6.9GB c0t3d0s0

bash-3.00# metainit -f d14 1 1 c0t2d0s4


d14: Concat/Stripe is setup
bash-3.00# metainit -f d24 1 1 c0t3d0s4
d24: Concat/Stripe is setup
bash-3.00# metainit d4 -m d14
d4: Mirror is setup
bash-3.00#
bash-3.00#
bash-3.00# metastat -ac
d4 m 909MB d14
d14 s 909MB c0t2d0s4
d3 m 909MB d13
d13 s 909MB c0t2d0s3
d1 m 1.0GB d11
d11 s 1.0GB c0t2d0s1
d0 m 6.9GB d10
d10 s 6.9GB c0t2d0s0
d24 s 909MB c0t3d0s4
d23 s 909MB c0t3d0s3
d21 s 1.0GB c0t3d0s1
d20 s 6.9GB c0t3d0s0

bash-3.00# 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/dsk/c0t2d0s1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/dsk/c0t2d0s4 /dev/rdsk/c0t2d0s4 /export/home ufs 2 yes
-
/dev/dsk/c0t2d0s3 /dev/rdsk/c0t2d0s3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
bash-3.00# pwd
/etc
bash-3.00# vi vfstab
"vfstab" 14 lines, 515 characters
#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/d1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/md/dsk/d4 /dev/md/rdsk/d4 /export/home ufs 2 yes -
/dev/md/dsk/d3 /dev/md/rdsk/d3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
"vfstab" 14 lines, 500 characters
bash-3.00#
bash-3.00#
bash-3.00# 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/d1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/md/dsk/d4 /dev/md/rdsk/d4 /export/home ufs 2 yes -
/dev/md/dsk/d3 /dev/md/rdsk/d3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
bash-3.00# lockfs -fa
bash-3.00# sync;sync;sync;init 6
updating /platform/i86pc/boot_archive
bash-3.00#
Connection closed by foreign host.

Disconnected from remote host(192.168.1.19:22) at 18:29:46.

Type `help' to learn how to use Xshell prompt.


[c:\~]$
[c:\~]$
[c:\~]$ ssh root@192.168.1.19

Connecting to 192.168.1.19:22...
Connection established.
To escape to local shell, press 'Ctrl+Alt+]'.

Last login: Wed Nov 8 17:54:31 2017 from 192.168.1.22


Oracle Corporation SunOS 5.10 Generic Patch January 2005
#
#
# bash
bash-3.00# metadb -ac
metadb: option requires an argument -- c
metadb: unknown command
usage: metadb [-s setname] -a [options] mddbnnn
metadb [-s setname] -a [options] device ...
metadb [-s setname] -d [options] mddbnnn
metadb [-s setname] -d [options] device ...
metadb [-s setname] -i
metadb -p [options] [ mddb.cf-file ]
options:
-c count number of replicas (for use with -a only)
-f force adding or deleting of replicas
-k filename alternate /etc/system file
-l length specify size of replica (for use with -a only)
bash-3.00# metastat -ac
d4 m 909MB d14
d14 s 909MB c0t2d0s4
d3 m 909MB d13
d13 s 909MB c0t2d0s3
d1 m 1.0GB d11
d11 s 1.0GB c0t2d0s1
d0 m 6.9GB d10
d10 s 6.9GB c0t2d0s0
d24 s 909MB c0t3d0s4
d23 s 909MB c0t3d0s3
d21 s 1.0GB c0t3d0s1
d20 s 6.9GB c0t3d0s0

bash-3.00# metattach d0 d20


d0: submirror d20 is attached
bash-3.00# metastat -ac
d4 m 909MB d14
d14 s 909MB c0t2d0s4
d3 m 909MB d13
d13 s 909MB c0t2d0s3
d1 m 1.0GB d11
d11 s 1.0GB c0t2d0s1
d0 m 6.9GB d10 d20 (resync-0%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0
d24 s 909MB c0t3d0s4
d23 s 909MB c0t3d0s3
d21 s 1.0GB c0t3d0s1

bash-3.00# metattach d1 d21


d1: submirror d21 is attached
bash-3.00# metattach d3 d23
d3: submirror d23 is attached
bash-3.00# metattach d4 d24
d4: submirror d24 is attached
bash-3.00# metastat -ac
d4 m 909MB d14 d24 (resync-1%)
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23 (resync-16%)
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21 (resync-61%)
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-12%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00#
bash-3.00#
bash-3.00#
bash-3.00#
bash-3.00# df -kh
Filesystem size used avail capacity Mounted on
/dev/md/dsk/d0 6.8G 3.4G 3.4G 51% /
/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.5G 996K 1.5G 1% /etc/svc/volatile
objfs 0K 0K 0K 0% /system/object
sharefs 0K 0K 0K 0% /etc/dfs/sharetab
/usr/lib/libc/libc_hwcap1.so.1
6.8G 3.4G 3.4G 51% /lib/libc.so.1
fd 0K 0K 0K 0% /dev/fd
swap 1.5G 40K 1.5G 1% /tmp
swap 1.5G 28K 1.5G 1% /var/run
/dev/md/dsk/d3 855M 1.1M 794M 1% /opt
/dev/md/dsk/d4 855M 1.0M 794M 1% /export/home
bash-3.00# metastat -ac
d4 m 909MB d14 d24 (resync-58%)
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23 (resync-75%)
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-14%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0
bash-3.00# metastat -ac
d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-18%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-29%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-30%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-31%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-37%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-55%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20 (resync-55%)
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# metastat -ac


d4 m 909MB d14 d24
d14 s 909MB c0t2d0s4
d24 s 909MB c0t3d0s4
d3 m 909MB d13 d23
d13 s 909MB c0t2d0s3
d23 s 909MB c0t3d0s3
d1 m 1.0GB d11 d21
d11 s 1.0GB c0t2d0s1
d21 s 1.0GB c0t3d0s1
d0 m 6.9GB d10 d20
d10 s 6.9GB c0t2d0s0
d20 s 6.9GB c0t3d0s0

bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1303 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): 2
selecting c0t4d0
[disk formatted]

FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
fdisk - run the fdisk program
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
!<cmd> - execute <cmd>, then return
quit
format> fdisk
No fdisk table exists. The default partition for the disk is:

a 100% "SOLARIS System" partition

Type "y" to accept the default partition, otherwise type "n" to edit the
partition table.
y
format> p

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)
Part Tag Flag Cylinders Size Blocks
0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wu 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> ^C
bash-3.00#
bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): 2
selecting c0t4d0
[disk formatted]

FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
fdisk - run the fdisk program
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
!<cmd> - execute <cmd>, then return
quit
format> p

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks


0 unassigned wm 0 0 (0/0/0) 0
1 unassigned wm 0 0 (0/0/0) 0
2 backup wu 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> 0
Part Tag Flag Cylinders Size Blocks
0 unassigned wm 0 0 (0/0/0) 0

Enter partition id tag[unassigned]:


Enter partition permission flags[wm]:
Enter new starting cyl[0]: 1
Enter partition size[0b, 0c, 1e, 0.00mb, 0.00gb]: 9.9gb
partition> p
Current partition table (unnamed):
Total disk cylinders available: 1302 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks


0 unassigned wm 1 - 1293 9.90GB (1293/0/0) 20772045
1 unassigned wm 0 0 (0/0/0) 0
2 backup wu 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> label
Ready to label disk, continue? yes

partition> ^C
bash-3.00# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c0t2d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@2,0
1. c0t3d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@3,0
2. c0t4d0 <DEFAULT cyl 1302 alt 2 hd 255 sec 63>
/pci@0,0/pci8086,2829@d/disk@4,0
Specify disk (enter its number): 2
selecting c0t4d0
[disk formatted]

FORMAT MENU:
disk - select a disk
type - select (define) a disk type
partition - select (define) a partition table
current - describe the current disk
format - format and analyze the disk
fdisk - run the fdisk program
repair - repair a defective sector
label - write label to the disk
analyze - surface analysis
defect - defect list management
backup - search for backup labels
verify - read and display labels
save - save new disk/partition definitions
inquiry - show vendor, product and revision
volname - set 8-character volume name
!<cmd> - execute <cmd>, then return
quit
format> p

PARTITION MENU:
0 - change `0' partition
1 - change `1' partition
2 - change `2' partition
3 - change `3' partition
4 - change `4' partition
5 - change `5' partition
6 - change `6' partition
7 - change `7' partition
select - select a predefined table
modify - modify a predefined partition table
name - name the current table
print - display the current table
label - write partition map and label to the disk
!<cmd> - execute <cmd>, then return
quit
partition> p
Current partition table (original):
Total disk cylinders available: 1302 + 2 (reserved cylinders)

Part Tag Flag Cylinders Size Blocks


0 unassigned wm 1 - 1293 9.90GB (1293/0/0) 20772045
1 unassigned wm 0 0 (0/0/0) 0
2 backup wu 0 - 1301 9.97GB (1302/0/0) 20916630
3 unassigned wm 0 0 (0/0/0) 0
4 unassigned wm 0 0 (0/0/0) 0
5 unassigned wm 0 0 (0/0/0) 0
6 unassigned wm 0 0 (0/0/0) 0
7 unassigned wm 0 0 (0/0/0) 0
8 boot wu 0 - 0 7.84MB (1/0/0) 16065
9 unassigned wm 0 0 (0/0/0) 0

partition> ^C
bash-3.00#
bash-3.00#
bash-3.00# mdf -kh
bash: mdf: command not found
bash-3.00# df -kh
Filesystem size used avail capacity Mounted on
/dev/md/dsk/d0 6.8G 3.4G 3.4G 51% /
/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.5G 996K 1.5G 1% /etc/svc/volatile
objfs 0K 0K 0K 0% /system/object
sharefs 0K 0K 0K 0% /etc/dfs/sharetab
/usr/lib/libc/libc_hwcap1.so.1
6.8G 3.4G 3.4G 51% /lib/libc.so.1
fd 0K 0K 0K 0% /dev/fd
swap 1.5G 40K 1.5G 1% /tmp
swap 1.5G 28K 1.5G 1% /var/run
/dev/md/dsk/d3 855M 1.1M 794M 1% /opt
/dev/md/dsk/d4 855M 1.0M 794M 1% /export/home
bash-3.00# pwd
/
bash-3.00# mkdir data
bash-3.00#
bash-3.00# df -kh
Filesystem size used avail capacity Mounted on
/dev/md/dsk/d0 6.8G 3.4G 3.4G 51% /
/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.5G 996K 1.5G 1% /etc/svc/volatile
objfs 0K 0K 0K 0% /system/object
sharefs 0K 0K 0K 0% /etc/dfs/sharetab
/usr/lib/libc/libc_hwcap1.so.1
6.8G 3.4G 3.4G 51% /lib/libc.so.1
fd 0K 0K 0K 0% /dev/fd
swap 1.5G 40K 1.5G 1% /tmp
swap 1.5G 28K 1.5G 1% /var/run
/dev/md/dsk/d3 855M 1.1M 794M 1% /opt
/dev/md/dsk/d4 855M 1.0M 794M 1% /export/home
bash-3.00# ls -ltrh
total 343
drwx------ 2 root root 8.0K Nov 8 12:53 lost+found
drwxr-xr-x 3 root sys 512 Nov 8 12:53 export
lrwxrwxrwx 1 root root 9 Nov 8 12:54 bin -> ./usr/bin
drwxr-xr-x 2 root sys 512 Nov 8 12:54 mnt
drwxr-xr-x 4 root root 512 Nov 8 12:54 system
drwxr-xr-x 2 root sys 1.0K Nov 8 13:59 sbin
drwxr-xr-x 18 root sys 512 Nov 8 14:19 kernel
drwxr-xr-x 5 root sys 512 Nov 8 14:25 platform
drwxr-xr-x 5 root sys 512 Nov 8 14:25 opt
drwxr-xr-x 8 root bin 5.5K Nov 8 14:30 lib
drwxr-xr-x 40 root sys 1.0K Nov 8 14:35 usr
drwxr-xr-x 8 root sys 512 Nov 8 14:47 boot
drwxr-xr-x 46 root sys 1.0K Nov 8 17:51 var
drwxr-xr-x 2 root root 512 Nov 8 17:51 Documents
drwxr-xr-x 2 root root 512 Nov 8 17:51 Desktop
drwxr-xr-x 2 root sys 512 Nov 8 18:30 devices
dr-xr-xr-x 1 root root 1 Nov 8 18:31 net
dr-xr-xr-x 1 root root 1 Nov 8 18:31 home
drwxr-xr-x 87 root sys 4.5K Nov 8 18:31 etc
dr-xr-xr-x 6 root root 512 Nov 8 18:31 vol
drwxrwxrwt 6 root sys 340 Nov 8 18:32 tmp
drwxr-xr-x 17 root sys 4.5K Nov 8 18:53 dev
drwxr-xr-x 2 root root 512 Nov 8 18:55 data
dr-xr-xr-x 55 root root 127K Nov 8 18:55 proc
bash-3.00# mount /dev/dsk/cot4d0s0 /data
mount: /dev/dsk/cot4d0s0 or /data, no such file or directory
bash-3.00# mount /dev/dsk/c0t4d0s0 /data
mount: /dev/dsk/c0t4d0s0 is not this fstype
bash-3.00# newfs /dev/dsk/c0t4d0s0
newfs: construct a new file system /dev/rdsk/c0t4d0s0: (y/n)? y
Warning: 820 sector(s) in last cylinder unallocated
/dev/rdsk/c0t4d0s0: 20772044 sectors in 3381 cylinders of 48 tracks, 128
sectors
10142.6MB in 212 cyl groups (16 c/g, 48.00MB/g, 5824 i/g)
super-block backups (for fsck -F ufs -o b=#) at:
32, 98464, 196896, 295328, 393760, 492192, 590624, 689056, 787488, 885920,

19858720, 19957152, 20055584, 20154016, 20252448, 20350880, 20449312,


20547744, 20646176, 20744608
bash-3.00#
bash-3.00#
bash-3.00# mount /dev/dsk/c0t4d0s0 /data
bash-3.00# cat vfstab
cat: cannot open vfstab
bash-3.00# 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/d1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/md/dsk/d4 /dev/md/rdsk/d4 /export/home ufs 2 yes -
/dev/md/dsk/d3 /dev/md/rdsk/d3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
bash-3.00# 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/d1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/md/dsk/d4 /dev/md/rdsk/d4 /export/home ufs 2 yes -
/dev/md/dsk/d3 /dev/md/rdsk/d3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
bash-3.00#
bash-3.00# pwd
/
bash-3.00# vi /etc/vfstab
"/etc/vfstab" 14 lines, 500 characters
#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/d1 - - swap - no -
/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -
/dev/md/dsk/d4 /dev/md/rdsk/d4 /export/home ufs 2 yes -
/dev/md/dsk/d3 /dev/md/rdsk/d3 /opt ufs 2 yes -
/devices - /devices devfs - no -
sharefs - /etc/dfs/sharetab sharefs - no -
ctfs - /system/contract ctfs - no -
objfs - /system/object objfs - no -
swap - /tmp tmpfs - yes -
/dev/dsk/c0t4d0s0 /dev/rdsk/c0t4d0s0 /data ufs 2 yes -
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
"/etc/vfstab" 15 lines, 573 characters
bash-3.00#
bash-3.00#
bash-3.00#
bash-3.00# init 6
bash-3.00#
bash-3.00#
bash-3.00#