Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Upgrade disk in FreeNAS 2TB -> 4TB

Posted on 2013-11-26
9
Medium Priority
?
4,066 Views
Last Modified: 2013-12-23
I have a small server running FreeNAS which is being used to store backups.

The FreeNAS server has a ZFS volume which is stored on a single 2TB disk.

I just bought a new 4TB disk that I want to upgrade to. How do I do that?

Can I power off the server, remove the 2TB disk and image it over to the 4TB using something like dd? Will FreeNAS recognize it when I plug it back in?

Or is there some supported way directly in FreeNAS to do this?
0
Comment
Question by:Frosty555
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 
LVL 19

Accepted Solution

by:
xterm earned 2000 total points
ID: 39679865
I would do the following:

- Yes, take the drive out, put both in an unused system, get any Linux/BSD boot disk, and then use dd to image the 2TB disk over to the 4TB disk.
- Now you will have a 4TB disk, but it will only look like 2TB because it's an exact image of previous disk.  My suggestion is to use gpart to expand the ZFS volume (see http://freebsd.so14k.com/grow_zfs_partiton_on_hardware_raid.shtml)
- Then according to the FreeNAS documentation, you should simply be able to import this as a new volume when you put the 4TB disk back in (see http://doc.freenas.org/index.php/Volumes)
0
 
LVL 56

Expert Comment

by:andyalder
ID: 39681185
Are you booting freenas from this disk or from USB stick?
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 39684217
Single disk configuration?

DD'ing a 2TB might take very long time. The best way is to import the external disk, copy the data then migrate the mount points. Then remove the old disk. This is assuming you have an extra slot, if it doesn't then you would have to follow xterm's method.
0
Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

 
LVL 31

Author Comment

by:Frosty555
ID: 39713038
I'm imaging it over now. Hopefully I should have some results for you by the end of the night whether it worked or not, and if not, we can figure out what to do next
0
 
LVL 19

Expert Comment

by:xterm
ID: 39713048
Good luck!  Let us know....
0
 
LVL 31

Author Comment

by:Frosty555
ID: 39729442
(FYI - it was actually a 3TB disk I am upgradingto a 4TB disk, my mistake)

Also I followed some instructions here:
https://bugs.freenas.org/issues/342

Well, I followed the instructions here and the instructions posted by xterm, and I did successfully image the disk over from the 3TB disk over to the new 4TB disk. I had to do a "gpart recover ada0" to recover the "corrupted" partition after DDing it over to the 4TB disk, and then I had to do a "zpool export" and "zpool grow" to make the zpool consume the free space.

Everything seems to have gone well, but I still don't see 4TB when I actually look at it in FreeNAS.

Here's the results if I examine the disks on the system now:

[root@esmerelda] ~# gpart show ada0
=>        34  7814037101  ada0  GPT  (3.7T)
          34          94        - free -  (47k)
         128     4194304     1  freebsd-swap  (2.0G)
     4194432  7809842696     2  freebsd-zfs  (3.7T)
  7814037128           7        - free -  (3.5k)

[root@esmerelda] ~# zpool list
NAME              SIZE  ALLOC   FREE    CAP  DEDUP  HEALTH  ALTROOT
MAINPOOL_BACKUP  1.81T   941G   915G    50%  1.00x  ONLINE  /mnt
OTHER_BACKUPS    2.72T  2.26T   470G    83%  1.00x  ONLINE  /mnt

Open in new window


The "OTHER_BACKUPS" zpool is the one that is associated with my 4TB drive.

In FreeNAS this is what I see:
The "OTHER_BACKUPS" zpool which is assigned to the 4TB disk
Now, these are nested zfs datasets, so that might be part of the reason why I'm not seeing the full 4TB... but I'm stumped now, I don't know what to do to "grow" the zfs dataset, or to add a new one to claim the unused space.

Any ideas what to do next?
0
 
LVL 19

Expert Comment

by:xterm
ID: 39729479
I guess first things first, if you add a new dataset, does it show the correct amount of free space available?  This way we can at least guarantee that the new space is accessible to FreeNAS.
0
 
LVL 31

Author Comment

by:Frosty555
ID: 39735091
Huh... nevermind it actually is working now. All of my datasets grew by about 500GB.

I turned off all of the quotas and reservation settings for all of the datasets, and now it looks like this:

datasets
So I think this is fully representing all 4TB now. TBH I don't know what changed between now and the picture I posted earlier, except maybe rebooting the server.
0
 
LVL 19

Expert Comment

by:xterm
ID: 39735579
awesome!  Glad to hear it :)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Is your phone running out of space to hold pictures?  This article will show you quick tips on how to solve this problem.
A look at what happened in the Verizon cloud breach.
This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question