2

So I am running a fresh copy of Ubuntu Server 16.04 (Did install the Ubuntu-desk on top of it but otherwise stock)

I installed zfsutils-linux then using instructions from the Ubuntu zfs kernel reference site I was able to create a raidz pool. I made some file systems on it and started copying files to it.

Upon reboot the system doesn't recognize the pool at all. A "sudo zpool status" returns nothing.

If I do these two commands after it reboots(storage is the name of the pool):

sudo zpool import storage

sudo zfs mount -a

This will connect the pool and I am fine until next reboot.

When i do a normal reboot the root drive ends up being /dev/sdb

I have tried adding these two commands to the rc.local file but the drive names are out of order. I am assuming due to the fact my main drive is a slower older drive and probably takes time to spin up.

The pool drives are all consumer grade 2 TB drives and the boot disk is a consumer grade 500 gig drive. I use this computer as a test machine and as a backup to my other server. This server has currently 32 gig of ram and is a "9" series supermicro server motherboard with xeon processor so it has more than enough power to run as a home server.

I REALLY want this to work automatically and my other option is to put a delay before the commands but I have to believe it should automatically mount the drive somehow but I have not found how in the documentation or in any searches online.

Thanks for any help!

1

First check to make sure it's really not mounted

sudo zfs get mounted

Then check if the mountpoint is set for the

sudo zfs get mountpoint storage

Then finally set the mountpoint

sudo zfs set mountpoint=/data data

Zfs works a bit differently than all the rest of the filesystems we are used to.

I think I created the pool without having a mountpoint already created with the same name. I'm not sure if that's why it failed to automount.

0

When you create your zpool, use the unique drive ids. You can find these by going to /dev/disk/by-id/. Drive aliases (e.g. /dev/sda, /dev/sdb) can be shuffled/reassigned at boot, causing zfs to be unable to find the zpool.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.