Iscsi,Storage and ESXi – Part 2

Forgetting about Iscsi, I went to try to enable RSYNC  to /from ESXi.
I enabled password-free SSH on the ESXi server and downloaded the self-contained rsync executable from http://computerpr0n.com/2011/04/esxi-remote-management-part-2/. I then created merged 2 rsync scripts, the one from the blog above and the one from http://troy.jdmz.net/rsync/index.html, in order to create one that runs without password-prompt to synchronize a local ISOs directory on a Ubuntu machine and the ISOs datastore on ESXi. It works perfect and allows me to have the files I need on ESXi for my VMs as well as a local backup. The final result looks something like this:

rsync -avr –delete -e “ssh -i /esxi-key/esxi” –rsync-path=/vmfs/volumes/datastore1/Others/rsync /my/local/datastore/ISOs/ user@ESXiServer:/vmfs/volumes/datastore1/ISOs/

WHERE

esxi-key/esxi is the path where the SSH keys shared with the ESXi server are hosted on the local machine

/vfms/volumes/datastore1/Others/rsync is the path on the ESXi server where to find the self-contained rsync executable

The rest should be pretty much self-explanatory after a standard RSYNC tutorial.

Iscsi,Storage and ESXi – Part 1

I got annoyed at the datastore in ESXi being only accessible via winSCP. No Samba, or any option to share the ISOs. So I have started looking at enabling iSCSI storage on one of the VMs so I could easily share ISOs and back them up across the network.

To enable iSCSI on a standard Ubuntu 12.04 LTS install,I followed those instructions http://linhost.info/2012/05/configure-ubuntu-to-serve-as-an-iscsi-target/. Very detailled and well-written,only think that caught me is that in the target definition, ScsiId is an upper case i and not an l, stupid typo.

Target iqn.2012-05.local.mynet:storage.sys0
Lun 0 Path=/media/volume0/storlun0.bin,Type=fileio,ScsiId=lun0,ScsiSN=lun0

And what I realized is that when you add it as a datastore to ESXi,it gets formatted in vmfx format, which Windows doesn’t know what to do with! Dead end so…