Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


IPv4 over IPv6 tunnel on VMWare - Kinda like LES?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

IPv4 over IPv6 tunnel on VMWare - Kinda like LES?

spammyspammy Member

I have a dedicated server which I have VMWare ESXi 6.0 installed on it. The server comes with only 2 IPv4 (one already assigned to management network so there is only one that's actually free) but has a /48 IPv6 assigned to the server.

So far I have managed to attach all the (public) IPv6 address to each one of the guest VMs, as well as set up the IPv4 to one of the guest VMs (running Debian). My guest VMs are either running on Debian or Windows 2008 R2.

This works for the most part however the guest VMs will failed to connect to websites that are IPv4 only. Most notably Github (how can they don't have IPv6 connectivity???). Therefore I plan to somehow route all the IPv4 traffic to that particular VM with the external IPv4 address.

One way of doing this seems to set up the guest VM with IPv4 configured as a router, however this seems to be quite complicated.

I am wondering if there is any way I can pass all the traffic on IPv6 internally from the other guest VMs to the VM with IPv4 configured and then having that going to the external IPv4 world?

If this is not possible, is there any other way to get the plan to work without too much configuration hassle?

Comments

  • AnthonySmithAnthonySmith Member, Patron Provider

    spammy said: One way of doing this seems to set up the guest VM with IPv4 configured as a router, however this seems to be quite complicated.

    If that seems complicated you need to take a few steps back already, this is really simple, how did you even manage to get online at home if you don't understand how NAT routers work?

    I don't mean any offense but the time it would take to teach you the principals is beyond a forum, so what I suggest is you start googling "vmware virtual router" and get one of the pre-built router appliances, @mikho might know of a good one.

  • mikhomikho Member, Host Rep

    For one of my projects I used psense. It has a vmware install guide. However, if you try to route traffic in (on specific ports) its not that straight-forward.

    Nat network with many guest OS sharing one ip is really simple, just follow the guide.

    Thanked by 1AnthonySmith
  • spammyspammy Member

    AnthonySmith said: If that seems complicated you need to take a few steps back already, this is really simple, how did you even manage to get online at home if you don't understand how NAT routers work?

    Thanks Anthony, at home the routers are generally plug and play with some basic configurations (on a nice GUI as well!), with VMWare I think it is somewhat more complicated.

    mikho said: For one of my projects I used psense. It has a vmware install guide. However, if you try to route traffic in (on specific ports) its not that straight-forward.

    I guess this is the one you are referring to?

    https://doc.pfsense.org/index.php/PfSense_on_VMware_vSphere_/_ESXi

  • mikhomikho Member, Host Rep

    @spammy said:

    >

    mikho said: For one of my projects I used psense. It has a vmware install guide. However, if you try to route traffic in (on specific ports) its not that straight-forward.

    I guess this is the one you are referring to?

    https://doc.pfsense.org/index.php/PfSense_on_VMware_vSphere_/_ESXi

    yup. It really is simple to install. They even tells you how to add the internal network that you will connect all your guest VMs to.

    connect 2 network cards to your pfSense VM, run the installer, select which network card should be internal and which one is the WAN card. Set IP, create a VM on the internal network , connect to pfSense (it's not open on the WAN card). Create a DHCP server (if needed) or assign static internal IPs to your guests.

    On my project I had port 80 & 443 forwarded to a guest VM with HAProxy installed which in turn forwarded the web traffic to different other guests.

    Thanked by 1spammy
  • NomadNomad Member

    pfSense works like a charm on such an occasion.

    It'll be your DHCP server, IPS/IDS, Firewall and many more depending on your needs.

    On vmware create a secondary network that's not attached to the network cards, name it LAN for example.

    Create pfsense vm and add your existing network interface and the secondary interface.

    Install it, assign the public IP to it.

    Then when you create a VM, put it behind the LAN interface. Create a few rules to pass traffic from pfsense to the VMs and voila... You'll be glad. But then again it isn't that easy. You will have a learning curve but if instead of buying new IPs you want to use your ones, this should be the way. I currently run a few hosts like that, not all has 1-2 IP addresses but still...

  • spammyspammy Member

    Nomad said: You will have a learning curve but if instead of buying new IPs you want to use your ones, this should be the way.

    That is exactly what happened to me, I used to buy IPv4s all the time, and just assign one each for my VMs. However those VMs are mostly outbound with no need for inbound connection so it was really kind of a waste. Plus the IPv4s are getting more and more expensive...

  • spammyspammy Member

    Also is it possible to have IPv6 still routed directly but having PFSense only handle the IPv4 traffic?

  • NomadNomad Member

    Sure, you can leave your current setup as is.

    You will add a second network interface to your existing machines. Via that, you can provide IPv4 connectivity.

    Though If you want pfsense can also be your dhcpv6 server as well but in your case there's no need.

    You will dhcp serve NAT IP addresses to the connecting vm's. That way you can do port forwarding when you need the vm's to be connected from the outside world as well.

    I don't know of any easier way to do that in ESXi, you need to use pfsense and such software to achieve that. But you will like it in the end.

Sign In or Register to comment.