« Posts tagged qnap

NFS VMware Datastore with QNAP

The new Qnap nas has also NFS service onboard, so I want try to use it as "addon datastore" for my VMware infrastructure.
I know poor performance but I'll use it to keep CD/DVD images, test virtual machines an why not, backup.

First of all we have to check if our esx hosts can reach the NAS, I mean the VMKERNEL, not the management, so ssh into your ESX and try with

root@esxhost# vmkping your.nas.ip

If you get response you are done, if not you have 2 solutions:

  • put your nas in the vmkernel's network
  • add another vmkernel

I've added another vmkernel, because we use the first for Vmotion and I want keep this separate.

So, open VI client, from inventory view choose "Hosts and Clusters" select the first Esx host and go to "configuration tab.", select "Networking" then "Add Networking".

Using the Wizard, select VMkernel and click Next. According with your network configuration, select the VSwitch that can communicate with your NAS

Give a name, IP Address and netmask (on the same netwok of NAS) to the new interface

Click Next and finish.

Try to "vmkping" and you should see response.

Now repeat these steps for all ESX hosts you have

Instruction From QNAP to use NFS on with VMware are not correct, because ESX is able to use NFS only over TCP; unforntunatley Qnap nas use NFS over UDP.

So we have to "force" the QNAP to use TCP instead of UDP...
In the configuration page on NAS there's no way to change this; so we have to connect in SSH and edit this file:
/etc/init.d/nfs

the line to change is #132

NO_V4="-N 4 --no-udp"

Reload the NFS service

/etc/initd/nfs restart

Now through the web management we can set permission to the share we want use

I permit full access from both esx hosts to this share

So, open VI client, from inventory view choose "Hosts and Clusters" select the first Esx host and go to "configuration tab.", select "Storage" then "Add Storage".

Follow the wizard  for configuration:

Select "Network File System"

Fill with ip address or name of your NAS, in the Path field put the name of the share you previously defined on the NAS

Click Next and finish.

Repeat this step with same data for all ESX hosts and you are done.

N.B.
this how to require you know what are you doing.
I'm not responsible if you destroy your production machine following my instruction.

Qnap TS419u port trunking with Cisco 4500

This powerful NAS (linux core inside) have 2 NICs that you can use in various mode.
I've choose to  aggregate these 2 NICs to have load balance and failover.
Through the web page go to System administration, then to network; here flag "Enable port trunking" option.
in the dropdown menu ou have to choose "IEEE 802.3ad". and apply settings.

Let's go to the cisco switch ( I have Cisco IOS, not CAT OS)
i'm assuming the two NICs are connectet to Gi1/1 and Gi1/2 (adapt to you)

interface GigabitEthernet1/1
 description to NAS
 switchport access vlan 10
 switchport mode access
 speed 1000
 duplex full
 channel-protocol lacp
 channel-group 64 mode active
end

interface GigabitEthernet1/2
 description to NAS
 switchport access vlan 10
 switchport mode access
 speed 1000
 duplex full
 channel-protocol lacp
 channel-group 64 mode active
end

interface Port-channel64
 description Connessione NAS
 switchport
 switchport access vlan 10
 switchport mode access
end

With this configuration on the switch, when you disconnect one NIC you will not loose connection to the NAS even if you are transferring data.