[Nottingham] How to enable echo (for ping)

Martin nottingham at mailman.lug.org.uk
Wed Jul 30 17:01:01 2003


Tom Bird wrote:
>>OK folks, this must be a trivially simple question...
>>
>>How do I enable echo on this box?
 >>
[...]
> 
> TCP echo is part of x?inetd, but ICMP echo is handled by the IP stack
> itself.
> 
> You're better off with the TCP one disabled.
> 
> Try 'iptables -A INPUT -i lo -j ACCEPT' or some similar incantation.  Make
> sure 'lo' is actually up.

OK, an 'iptables -L -v' gives:

Chain INPUT (policy DROP 0 packets, 0 bytes)
  pkts bytes target     prot opt in     out     source 
destination
  1110 1627K ACCEPT     all  --  lo     any     anywhere 
anywhere
  8849 5966K eth0_in    all  --  eth0   any     anywhere 
anywhere
     0     0 common     all  --  any    any     anywhere 
anywhere
     0     0 LOG        all  --  any    any     anywhere 
anywhere           LOG level info prefix `Shorewall:INPUT:REJECT:'
     0     0 reject     all  --  any    any     anywhere 
anywhere

Chain FORWARD (policy DROP 0 packets, 0 bytes)
  pkts bytes target     prot opt in     out     source 
destination
     0     0 eth0_fwd   all  --  eth0   any     anywhere 
anywhere
     0     0 common     all  --  any    any     anywhere 
anywhere
     0     0 LOG        all  --  any    any     anywhere 
anywhere           LOG level info prefix `Shorewall:FORWARD:REJECT:'
     0     0 reject     all  --  any    any     anywhere 
anywhere

Chain OUTPUT (policy DROP 0 packets, 0 bytes)
  pkts bytes target     prot opt in     out     source 
destination
  1110 1627K ACCEPT     all  --  any    lo      anywhere 
anywhere
   312 33072 ACCEPT     icmp --  any    any     anywhere 
anywhere
  7579  802K fw2net     all  --  any    eth0    anywhere 
anywhere
     0     0 common     all  --  any    any     anywhere 
anywhere
     0     0 LOG        all  --  any    any     anywhere 
anywhere           LOG level info prefix `Shorewall:OUTPUT:REJECT:'
     0     0 reject     all  --  any    any     anywhere 
anywhere

[...snipped...]

Which seems to show ACCEPT for lo INPUT and lo OUTPUT for all...

So have I not got echo in the tcp stack?!
Martin



-- 
----------------
Martin Lomas
martin@ml1.co.uk
----------------