I'm a newbie that has mhvtl setup to emulate an HP changer with ultrium drive per a number of examples. Nothing special going on with the config. The box is an old tower with a SATA hot swap tray. The bios supports hot swap. I'm using tgt to export the emulated tape changer. To get things working, I mount the hotswap disk to /opt. Hosts see it and everything works great.
I have two further goals:
1. Rotate the hotswap disk, taking them offsite for backup/DR.
1a. Furthermore, each disk should have a unique set of simulated tape.
I poked around at the file structure and moved the hotswap disk to another mount point, /mnt/tape. Then I made symbolic links from /opt/mhvtl/90/tapexxxyyzzzz The daemon runs fine like this, but, please let me know if that's not a good way to solve the problem.
The question of how to replace the hotswap drives and populate each drive with its own set of virtual tapes is still open.
Why are you trying this ?
Surely the backup application can handle disk better than using software (mhVTL) to convert perfectly good disk (random access) into sequential access..
Now that is out of the way, onto ideas / hacks to get this to work :)
If you linked /etc/mhvtl/library_contents.xx -> /mnt/tape/library_contents.xx
When you swap your disk /mnt/tape, you "pkill -HUP vtllibrary" which will re-read the library_contents.xx
I would strongly recommend keeping the number of drives the same across each instance - but you can change the number of storage slots, mail slots (if you like).
As long as no tapes are mounted at the time of the disk swap - all will be good..
To be sure, before you swap out the disk run the following checks
- mtx -f /dev/sgXX status | grep "Data Transfer Element" | grep -v Empty | wc -l
(Should return 0)
Take the library in an offline state (which will prevent anything from moving media into a drive)
- vtlcmd <index> offline
- vtlcmd <index> online
- pkill -HUP vtllibrary
Re-inventory the robot using your application software..
Please post your experience - good or bad and any ideas you think may help.