-1

Well, let me give you a little detail about my problem where I can't figure out any solution to this.I basically have a local server within my company which is all set. We use xencenter to manage all the VMs. To access them, we have given them the static unique IPs to every VM which is connected to one router. Since it's within LAN. Now the issue is, I want to access from outside but not inside that is from another network my house maybe. The server is assigned with the IP of 10.0.0.4. Can you please tell me how come I do this. I just want to connect to the server's Ip from another network. Once Ill access the server I can further connect to other VMs. I don't know if I have to play with the router.

Also, Ive heard that I can access from outside if I have the hosting IP (Outside IP). So what have I done is, I have a shared hosting from Hostgator. They gave me an IP, to which I mapped into a domain that is dev.xxxxxx.com from hostgator cpanel "Advanced DNS". Now, what do I have to do to connect my outside IP (hosting IP) to my LAN so that I can Access it from outside? Again, Do I have to port forward something or define my Hostgator IP with my LAN router where the server is connected?

My desire:

I want to access any of my VM like. user@dev.xxxxxxx.com -p 2211 where -p is the port. This is the way you connect to a VM using linux terminal. I that port 2211 have be a forward port within my router and I know this how. Please help me both the question I am quite confused with this and can't figure out the way. Just simple want to connect WAN ip to my LAN so that I can access I from outside.

Ill highly appreciate it if anybody will define with a good network knowledge so that I can grab the idea of this as much as I can.

Here is the basic diagram:

HBruijn
  • 77,029
  • 24
  • 135
  • 201
Mahirq8
  • 1
  • 1
  • 1
    Typically you would either assign the hostname `dev.example.com` to the public ip-address of your LAN router and in the LAN router you would configure *port-forwarding* of LAN port 2211 to port 22 on your VM. - More conventional (and slightly more complex) is to set up a VPN server for remote access and work from home scenario's. Many SoHO routers already support running a VPN server out of the box. – HBruijn Dec 12 '17 at 07:41
  • thnks for your reply. But how come I assign dev.example.com or its IP (Open IP) into the router? – Mahirq8 Dec 12 '17 at 10:09

1 Answers1

0

You can setup dynamic DNS, so that you alway can connect to a a FQDN (dev.xxx.com). Then on your router you can do port-forwarding and forward some specific port (f.ex. 2211 like @HBujin suggested) back to the (internal) IP and port (22) of your server.

  • I suppose I've already implemented the Dynamic DNS from the hosting side and its dev.xxxx.com.. But still I cant ping this. – Mahirq8 Dec 12 '17 at 10:51
  • It doesnt seem like I want a Dynamic DNS because my hosting IP is static where dev.xxxx.com is mapped to. – Mahirq8 Dec 12 '17 at 11:10
  • Here's a general approach to solving networking problems you maybe want to have a look at: https://serverfault.com/a/885958/387342 – Tomáš Pospíšek Dec 12 '17 at 18:10