Tuesday, 10 September 2019

Troubleshooting cronjob

Plenty of times, perfectly working scripts can't seem to be executed properly when configured as cronjob. The annoying part is cron seem to only log the time when the script is executed and nothing else.

The solution is actually rather simple, just add the following lines to the end of your script
>/tmp/cronscript.log 2>&1

After the script is executed, you will be able to see the error messages

Hints: Most of the time, cron job is just missing the $PATH environment variable.

Cheers

Sunday, 8 September 2019

putty and ugly ncurses border

ncurses borders always appear nicely when logging in from any Linux system, however a lot of our customer is using putty on windows. When loading ncurses application like YasT, ncurses border usually appear as characters (l, q, k, x, m and j) and the nice ncurses will looks ugly. 

The fixed is actually quite simple, in putty configuration make sure you check "Enable VT100 line drawing even in UTF-8 mode"


Reconnect your ssh session and your ncurses border will be beautiful again. 

Cheers!!!