Hey Guys,
Sorry its been a while. Today I'll talk about the benefits of LUN cloning, an interesting feature that's included in with Netapp ONtap version 7 or later.
I first used lun clone when I wanted to create multiple iSCSI LUNs that contained the same original data. We had a requirement to create 16 training servers that would be contain the exact same starting data, but be independant so that the data entered during training wouldn't spread to the other servers.
So how we did this is we created the pristine image, and then duplicated it 15 times. For the C: drive, I basically just did a copy of the vmdk file 15 times. The data drive I was lucky enough to setup an iSCSI LUN on the Netapp and use the software based initiator in the guest OS (it was ESX 2.5 at the time).
What I could do to duplicate the drive is create 15 copies of the iSCSI LUN using NDMPCOPY but then I would be consuming a great deal of space. Instead, I used lun clone to clone the iSCSI LUN 15 times. And the cool thing is that the lun clone does not use any additional space from the original lun. So say my iSCSI LUN was originally 10GB, I lun clone 15 times, and the space used is only 10GB, because there has been no changes to the files. The only time you use space is when there are block level changes to the cloned luns.
Taking this one step further, when I setup each server by changing IP, computer name, iSCSI initiator name, and a couple of other things, I took a snapshot and every week I roll back to day 0 so that the trainers don't have any old day at the start of the week.
So we were really happy with this, it worked out well and didn't take up a lot of storage because of the lun clone feature. So how else can you use this technology.
Say you have data on a LUN and part of it gets corrupted for whatever reason, OS issue, you name it. You don't want to do a snap restore or maybe you don't have snap restore. Doing a snap restore would revert the entire volume. So, a great way is to do a lun clone from a snapshot. You can now present the lun clone as a secondary drive to the server and drag and drop the files that you need to recover.
Command structure is similar to the following:
lun clone create /vol/serverdatavol/backuplun -o noreserve -b /vol/serverdatavol/currentlun hourly.3
So details from the above would be lun clone create is the first part required, /vol/serverdatavol/backuplun would be name/location of the lun to be created from the clone. -o noreserve is required because you don't want to consume any space. -b says that you are cloning from a snapshot and /vol/serverdatavol/currentlun indicates the current active lun. hourly.3 tells the filer what snapshot to create the clone from.
A couple of key things here, make sure that if you are using Windows, you are using W2k3, it does drive resignaturing automatically because the new drive that is presented will have the exact same drive "serial number" and the OS won't use it unless it gets resignatured. Also, ESX 3 will do lun resignaturing for you if you tell it to do that, do a search in the VMware forums for lun resignature and you'll find the exact syntax on how to permit that.
Also, even though you won't consume storage by doing this, the volume wants to be able to handle the additional size requirements of the LUN. So I've had to increase the size of the volume substantially to accomodate it, even though it doesn't use the space.
If this sounds similar to flex clones, it is, but flex clones deals with cloning volumes, not luns, and flex clone is a separate license, so of course, extra money.
Hope this helps you guys out in the future.
Cheers,
Chris