Find the answer to your Linux question:
Results 1 to 7 of 7
Hi, I've been struggling badly with this issue and still haven't worked out what's going on, so any help would be greatly appreciated in case there's something I've missed... I ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jun 2011
    Posts
    4

    Weird issue - can't connect to server IP from my ubuntu box


    Hi, I've been struggling badly with this issue and still haven't worked out what's going on, so any help would be greatly appreciated in case there's something I've missed...

    I am the only person in my office running Linux and am the only person who can't connect to our new web server IP, even though I use the same gateway and network IP as the other machines in the office. From any other machine, I can access the server using HTTP, SSH, FTP, all of which are open via the normal ports. I can ping the server by IP or name, however any attempts to connect always end up with a timed out error. If i look at the server logs, there is no record of any refused connection from my IP (which is probably to be expected). Nothing has changed in our office in terms of the networking set up and I've not changed anything locally on my machine. All that has happened is that we have transferred our remote web server to a different IP. At the moment, this means I have no access to email and to the sites hosted on our server.

    The traceroute output is the same on my machine as on windows machines in my office. There's nothing listed on the firewall rules under chain INPUT, FORWARD and OUTPUT.

    Some output below if it helps:

    /etc/resolv.conf file

    Code:
    # Generated by NetworkManager
    nameserver 192.168.0.1

    /etc/hosts

    Code:
    127.0.0.1	localhost.localdomain	localhost
    ::1	nicky-desktop	localhost6.localdomain6	localhost6
    127.0.1.1	nicky-desktop
    
    # The following lines are desirable for IPv6 capable hosts
    ::1 localhost ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    ff02::3 ip6-allhosts

  2. #2
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    You mentioned firewall rules...who is running the firewall, the webserver or your local machine? If possible turn yours off, if it is running, for testing purposes. If the webserver's firewall is blocking you, the messages would never get to the apache log...

    Have you tried accessing the webserver from the command line, to make sure your browser settings are not munged up (bad proxy server, etc.)?, e.g.:

    Code:
    wget -O test.html http://<WEB_SERVER_IPADDRESS>
    You say you can ping the webserver's name and ip address from your workstation. What does nmap tell you? You may have to install it first (yum install nmap, apt-get install nmap, etc.). Try something like this:

    Code:
    nmap -n <WEB_SERVER_IPADDRESS>
    It should list all open/filtered TCP and UDP ports on the webserver.

    You can also use arp to see if you are getting to the right machine by check the MAC and comparing it to the server's MAC:
    Code:
    arp -a <WEB_SERVER_IPADDRESS>
    also, if you are using static ip, make sure you don't have a duplicate IP address on the network!

  3. #3
    Just Joined!
    Join Date
    Jun 2011
    Posts
    4
    Cheers for the reply @atreyu.

    The firewall I was referring to was the local machine's iptables output. The firewall on the web server has our network IP whitelisted, so there shouldn't be a problem at that end I don't think, as I'm using the same IP as other machines which can access the server fine. Just to check, I switched off the firewall on my machine (using ufw stop) and still the connection timed out.

    Trying wget also results in a timeout.

    When I tried nmap -n, I got the following:

    Code:
    Note: Host seems down. If it is really up, but blocking our ping probes, try -PN
    Nmap done: 1 IP address (0 hosts up) scanned in 3.06 seconds
    Then when I tried using nmap -PN, i get a list of the open ports and the host shows as being up. Maybe there's something valuable in this...

    When i use arp -a, I get
    Code:
    arp: in 9 entries no match found.
    Thanks for the help so far, if there's anything else I can try to shed some light on this then let me know!

  4. #4
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Quote Originally Posted by nicky77 View Post
    I'm using the same IP as other machines which can access the server fine.
    but you are using a UNIQUE ip address, right? if you are using a duplicate ip address, that would be bad. The subnet mask (e.g. 255.255.255.0) and the gateway/DNS stuff can be the same on all your clients, but the IP should be unique.

    As to the arp thing, try a ping first, then an arp, and see if you get the MAC. but based upon your 2nd nmap attempt, you are getting to the right server.

    I have to say, it sounds like a firewall issue (if it is not the dup ip address thing). would it be possible to turn off the webserver firewall, for a minute or two, just so you can rule out that possibility? but don't forget to re-enable it!! and it's not my fault if you get hacked!!!

  5. #5
    Just Joined!
    Join Date
    Jun 2011
    Posts
    4
    Ah sorry, I should have said that my machine has a unique IP on the network, while the gateway IP is the same for all machines and it's this IP which is whitelisted on the server.

    Trying a ping then arp resulted in the same "no match found ".

    So it looks like that leaves the firewall on the server...I'll report back on that one (and I'll remember to switch it off!)

  6. #6
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    you mean on!

  7. #7
    Just Joined!
    Join Date
    Jun 2011
    Posts
    4
    This may or may not be useful in trying to figure out what's going on here, but I've since had the same issue on a new machine which dual boots Windows 7 and a clean install of Ubuntu. On Windows, I can access the server by host or IP absolutely fine, but on Ubuntu I get the timeout problem. I also tried Linux Mint from the live CD and had the same issue there too. Very strange!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •