November 2012
M T W T F S S
 1234
567891011
12131415161718
19202122232425
2627282930  

Categories

November 2012
M T W T F S S
 1234
567891011
12131415161718
19202122232425
2627282930  

How to disable Core file generation Apache

First of all delete the core files which are preset on the server or under any account then

vi /etc/init.d/httpd

and below the “ulimit -n 16384? you need to put

ulimit -c 0

And Command to delete core files

#find ./ -name “core.*” -exec rm -f {} \;

Removing blank lines from a text file

Method 1: Using grep

$ grep -v ‘^$’ infile.txt > outfile.txt

Method 2: Using sed

$ sed ‘/^$/d’ infile.txt > outfile.txt

To remove blank lines from multiple files a script like the one below can be used

#!/bin/sh files=”/somefolder/*.txt” for f in $files do sed ‘/^$/d’ $f > $f.tmp mv $f.tmp $f done

GZIP COMMAND

Gzip is one of the frequent command used in linux . gzip command is use do to compression of a file for reducing size of file. This will saves the bandwidth if the file is transferring between different systems.Moreover the reduced size depends on the the content of the file, if the content is text, […]