After some playing around I've noticed some kinks particularly around
booting.
Some scenarios :
- Poweroff with USB drive connected or removed, Solaris will not boot
unless USB drive is
connected, and in some cases need to be attached to the exact same
USB port when last
attached. Is this a bug ?
- Take USB drive offline via zfs offline, and poweroff, this is much
nastier, as machine would not
boot at all regardless of whether USB drive was connected or not. I
had to boot into LiveCD,
zpool import (whilst USB was attached), and bring USB drive back
online via zfs online pool
disk.
Exact steps on what I did :
http://blogs.sun.com/mattman/entry/bootable_usb_mirror
As I find other caveats I'll add them... But it looks like having the
drive connected at all times is preferable.
cheers
Matt
On 05/ 6/10 12:11 PM, Matt Keenan wrote:
Based on comments, some people say nay, some say yah..... so I decided
to give it a spin, and see
how I get on.
To make my mirror bootable I followed instructions posted here :
http://www.taiter.com/blog/2009/04/opensolaris-200811-adding-disk.html
I plan to do a quick write up myself of my own experience, but so far
everything is working fine.
Mirror size is 200GB (Smallest disk, happens to be laptop disk), once
I attached the USB drive, it
started resilvering straight away, and only took 1hr 45mins to
complete and it resilvered 120G !!
This I was very impressed with.
So far I've not noticed any system performance degradation with the
drive attached. I did a quick test, yanked out the drive, degrades
rpool as expected, but system continues to function fine.
I also did a quick test to see of the USB drive was indeed bootable,
by connecting to another laptop, it booted perfectly.
Connecting the USB drive back to original laptop, the pool comes back
online and resilvers seamlessly.
This is automatic 24/7 backup at it's best...
One thing I did notice, I powered down yesterday whilst USB was
attached, this morning when booting up, I did so without the USB
attached, laptop failed to boot, I had to connect the USB drive and it
booted up fine.
Key would be to degrade the pool before shutdown, e.g. disconnect USB
drive, might try using zpool offline and see how that works.
If I encounter issues, I'll post again.
cheers
Matt
On 05/ 5/10 09:34 PM, Edward Ned Harvey wrote:
From: zfs-discuss-boun...@opensolaris.org [mailto:zfs-discuss-
boun...@opensolaris.org] On Behalf Of Matt Keenan
Just wondering whether mirroring a USB drive with main laptop disk for
backup purposes is recommended or not.
Plan would be to connect the USB drive, once or twice a week, let it
resilver, and then disconnect again. Connecting USB drive 24/7 would
AFAIK have performance issues for the Laptop.
MMmmm... If it works, sounds good. But I don't think it'll work as
expected, for a number of reasons, outlined below.
The suggestion I would have instead, would be to make the external
drive its
own separate zpool, and then you can incrementally "zfs send | zfs
receive"
onto the external.
Here are the obstacles I think you'll have with your proposed solution:
#1 I think all the entire used portion of the filesystem needs to
resilver
every time. I don't think there's any such thing as an incremental
resilver.
#2 How would you plan to disconnect the drive? If you zpool detach
it, I
think it's no longer a mirror, and not mountable. If you simply yank
out
the plug ... although that might work, it would certainly be
nonideal. If
you power off, disconnect, and power on ... Again, it should probably be
fine, but it's not designed to be used that way intentionally, so your
results ... are probably as-yet untested.
I don't want to go on. This list could go on forever. I will strongly
encourage you to simply use "zfs send | zfs receive" because that's a
standard practice thing to do. It is known that the external drive
is not
bootable this way, but that's why you have this article on how to
make it
bootable:
http://docs.sun.com/app/docs/doc/819-5461/ghzur?l=en&a=view
This would have the added benefit of the USB drive being bootable.
By default, AFAIK, that's not correct. When you mirror rpool to another
device, by default the 2nd device is not bootable, because it's just
got an
rpool in there. No boot loader.
Even if you do this mirror idea, which I believe will be slower and less
reliable than "zfs send | zfs receive" you still haven't gained
anything as
compared to the "zfs send | zfs receive" procedure, which is known to
work
reliable with optimal performance.
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss