LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud
User Name
Password
Linux - Virtualization and Cloud This forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.

Notices


Reply
  Search this Thread
Old 03-09-2021, 08:38 PM   #1
rrog
LQ Newbie
 
Registered: Feb 2021
Posts: 2

Rep: Reputation: Disabled
Allowing traffic to a VM


Hey guys,

So I'm having an issue with port forwarding - and could really use a tip or two on how to get things working... Here is my senario:

I'm running Linux on a VM I've created on a ESXi Hypervisor

The Linux machine has a private IP in my home network (192.168.1.94).

I have setup our route to forward any requests on all ports to this system, (also tried selective ports like 22/80) - but

No matter what, I cannot seem to have anyone from the outside world touch these systems.

Looking at the logs, it seems I'm getting some blockage in terms of my router address... but I thought I have it all open for port 80.

Anyone else run into this? any tricks or help would be supper appreciated.

Thanks all
 
Old 03-09-2021, 08:44 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Check if your ISP is blocking it.
 
1 members found this post helpful.
Old 03-09-2021, 11:49 PM   #3
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
I suppose ESXi has several ways of attaching the VM to the network. With other hypervisors like KVM or VirtualBox, default attachment is NAT, which requires port forwarding to access the VM. I have had countless situations where I could not reach a VM because I had set up the network attachment incorrectly.

So, in order to help you, it would be good to know:
  • how does ESXi attach the VM
  • from where and how are you trying to connect to the VM (if you issue commands, show the commands)
  • where do you define the route you mention, and what is that route precisely
  • which logs did you check, what do you mean by "blockage in terms of my router address", and how do you come to that conclusion
  • the network topology

Last edited by berndbausch; 03-09-2021 at 11:50 PM.
 
Old 03-10-2021, 05:22 AM   #4
rkelsen
Senior Member
 
Registered: Sep 2004
Distribution: slackware
Posts: 4,454
Blog Entries: 7

Rep: Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557
Allowing traffic to a VM

What services is it running that you're trying to access? Can you ssh in?

It's quite unusual to want all traffic to be allowed through a firewall and redirected to one machine.

Perhaps provide more details about what you are trying to achieve.

What kind of server are you trying to build?

Beware that as suggested above, most ISPs will block "commercial" traffic on home networks. You can't run a web server from home, for example.

Last edited by rkelsen; 03-10-2021 at 06:15 AM.
 
Old 03-10-2021, 06:23 AM   #5
rkelsen
Senior Member
 
Registered: Sep 2004
Distribution: slackware
Posts: 4,454
Blog Entries: 7

Rep: Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557Reputation: 2557
Quote:
Originally Posted by berndbausch View Post
I suppose ESXi has several ways of attaching the VM to the network. With other hypervisors like KVM or VirtualBox, default attachment is NAT, which requires port forwarding to access the VM.
ESXi is a type 1 hypervisor, which works quite differently to the ones you mentioned.

VMs operating under ESXi are configured by default to operate the same way as any other machine on your network. That is to say that the hypervisor acts as a virtual switch by default, and you don't need to set up any port forwarding to access the VMs.
 
Old 03-10-2021, 07:33 AM   #6
dc.901
Senior Member
 
Registered: Aug 2018
Location: Atlanta, GA - USA
Distribution: CentOS/RHEL, openSuSE/SLES, Ubuntu
Posts: 1,005

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
Quote:
Originally Posted by rrog View Post
I have setup our route to forward any requests on all ports to this system, (also tried selective ports like 22/80) - but

No matter what, I cannot seem to have anyone from the outside world touch these systems.

Looking at the logs, it seems I'm getting some blockage in terms of my router address... but I thought I have it all open for port 80.
Before starting to look at this from "outside"; let's look at "inside"...
On your Linux VM; are the ports actually open? Look at output of: netstat -ntlp

Is there a firewall on your Linux VM? If so, are these ports allowed thru that firewall?
Try to access port 80 (or 22) from another machine on the same network. Does that work?
 
Old 03-11-2021, 07:23 PM   #7
jmgibson1981
Senior Member
 
Registered: Jun 2015
Location: Tucson, AZ USA
Distribution: Debian
Posts: 1,141

Rep: Reputation: 392Reputation: 392Reputation: 392Reputation: 392
Simple question. Do you have a static ip? Generally for any server stuff you will need a static ip. In my area a static ip isn't just nice to have. It's the only way to get mostly unrestricted access to ports. They may all be blocked on the isp side as they don't want people running servers on them.
 
Old 03-11-2021, 09:53 PM   #8
rrog
LQ Newbie
 
Registered: Feb 2021
Posts: 2

Original Poster
Rep: Reputation: Disabled
Hey Jim and everyone that replied... I'm afraid to admit - I think you guys are right.. looks like telus blocks these ports for "residential" users.. (me).

Thank you guys - this one now makes sence.. still sucks, but at least I know.

Thanks again all!

Quote:
Originally Posted by jmgibson1981 View Post
Simple question. Do you have a static ip? Generally for any server stuff you will need a static ip. In my area a static ip isn't just nice to have. It's the only way to get mostly unrestricted access to ports. They may all be blocked on the isp side as they don't want people running servers on them.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Securing a network by only allowing traffic from certain ip addy's or maybe mac addy cereal83 Linux - Security 6 08-15-2007 01:57 PM
allowing traffic in some ports igordonin Linux - Networking 10 12-11-2006 08:46 AM
iptables allowing all LAN traffic tebucky Linux - Security 1 11-04-2004 11:27 AM
allowing IP traffic on firewall - unsafe? complus Linux - Security 4 09-04-2003 03:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud

All times are GMT -5. The time now is 12:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration