Home Citrix How to create a NFS share on a Windows 2008 R2 server for use with ESXi or XenServer

How to create a NFS share on a Windows 2008 R2 server for use with ESXi or XenServer

by admin

I’ve had a requirement recently to create a small XenServer 6.2 test/demo environment. I decided to use a Windows 2008 R2 host as an NFS server to provide shared storage to the XenServer hosts as it is quick and easy to set up.

First of all you have to install NFS services. This is done by running the following command:

ServerManagerCmd -install File-Services FS-NFS-Services


nfs_feature_install

Once the installation is complete, the next step is to create a share. First of all, create a folder, then right click on it and select the NFS Sharing tab:

nfs_share

Click the Manage NFS Sharing button:

nfs_settings

For our purposes, it’s fine to leave the defaults, but we will need to change a setting in the permissions options:

nfs_permissions

We need to ensure that ‘Allow root access’ is enabled, and that the share is set to Read-Write. By default it will be set as read only. If required, you can set it so that only certain IP address are able to connect to the share, however in this example I will leave it as allow all.

Now the share has been set up it can be added to the XenServer hosts as a Storage Repository. In XenCenter, right click a XenServer host and select ‘New SR’:

new-sr

Next, choose NFS VHD as the virtual disk storage type:

nfs-type

On the next screen, give the SR a name:

sr-name

Finally, enter the path to the NFS share created earlier:

sr-server

After clicking finish the new SR should be available.

If you wanted to use this NFS share with an ESXi environment rather than XenServer, the setup is identical on the NFS server. To connect an ESXi host to it, use the Add Storage wizard in the vSphere client:

esxi-nfs

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More