[quote="jeo"]The 'sed' command may be a good place to start. There are lots of options for search/replace and removing text selectively. Here's an example:
Code:
wendtj@HOUWENDTJ03>$ cat /tmp/example
this is line one
this is line two
this is line three
this is line four
this is line five
this is line six
wendtj@HOUWENDTJ03>$ sed '/this.is.line.four/d' /tmp/example
this is line one
this is line two
this is line three
this is line five
this is line six
that is a good ideea but , he is not removing the line two , if i look into example line is still there, i need it to be remove from file .i made a script to block a ip into firewall rules , and i whant to make one to be removed also but how to remove a line from a file? this is my problem.