Sie sind auf Seite 1von 4

# echo | format

Searching for disks...done


AVAILABLE DISK SELECTIONS:
0. c1t0d0
/pci@0,0/pci15ad,1976@10/sd@0,0
1. c1t1d0 <VMware,-VMware Virtual S-1.0-1.00GB>
/pci@0,0/pci15ad,1976@10/sd@1,0
2. c1t2d0
/pci@0,0/pci15ad,1976@10/sd@2,0
3. c1t3d0
/pci@0,0/pci15ad,1976@10/sd@3,0
4. c1t4d0
/pci@0,0/pci15ad,1976@10/sd@4,0
Specify disk (enter its number): Specify disk (enter its number):

# zpool create geekpool c1t1d0


# zpool list
NAME SIZE ALLOC FREE CAP HEALTH ALTROOT
geekpool 1008M 78.5K 1008M 0% ONLINE -

Creating a ZFS file system


The best part about zfs is that oracle(or should I say Sun) has kept the commands for it
pretty easy to understand and remember. To create a file system fs1 in an existing zfs
pool geekpool:
# zfs create geekpool/fs1
# zfs list
NAME USED AVAIL REFER MOUNTPOINT
geekpool 131K 976M 31K /geekpool
geekpool/fs1 31K 976M 31K /geekpool/fs1

To set mount point for the file system


By default a mount point (/poolname/fs_name) will be created for the file system if you
don’t specify. In our case it was /geekpool/fs1. Also you do not have to have an entry of
the mount point in /etc/vfstab as it is stored internally in the metadata of zfs pool and
mounted automatically when system boots up. If you want to change the mount point :
# zfs set mountpoint=/test geekpool/fs1
# df -h |grep /test
geekpool/fs1 500M 31K 500M 1% /test

http://thegeekdiary.com/zfs-tutorials-creating-zfs-pools-and-file-systems/
…………………………………………………………………………………………………………………………………………………………………

root@solaris:~# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:


0. c3t0d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
/pci@0/pci@0/pci@2/scsi@0/sd@0,0
1. c3t1d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
/pci@0/pci@0/pci@2/scsi@0/sd@1,0
2. c4t500A09828DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09828de3e799,0
3. c4t500A09828DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09828de3e799,1
4. c4t500A09829DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09829de3e799,0
5. c4t500A09829DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09829de3e799,1
6. c5t500A09818DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09818de3e799,0
7. c5t500A09818DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09818de3e799,1
8. c5t500A09819DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09819de3e799,0
9. c5t500A09819DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09819de3e799,1
Specify disk (enter its number): ^D
root@solaris:~#

root@solaris:~# format
Searching for disks...done

c4t500A09828DE3E799d2: configured with capacity of 499.92GB


c4t500A09829DE3E799d2: configured with capacity of 499.92GB
c5t500A09818DE3E799d2: configured with capacity of 499.92GB
c5t500A09819DE3E799d2: configured with capacity of 499.92GB

AVAILABLE DISK SELECTIONS:


0. c3t0d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
/pci@0/pci@0/pci@2/scsi@0/sd@0,0
1. c3t1d0 <SUN146G cyl 14087 alt 2 hd 24 sec 848>
/pci@0/pci@0/pci@2/scsi@0/sd@1,0
2. c4t500A09828DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09828de3e799,0
3. c4t500A09828DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09828de3e799,1
4. c4t500A09828DE3E799d2 <NETAPP-LUN-8030 cyl 6480 alt 2 hd 16 sec 10112>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09828de3e799,2
5. c4t500A09829DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09829de3e799,0
6. c4t500A09829DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09829de3e799,1

