iSCSI Target on Second NIC with ESXi

Status
Not open for further replies.

hermanpeckel

Dabbler
Joined
Jun 5, 2012
Messages
12
Hi,

I have managed to set up a sweet home lab using ESXi in a diskless box, connecting to my FreeNAS box via iSCSI. So far so good, but now I want to push it a bit further and separate the iSCSI traffic from my normal LAN. I plan to put a second NIC into the FreeNAS box and set up the networking for management on one NIC, iSCSI on the other.

My problem lies in how to and which NIC to change (as in which will be easier). Currently everything is on 192.168.5.x (including a load of VM's - probably 10 machines in total). Ideally I'd like to change the iSCSI to 192.168.6.x, but am unsure how I'd have to go about setting up iSCSI target again.

Any thoughts? Is setting up a new IP for iSCSI relatively straight forward? This box has ALL of my stuff on it so I'm a bit nervous about killing it. Any suggestions much appreciated.

Regards
HP
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
So are you saying you have no backup? If you have no backup you should seriously consider doing a backup. The reason I have what I have in my sig is because of the number of people that lose data and then realize how valuable a backup is...after its too late.

As for your IP issues I'm not sure how to do that exactly. If your subnet is 255.255.255.0(typical setup for most people) then I don't believe you can do what you want.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
It is unlikely to kill it, just proceed slowly and incrementally, testing each step along the way. When you put the second interface in the FreeNAS box, that does not need to be a flag day to move all traffic onto the new interface. Just get the IP networking up and working. Your ESXi and FreeNAS box will both take a little configuration to get working with an extra network.

It basically works like this:

1) Add new vSwitch and VMkernel interface to ESXi. Configure.
2) Add interface to FreeNAS. Configure.
3) Verify connectivity between ESXi and FreeNAS using IP networking utilities like ping, etc. If you are trying to do something gimpy like not using a second switch you may have ... issues.

4) Check to see if you are using 0.0.0.0 as the iSCSI portal address on FreeNAS. If so, good.
5) Add 192.168.6.* to your iSCSI initiators authorized networks list.

6) If you can afford a little VM downtime, shut down ESXi, reconfigure it to use 192.168.6.* for iSCSI, and then go. If you cannot afford a little VM downtime, then you may want to look at the multipathing instructions for ESXi and iSCSI.

Theoretically you can do all of this with zero downtime as long as you don't need to down the hardware to stick in cards. In practice, it is easier for someone without the experience to take it slow and plan some downtime to verify the steps.
 

hermanpeckel

Dabbler
Joined
Jun 5, 2012
Messages
12
@noobsauce - Oh, don't get me wrong, I know how reckless it is. The problem is that it is my home setup and I don't have the disk space or extra machine to backup 9TB of data.

@jgreco - Nice!! That's exactly what I was after!! Thanks heaps! Everything you say makes sense and gives me a bunch of things to try. I actually WAS planning on doing "something gimpy" and just using a crossover cable from the second pNic on ESXi to the second pNIC on the NAS. Not a good idea?

Thanks again!

HP
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
Everything you say makes sense and gives me a bunch of things to try.

Just know that some of those steps may require a little additional research and work, and since the list was generated off the top of my head, might not even be complete or correct.

I actually WAS planning on doing "something gimpy" and just using a crossover cable from the second pNic on ESXi to the second pNIC on the NAS. Not a good idea?

I'm not sure why that would be doing something gimpy.

Gimpy: connecting two different subnets (i.e. all of your server ports) to the same switch, thereby creating the opportunity for unintended communications. Fun results when something sees ARP messages on the "wrong" interface and the IP stack gets FUBAR'd.

Gimpy: connecting everything on one subnet and not knowing that "binding" to IP addresses does not imply binding to a particular physical card (explained THAT several times in recent years to people, sigh).

Not gimpy: having two completely separate and properly configured IP subnets, following best practice for ESXi by having one of them as a dedicated storage network. The fact that your dedicated storage network is sufficiently small that it doesn't require a switch? Well that's just a side effect of having only two hosts on the net.

Put differently: Would you use 1000baseLX gig fiber cards, SFP's, and conditioning cables to hook your ESXi and FreeNAS up to a switch that was 5 feet away? You COULD do it and it would be legitimate but it'd be a stupid waste of money when a copper card and cables are a tenth the cost, eh? Why spend money on fancy ethernet gear that serves no purpose and contributes no value to your network? Just more things to fail.

So when you consider it in that light, a direct connection between hosts instead of including a pointless switch is more of a smart move than anything else.

Oh. By the way. Don't use a crossover cable - just a regular cable. GigE is supposed to do auto-MDI/MDIX and should figure out the configuration all by itself. Completely awesome and "about effin' time."
 

hermanpeckel

Dabbler
Joined
Jun 5, 2012
Messages
12
Sweet! Thanks jgreco! I kicked it off last night by putting the 2nd NIC in my FreeNAS box. Baby steps...

Thanks again!

HP
 
Status
Not open for further replies.
Top