How to connect to a webserver hosted on vmplayer guest os? - linux

I am running a webserver (eg: tomcat7) in vmplayer guest, with NAT and I am able to view the webserver from guest using it's hostname:port but host browser is unable to connect to this webserver. Any idea? Is there any specific network configuration that needs to be done for host to connect to guest?
Note: I used ifconfig and got ip address from eth8, but ping request times out all the time.
VMWARE player network settings screenshot
Update
I also had to add entries in both machines hosts file for DNS

Change the network settings to use Bridged. That will connect to your router and get an IP off DHCP which your Host will be able to see. NAT is using your host address.

Related

Open docker to internet from azure Redhat server without IP forwarding

I have 5 docker containers running inside Azure Redhat Server. If IP forwarding is enabled it works over the internet.
As a security issue need to disable IP forwarding.
Is there any solution like switching it from docker0 to eth0?

How to use iis with friendly name on local network

I make a web site to my local. I set bindings local.com and www.local.com. I add hosts xml to
127.0.0.1 local.com
127.0.0.1 www.local.com
So, I can connet on my pc like
local.com,
www.local.com,
192.168.1.35
But another pc on my network can't conenct with friendly name
www.local.com,
local.com,
But same pc can connet with ip
192.168.1.35
How can that another pc connect with friendly name ?
IP Addresses are the numerical identification for each device on a computer network.
Named Addresses invented, because remembering each device Address's turned to a difficult job.
So someone must know's which names must be converted to which IP Address.
DNS Servers are responsible to do this translation. But you done that locally. Actually you don't have a DNS Server on your local System, So you can't tell to others that "WWW.Something.COM" is my Address.
If you didn't connected to the internet, you must establish a DNS Server or done this task manually in all clients:
https://helpdeskgeek.com/networking/edit-hosts-file/
Running a DNS Server is another task. you can search for DNS Server applications like https://simpledns.com/ or you can setup a DNS Server using Windows Server. for both scenarios you need to tell to your clients to add your DNS Server Address to their network Adapter settings.
or If you are connected to the Internet, you can Use a NoIP to register a free Address:
https://www.noip.com/
you then need to download an application (In Noip.com) to monitor IP changes, it will monitors your IP address and it changes and then tells to NOIP.com to translate your address into your current IP address.
Actually NOIP will registers your address globally around the Internet network and each one who can access to the internet is able to reach to your address.

My Virtual Server Linux Dosen't connect to internet

I Have Virtual server That My App is connected this and webService is on there
app can connect and get data and i can connect to that by vnc-Viewer or ...
but
server can not connect to internet or any website
please help me
There are two option for VM.
1. linux
2. window.
Linux :- check and find the ip has connected to ethernet port and also entry to /etc/resolv.conf.
nameserver 8.8.8.8
nameserver 8.8.4.4
then start the network service using command service network restart(centos-6) and also start sshd service for outside ping.
Window:- in window case you have to check that remote setting has enabled.
window property - > remote setting.
then ping the ip outside the network, it may be work

Write failed: Broken pipe

i was accessing a vm from a server ip . today i changed that vm ip to a different ip.but while restarting network it showed
Shutting down interface eth0: Write failed: Broken pipe
after that i am not able to access the old ip as well as the new ip i assigned.i think it shutted down the eth0 interface . so i am not able to access.so how to reset that vm network configuration now from server ip??? i am not able to ssh now to that vm from server as well .
note: i ahve a server ip.i am doing ssh to that ip first.then i was doing ssh to a vm ip. i was not able to access directly the vm from outside. so i was configuring that vm to a new ip for outbound access.

SSH into Linux Guest Virtual machine from External Source?

I currently have a Linux server running as a guest on Virtualbox using Windows 8.1 as the host. I can SSH from my Windows host into the guest with no problem. But how do I set it up so I can SSH from an external machine that is not within the local network, like from another country, for example? All the examples I see online are SSHing from the host to the guest only.
My Linux guest is using a bridged network and using dynamic IP.
Thank you very much!
Ok, so I got it figured out!
I set up 2 networks in Virtualbox: NAT (eth0) and bridged (eth1). NAT allows for internet access from the Linux guest, and bridged allows the Windows host to send the data through to the Linux guest. Both are given dynamic IP in the Linux guest.
In the port forwarding section for NAT of Virtualbox, I have the interal IP address of the Windows host and the IP address of the bridged connection as guest. In my case, it's 192.168.1.1 and 192.168.1.8, respectively. Ports are 2222 and 22, respectively.
For my router, I enabled port forwarding to port 2222 of the Windows host (192.168.1.1).
In Windows Firewall, I opened up port 2222 for connections.
And that's it! I can now SSH to the Linux guest from computers in the local network via (username)#192.168.1.8, and via (username)#Windows_host_public_IP from a computer outside the local network.
I followed all the steps which you mentioned but still I am not able to connect from external network.
Steps I followed listed below.
Created NAT and Bridged connection on Linux vm.
Created NAT and Bridged connection on virtual box.
In NAT port forwarding table of virtual box, added host ip as windows ip and host port as 2222 along with guest ip as Linux vm Bridged ip and guest port as 22.
Opened port 2222 on windows firewall settings.
Please let me know if I missed something here.

Resources