http://thegeekdiary.com/zfs-tutorials-creating-zfs-pools-and-file-systems/
7. c4t500A09829DE3E799d2 <NETAPP-LUN-8030 cyl 6480 alt 2 hd 16 sec 10112>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0/fp@0,0/ssd@w500a09829de3e799,2
8. c5t500A09818DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09818de3e799,0
9. c5t500A09818DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09818de3e799,1
10. c5t500A09818DE3E799d2 <NETAPP-LUN-8030 cyl 6480 alt 2 hd 16 sec 10112>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09818de3e799,2
11. c5t500A09819DE3E799d0 <NETAPP-LUN-8030-500.08GB>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09819de3e799,0
12. c5t500A09819DE3E799d1 <NETAPP-LUN-8030 cyl 6535 alt 2 hd 16 sec 12032>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09819de3e799,1
13. c5t500A09819DE3E799d2 <NETAPP-LUN-8030 cyl 6480 alt 2 hd 16 sec 10112>
/pci@0/pci@0/pci@8/pci@0/pci@9/SUNW,emlxs@0,1/fp@0,0/ssd@w500a09819de3e799,2
Specify disk (enter its number):

Specify disk (enter its number): ^D


root@solaris:~# zpool create oracle c4t500A09828DE3E799d2
root@solaris:~# zpool list
NAME SIZE ALLOC FREE CAP DEDUP HEALTH ALTROOT
oracle 500G 112K 500G 0% 1.00x ONLINE -
oradata 500G 473G 27.4G 94% 1.00x DEGRADED -
oradata1 596G 517G 78.8G 86% 1.00x ONLINE -
rpool 136G 132G 4.10G 96% 1.00x ONLINE -
root@solaris:~# zfs create oracle/oradata2
root@solaris:~# zfs list
NAME USED AVAIL REFER MOUNTPOINT
oracle 124K 492G 32K /oracle
oracle/oradata2 31K 492G 31K /oracle/oradata2
oradata 473G 19.6G 473G /oradata
oradata1 517G 69.5G 517G /oradata1
rpool 132G 1.47G 73.5K /rpool
rpool/ROOT 105G 1.47G 31K legacy
rpool/ROOT/solaris 105G 1.47G 104G /
rpool/ROOT/solaris/var 660M 1.47G 498M /var
rpool/dump 8.19G 1.72G 7.94G -
rpool/export 11.3G 1.47G 33.5K /export
rpool/export/home 11.3G 1.47G 34K /export/home
rpool/export/home/cmovel 4.66G 1.47G 4.66G /export/home/cmovel
rpool/export/home/oracle 6.66G 1.47G 6.66G /export/home/oracle
rpool/swap 2.06G 1.53G 2.00G -
rpool/swap2 6.19G 1.66G 6.00G -
root@solaris:~# zfs set mountpoint=/oradata2 oracle/oradata2
root@solaris:~#
df -h
Filesystem Size Used Available Capacity Mounted on
rpool/ROOT/solaris 134G 104G 1.5G 99% /
/devices 0K 0K 0K 0% /devices
/dev 0K 0K 0K 0% /dev
ctfs 0K 0K 0K 0% /system/contract
proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
swap 289M 2.2M 286M 1% /system/volatile
objfs 0K 0K 0K 0% /system/object
sharefs 0K 0K 0K 0% /etc/dfs/sharetab
fd 0K 0K 0K 0% /dev/fd
rpool/ROOT/solaris/var

http://thegeekdiary.com/zfs-tutorials-creating-zfs-pools-and-file-systems/
134G 498M 1.5G 25% /var
swap 286M 0K 286M 0% /tmp
rpool/export 134G 33K 1.5G 1% /export
rpool/export/home 134G 34K 1.5G 1% /export/home
rpool/export/home/cmovel
134G 4.7G 1.5G 77% /export/home/cmovel
rpool/export/home/oracle
134G 6.7G 1.5G 82% /export/home/oracle
oradata 492G 473G 20G 97% /oradata
oradata1 587G 517G 69G 89% /oradata1
rpool 134G 73K 1.5G 1% /rpool
/export/home/cmovel 6.1G 4.7G 1.5G 77% /home/cmovel
oracle 492G 32K 492G 1% /oracle
oracle/oradata2 492G 31K 492G 1% /oradata2
root@solaris:~#

http://thegeekdiary.com/zfs-tutorials-creating-zfs-pools-and-file-systems/

Das könnte Ihnen auch gefallen