0

I have a dedicated server running Ubuntu 9.04. I have sites running fine on the server and are accessible from anywhere. However, pinging the server's IP address always results in timeouts.

I did some Googling and saw information that said to basically put 0 in the file /proc/sys/net/ipv4/icmp_echo_ignore_all. I checked and that was already the case (I ran the command on here just to make sure).

But the server is still not pingable. Is there something else that could be the problem?

PS. I have seen some places mention firewalls. I don't know if the server has a firewall installed (I haven't installed anything myself but the server came pre-built with everything). How would I find out if there is a firewall running? And can the server be pingable but keep the firewall running?

DisgruntledGoat
  • 2,629
  • 4
  • 28
  • 36

1 Answers1

0

Most likely you would be running iptables as a firewall. Type iptables -L as root to see if there is a rule (or the lack thereof) for ICMP requests. If there are rules, save all using iptables-save, add an additional one for your ICMPs (for example -A INPUT -p icmp -j ACCEPT) and reload the entire batch with iptables-restore.

Christian
  • 411
  • 2
  • 7
  • If he doesn't know to check iptables, he's not going to know that iptables-save writes to stdout, and will need to save that to a file, to be read in with iptables-restore. – Nathan Powell Feb 12 '11 at 19:30
  • If you run a dedicated server and host several sites, I assume you are able to redirect the output of a program to a file (and possibly read a man page). Besides, he has already another question on how to save the iptables rules running. – Christian Feb 12 '11 at 19:46
  • Yeah I'm a bit of a newbie when it comes to server management, but I'm fairly clued up on Linux and command line usage :) – DisgruntledGoat Feb 13 '11 at 15:43
  • Thanks, it works now. One more question regarding save/restore: is this a good way to reorder the rules? For example, first running `iptables-save > iptables.bak`, editing that file, then running `iptables-restore < iptables.bak` ?? – DisgruntledGoat Feb 13 '11 at 16:12