I'd like to use an OpenSolaris EC2 instance as a DB server, using an external EBS volume connected to a ZFS pool.
If I set-up the ZFS pools then bundle-up the EC2 image, could I terminate the instance then safely re-attach the existing EBS volume (with data) to a new EC2 instance after it boots?
My main concern is if the instance terminates unexpectedly. I would ideally like to bring up a new instance and automate the re-attachment of the EBS volume but I'm not sure whether I could store the AMI with the pool structure already set, or whether I'd have to issue some commands at start-up to build the pool structure after attaching the volume.
-
I haven’t used ZFS on EBS, so I don’t know if there are specific wrinkles related to that (there shouldn’t be).
When moving ZFS pools between “machines” (real or virtualised), you’re supposed to
export
the pool beforeimport
ing into the other. It’s not strictly necessary, but it makes things happen more smoothly.This article on migrating ZFS storage pools may give you the heads-up you need.
Phillip Oldham : Any idea how this works with separate cache and intent-log devices?Mo : I’m guessing your plan is to not move the cache and log devices alongside the pool itself? If so, (caveat: I have no personal experience of doing this), I’d err on the side of caution and remove them prior to export and re-add as necessary after import on the other machine. I could very well be wrong, but I suspect ZFS will discover the cache and intent log devices are absent and trip a (non-fatal) error condition. If you are going to move all of the devices together, then just an `export` and `import` should theoretically just work. If not, then you’ll have to remove and re-add them.From Mo
0 comments:
Post a Comment