shell script newbie question
i have a file in /proc directory that stores some tcp parameters.............i heard that files in /proc directory has a 1 page size limit
how do i want to write a shell script that reads the proc file from time to time and save it as a text file, and then read some more and append whatevers new to the text file?
the file format of /proc/tcp_parameters is:
2 3 4
3 5 5
6 5 3
...
i want to read the proc file, then store it as a text file
then sometime later, like 1 or 2 sec later, read the file again and apend whatevers new to the txt file?
i tried doing
cat tcp_parameters > /home/tcpvars
but i have no idea how do deal with the time issue, and the '>' overwrites everything instead of appending
thanks in advance
|