{"id":747,"date":"2010-01-15T06:00:57","date_gmt":"2010-01-15T11:00:57","guid":{"rendered":"http:\/\/www.gamescheat.ca\/?p=747"},"modified":"2019-09-04T19:57:39","modified_gmt":"2019-09-05T00:57:39","slug":"how-to-create-a-zfs-filesystem-on-two-striped-disk-drives","status":"publish","type":"post","link":"http:\/\/www.gamescheat.ca\/?p=747","title":{"rendered":"How to create a ZFS filesystem on two striped disk drives"},"content":{"rendered":"<p>I ran out of space on my SAN drive on the Solaris 10 SPARC server. Since I had two spare disk drives sitting in the server that were not being used, I decided to create a single striped volume out of the two drives.  The drives contained the factory installed Solaris 10 image.<\/p>\n<p>Here are the step by step instructions on how to create a ZFS pool on the two hard disks, and then create a single ZFS filesystem.<\/p>\n<p>I tried to create the ZFS pool but received the error message that the drive contains ufs filesystems.  This was the factory installed filesystem.<\/p>\n<blockquote><div style=\"float: left;\"><div style=\"margin: 15px 15px 15px 15px\";><script type=\"text\/javascript\"><!--\ngoogle_ad_client = \"pub-3319935785736004\";\ngoogle_alternate_color = \"FFFFFF\";\ngoogle_ad_width = 250;\ngoogle_ad_height = 250;\ngoogle_ad_format = \"250x250_as\";\ngoogle_ad_type = \"text_image\";\ngoogle_ad_channel =\"\";\ngoogle_color_border = \"cccccc\";\ngoogle_color_link = \"cc0000\";\ngoogle_color_bg = \"ffffff\";\ngoogle_color_text = \"000000\";\ngoogle_color_url = \"008000\";\n\/\/--><\/script>\n<script type=\"text\/javascript\"\n  src=\"http:\/\/pagead2.googlesyndication.com\/pagead\/show_ads.js\">\n<\/script><\/div><\/div><p>bash-3.00# zpool create backup c0t0d0<br \/>\ninvalid vdev specification<br \/>\nuse \u2018-f\u2019 to override the following errors:<br \/>\n\/dev\/dsk\/c0t0d0s1 contains a ufs filesystem.<br \/>\n\/dev\/dsk\/c0t0d0s2 contains a ufs filesystem.  <\/p><\/blockquote>\n<p>Use the -f option with the create command to forcefully create the zfs pool.<\/p>\n<blockquote><p>bash-3.00# zpool create -f backup c0t0d0<\/p><\/blockquote>\n<p>Now confirm that the zfs pool was created successfully.<\/p>\n<blockquote><p>bash-3.00# zpool list<br \/>\nNAME     SIZE   USED  AVAIL    CAP  HEALTH  ALTROOT<br \/>\nbackup   136G  76.5K   136G     0%  ONLINE  \u2013<br \/>\nrpool    348G   221G   127G    63%  ONLINE  \u2013<\/p><\/blockquote>\n<p>Add the second disk drive to the zfs pool backup.<\/p>\n<blockquote><p>bash-3.00# zpool add backup c0t1d0<\/p><\/blockquote>\n<p>Confirm that the second disk was added, the size of backup should have doubled.<\/p>\n<blockquote><p>bash-3.00# zpool list<br \/>\nNAME     SIZE   USED  AVAIL    CAP  HEALTH  ALTROOT<br \/>\nbackup   272G  79.5K   272G     0%  ONLINE  \u2013<br \/>\nrpool    348G   221G   127G    63%  ONLINE  \u2013   <\/p><\/blockquote>\n<p>Create a ZFS filesystem called archive with the zfs create command.  It should reside in the backup pool.<\/p>\n<blockquote><p>bash-3.00# zfs create backup\/archive<\/p><\/blockquote>\n<p>Confirm that the new zfs filesystem archive was created.<\/p>\n<blockquote><p>bash-3.00# zfs list<br \/>\nNAME                        USED  AVAIL  REFER  MOUNTPOINT<br \/>\nbackup                      106K   268G    21K  \/backup<br \/>\nbackup\/archive               21K   268G    21K  \/backup\/archive<br \/>\nrpool                       223G   120G    97K  \/rpool<br \/>\nrpool\/ROOT                 4.39G   120G    21K  legacy<br \/>\nrpool\/ROOT\/s10s_u8wos_08a  4.39G   120G  4.39G  \/<br \/>\nrpool\/dump                 1.00G   120G  1.00G  \u2013<br \/>\nrpool\/export                215G   120G   215G  \/export<br \/>\nrpool\/export\/home            21K   120G    21K  \/export\/home<br \/>\nrpool\/swap                    2G   122G    16K  \u2013   <\/p><\/blockquote>\n<p>A ZFS filesystem is automatically mounted after you create it, you can now use the new filesystem archive. If you do not want archive to use all available disk space in the zfs pool backup, then you can define a quota.  If you were to create a second filesystem in the backup pool, then the available disk dynamically shared between the two filesystems unless a quota is defined.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I ran out of space on my SAN drive on the Solaris 10 SPARC server. Since I had two spare disk drives sitting in the server that were not being used, I decided to create a single striped volume out&hellip;<\/p>\n<p class=\"more-link-p\"><a class=\"more-link\" href=\"http:\/\/www.gamescheat.ca\/?p=747\">Read more &rarr;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[19],"tags":[64,67],"_links":{"self":[{"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/posts\/747"}],"collection":[{"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=747"}],"version-history":[{"count":2,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/posts\/747\/revisions"}],"predecessor-version":[{"id":975,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=\/wp\/v2\/posts\/747\/revisions\/975"}],"wp:attachment":[{"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=747"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=747"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.gamescheat.ca\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=747"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}