3
votes
3answers
1k views

limiting size of logfile from a variable

How can I limit the size of a log file, which is saved in the form of 'foo.txt', from within a bash script please? I want to put in the variables 'LOGFILE=50 mb' and it uses that size, or whatever ...
10
votes
5answers
8k views

How to limit log file size using >>

How can I limit the size of a log file written with >> to 200MB? $ run_program >> myprogram.log