I have added a python code in rc.local service to run on every bootup on my TX2. The code might throw errors and I would like to log them. Currently, I am doing this in my rc.local file:
/home/jetson/pythoncode.sh > /usr/tmp/debug.log 2>&1 & exit 0
In the above case, the log file is being generated, however, it is also getting overwritten on every boot up. I do not want the error log file to be overwritten for my application.
I have also tried:
/home/jetson/pythoncode.sh >> /usr/tmp/debug.log 2>&1 & exit 0
(In both cases, the last append sign I am using so that the booting doesn’t stop on the middle).
If it is not possible to have errors appended in the same file, I could also try any other method. I just want the error log file to have information about all session errors instead of the last/latest one.