Can't access Apache web server from outside lan

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
toddbailey

Can't access Apache web server from outside lan

Post by toddbailey »

Hi All

I trying to get access to a web server installed behind a router (westel 7500 series) and so far nothing works.

I've set up port forwarding for both port 80 and 8080 to the server (192.168.1.10)
I've tested the ip on canyouseeme port test web site
I've turned off the firewalls, I can ping the ip address 50.47.91.193
I've edited apache2.conf to include
NameVirtualHost 192.168.1.10
NameVirtualHost 50.47.91.193
<VirtualHost 192.168.1.10 50.47.91.193>
DocumentRoot /var/www
ServerAlias aasi-intranet
</VirtualHost>

But still can't access the web site via the external ip address (50.47.....)
everything looks right, so what am I missing ?

eventually I want to set up an account on no-ip.org but for now I should be able to access the web server as it is.

any clues
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
wavespot
Level 2
Level 2
Posts: 94
Joined: Tue Jan 17, 2012 6:44 am

Re: Can't access Apache web server from outside lan

Post by wavespot »

I think you miss the 'Servername directive' inside the virtualhost block.

Virtualhost <IP>, means apache listen to the specified IPs (so, your external IP is useless here). Use the wildcard for debugging, and then you can restrict the binding.

<VirtualHost *:80>
DocumentRoot /var/www
Servername 50.47.91.193
ServerAlias aasi-intranet
</VirtualHost>

-- Fred
toddbailey

Re: Can't access Apache web server from outside lan

Post by toddbailey »

wavespot wrote:I think you miss the 'Servername directive' inside the virtualhost block.

Virtualhost <IP>, means apache listen to the specified IPs (so, your external IP is useless here). Use the wildcard for debugging, and then you can restrict the binding.

<VirtualHost *:80>
DocumentRoot /var/www
Servername 50.47.91.193
ServerAlias aasi-intranet
</VirtualHost>

-- Fred
I have no idea what you just said, I have 0 experience with apache can you expand a bit on your comments?
thanks
js3915

Re: Can't access Apache web server from outside lan

Post by js3915 »

toddbailey wrote:I have no idea what you just said, I have 0 experience with apache can you expand a bit on your comments?
thanks
What he means is, try first with the wildcard * under virtualhost *:80 which means when apache gets a request from the outside world it will try port any Internal IP address on port 80.. See if you can make that work first. After you can set a specific IP on your Local network

You also need a Server Name which for now would be external IP

If that helps
toddbailey

Re: Can't access Apache web server from outside lan

Post by toddbailey »

2 valid answers, but I stilll have no idea what you are asking me to do,
an example is needed.

BTW: I've setup IIS on a vm box running vista and I can't access it either via the routers external ip address.
but if I use local host or the internal ip address no issues,
I think the issue is with the router's port forwarding rules.
js3915

Re: Can't access Apache web server from outside lan

Post by js3915 »

toddbailey wrote:2 valid answers, but I stilll have no idea what you are asking me to do,
an example is needed.

BTW: I've setup IIS on a vm box running vista and I can't access it either via the routers external ip address.
but if I use local host or the internal ip address no issues,
I think the issue is with the router's port forwarding rules.
Yes would need to ensure Port 80 on your router is forwarded to the IP of the machine. I dont know this router type so I would need to do some searching myself to see how to enable port forwarding on that particular model

Hope i didnt confuse you too much with that :/
toddbailey

Re: Can't access Apache web server from outside lan

Post by toddbailey »

It's a westell 7500, and I'm not the only one what has port forwarding issues with this device

I have both ports 80 and 8080 forwarded to the web server.
There is a remote admin enable setting so now I can at least see the router config via it's external ip address. But still can't see the web servers
wavespot
Level 2
Level 2
Posts: 94
Joined: Tue Jan 17, 2012 6:44 am

Re: Can't access Apache web server from outside lan

Post by wavespot »

toddbailey wrote:
wavespot wrote:I think you miss the 'Servername directive' inside the virtualhost block.

Virtualhost <IP>, means apache listen to the specified IPs (so, your external IP is useless here). Use the wildcard for debugging, and then you can restrict the binding.

<VirtualHost *:80>
DocumentRoot /var/www
Servername 50.47.91.193
ServerAlias aasi-intranet
</VirtualHost>

-- Fred
I have no idea what you just said, I have 0 experience with apache can you expand a bit on your comments?
thanks
I wrote the config block you need to use (5 lines above, between <Virtualhost> and </Vitualhost> , replace your lines with that.
toddbailey

Re: Can't access Apache web server from outside lan

Post by toddbailey »

Thanks I see the changes

however I still can't connect to the web server from the outside.
There is something with the dsl router that isn't connecting the outside lan with the local.
Frontier is offering no assistance and I haven't found any useful information from google either

I did find a video on you tube that the title addresses the issue, but it doesn't play-- figures.
Locked

Return to “Networking”