Total Pageviews

Friday, May 23, 2008

Search String in many files

The command to find string in many files:

srini@ openslp-1.2.1]$ find . -exec grep -q "427" '{}' \; -print
./common/slp_message.h
./config.log
./doc/rfc/rfc2614.txt
./doc/rfc/rfc2608.txt
./doc/rfc/rfc2165.txt

Thursday, May 22, 2008

SIOCADDRT: Invalid argument

According to the usual man pages, the following command should add the normal loopback entry, using netmask 255.0.0.0 and associate with the "lo" device.

But I got an error when trying on a linux system with linux kernel 2.6.x

#route add -net 127.0.0.0


#SIOCADDRT: Invalid argument

I could fix this by using the additional arguments to the "route add" command

#route add -net 127.0.0.0 netmask 255.0.0.0 lo

and it worked...

Now the "route -n" shows the added loopback route..