Clicky

I have a server on my LAN and I want to use my linksys WRT54G2 to forward internet traffic to my CentOS web server where I have my website. I had it working before using NAT one-to-one on my SOHO3 Sonicwall, but the Sonicwall died. I'm trying to just use this Linksys now to route the web traffic for now. I realize it's not optimal, but I think it should be working.

I set Port Range Forwarding to forward port 80 to 192.168.1.43 (my web server).

RDP is working fine to my file server, but the web server just won't work. I can see it locally on my LAN, but when I go to the WAN address in a browser. No can do.
linksysWebServer.jpg
  • 86 KB
  • linksys port range forward
linksysWebServer.jpg

    asked 12/12/2011 08:33

    mrmyth's gravatar image

    mrmyth ♦♦


    16 Answers:
    Have you tried accessing it from outside your local network?  You're generally not going to be able to access an address on your LAN through this router from within your LAN using the WAN address.

    Also, make sure remote administration is turned off in the router.


    link

    answered

    akahan's gravatar image

    akahan

    Thanks, good point. I have tried from outside and I have the same problem.

    Here is a screenshot of the settings I have for remote administration. I'm not sure the difference between "Web Access" and "Remote router Access."
    linksysRemote.jpg
    • 23 KB
    • router Remote access
    router Remote access
      link

      answered 2011-12-12 at 16:59:00

      mrmyth's gravatar image

      mrmyth

      The settings look right.
      I suppose you could try putting the web server in the DMZ temporarily to make sure there's not some firewall blocking access.
      link

      answered 2011-12-12 at 17:41:17

      akahan's gravatar image

      akahan

      okay i figured something out. my web server is CentOS and i can't  get the port to forward to it, however, my file server also has an old website on it and i forwarded the 80 web port to it and it works fine, i can see the site from a browser. the external IP address is new, maybe the CentOS sever website requires some change of some sort
      link

      answered 2011-12-12 at 17:58:07

      mrmyth's gravatar image

      mrmyth

      By the way, my fle server is windows smb 2003. Ive just requested attention from a Linux queue too in case it's it's a setting on my web server to accept the WAN IP address change
      link

      answered 2011-12-13 at 00:05:20

      mrmyth's gravatar image

      mrmyth

      Hi,

      the problem is that the router use this ports to mgmt, you need to create another NAT rule for example:

      4443 --> 443
      8080 --> 80
      link

      answered 2011-12-13 at 00:16:21

      ikalmar's gravatar image

      ikalmar

      as root on centos send us output of those

      iptables -n -vL
      iptables -n -vL -t nat
      netstat -tapn
      cat /etc/hosts.deny
      cat /etc/hosts.allow
      ip addr show
      ip route show
      link

      answered 2011-12-13 at 00:27:20

      shukalo83's gravatar image

      shukalo83

      As for linksys, disable any firewall, disable management from outside.
      link

      answered 2011-12-13 at 00:28:13

      shukalo83's gravatar image

      shukalo83

      Can I create a nat rule on this router? How come it works with my windows server?
      link

      answered 2011-12-13 at 00:29:33

      mrmyth's gravatar image

      mrmyth

      OK, now I got that you did not made port forward at all.
      http://portforward.com/english/routers/port_forwarding/Linksys/WRT54G2/

      Do it and then try from outside with your webbrowser. (You enter the wan address of linksys router, no webserver itself)
      link

      answered 2011-12-13 at 00:30:00

      shukalo83's gravatar image

      shukalo83

      Shukalo83, look up above at the 1st screenshot. Port forwarding was done. Is that what you were referring to?

      link

      answered 2011-12-13 at 00:38:51

      mrmyth's gravatar image

      mrmyth

      Sorry on that again. If your centos is 192.168.1.43 then yes.

      Please, can you post me output of aforementioned commands from webserver?
      link

      answered 2011-12-13 at 01:00:09

      shukalo83's gravatar image

      shukalo83

      It's clear that the router settings are fine; problem is with the server setup.
      link

      answered 2011-12-13 at 01:22:44

      akahan's gravatar image

      akahan

      I think it might be that the old  firewall was at 192.168.1.253 and the new one is at 192.168.1.1

      Maybe I'll change the internal ip address of the firewall first before I try to change the web server.
      link

      answered 2011-12-13 at 07:16:25

      mrmyth's gravatar image

      mrmyth

      I decided to change the web server instead. Went into the control panel of the server and found that the default gateway was indeed 192.168.1.253. I changed it to 192.168.1.1 and I'm currently rebooting.
      link

      answered 2011-12-13 at 09:19:48

      mrmyth's gravatar image

      mrmyth

      Thanks for all your help. It turns out that the default gateway on the web server had to be changed from the address of the old sonicwall 192.168.1.43 to the ip of the Linksys router 192.168.1.1

      link

      answered 2011-12-13 at 09:29:41

      mrmyth's gravatar image

      mrmyth

      Your answer
      [hide preview]

      Follow this question

      By Email:

      Once you sign in you will be able to subscribe for any updates here

      By RSS:

      Answers

      Answers and Comments

      Tags:

      ×3
      ×25
      ×30
      ×11

      Asked: 12/12/2011 08:33

      Seen: 255 times

      Last updated: 12/17/2011 05:19