Advise - VMWare - NAT/Bridged

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Advise - VMWare - NAT/Bridged

Post by A.Cormack »

Hi All,

I'm looking for some advise, first of all I'd like to appologise for my lack of experience, I've only been using Nagios XI for a few weeks, for my dissertation project so I'm still in the procedure of learning.

I am using VMWare which is currently running Nagios, 2 x XP Machines and a Windows Server. This current set up is using NAT as if I change them to bridge they all stop communicating. I am trying to monitor a switch outside the VMware enviroment so for this I need to change the connection to bridged.

To test this theory I had to ports on Nagios Eth0 (NAT) and Eth1(Bridged). If i tried to ping the switch with both interfaces open, it failed, if i closed Eth0 and pinged, it suceeded.

My question is, is there anyway to get Nagios to use both interfaces? and if not, can anyone recommend a solution or a work around?

Again, appolgies if these are stupid questions, I'm still learning.

Thank You.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Advise - VMWare - NAT/Bridged

Post by lmiltchev »

Are you changing the network adapter' to "bridged" on one VM only or on all of them? What happens when you use only one interface?
Be sure to check out our Knowledgebase for helpful articles and solutions!
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Advise - VMWare - NAT/Bridged

Post by A.Cormack »

I'm changing to bridge adapter on all of them.

If I have a single interface running on Nagios, its as follows...

Set to Bridged - Can ping all VMWares but not swtich.
Set to NAT - Can ping switch, but can not ping VMware's
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Advise - VMWare - NAT/Bridged

Post by sreinhardt »

Firstly, using two interfaces as you had tried, probably will not work as expected. Because they can both end up routing into the same address space your machine could be simply getting confused on which interface to actually send on. Also, you most likely will not need to switch from NATed to bridged to communicate with the switch. Once your VM understands the route and sends the packet, the devices, virtual or real, in between will have no problem sending it back.

With that, I would suggest trying with just a single interface on the NAT network, to communicate with the switch from your nagios host. At the same time, you may try using another VM on your same network to touch it, to verify whether the issue really is the nagios machine or something with the network.

1) When switching between bridged and NAT connections on all machines, are you rebooting, restarting network services, or letting each machine handle it alone?

2) Are you using IPTables or another firewall on each host? If so are you making changes to those rules as you change networks?

3) Considering your last post, have you attempted to communicate with either the VMWare gateway, or the internet with any of these machines once either bridged or NATed? How does it work in either case?
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Advise - VMWare - NAT/Bridged

Post by A.Cormack »

Apologies for the severe delay in replying to this post. With the festive holidays and other university work my project took a back seat for a while.

Due to time constraints, I'm going to go down the route of using several physical machines and completing it that way.

I'd like to thank you for your help and quick responses in trying to resolve this issue. Please mark this post as resolved or closed, what ever is easiest.

Thanks again.
Locked