custombuild cron sending jibberish

Duboux

Verified User
Joined
Apr 20, 2007
Messages
264
Since a few days the custombuild cron is sending me jibberish between words.
I also see arrow's which don't show up here.

[1mDovecot 2.0.9 to 2.0.11 update is available. (B [m [1mMySQL 5.1.55 to 5.1.56 update is available. (B [m
 
Those are ascii escape sequences, most likely to change the color or font attribute (bold). You should be able to ignore it or I think if you just change bold=yes to bold=no in your options.txt file and rerun the './build cron' command that will remove those sequences from the cronjob.
 
In FreeBSD bold should be set to no. I did not learn details, but in my experience, bold does not work in FreeBSD 5/6/7 (never tried Directadmin with FreeBSD 8).
 
It may not work on FreeBSD, but there isn't any check in custombuild/build to turn it off if you are on FreeBSD. It defaults to on and unless you modify it in your options.txt then it will use the bold as defined by:
Code:
# Variables for bolded text
boldon=""
boldoff=""
if [ "${BOLD_OPT}" = "yes" ]; then
        boldon="`tput -Txterm bold`"
        boldoff="`tput -Txterm sgr0`"
fi
 
OK, with the email notifications. I've got the issue with CentOS 5:

[1mPHP5 (CGI) 5.2.9 to 5.2.17 update is available.(B[m

It seems to be a bug, that needs to be fixed.
 
Hello,

Thanks for the report. I've added a fix which does not use bold for cron, but it will require you reinstall the cronjob. To do so, run:
Code:
./build update
./build cron
This will use the new function "./build versions_nobold" instead of "./build versions", thus.. no bold in the email. It changes /etc/cron.daily/custombuild.

John
 
mmmh looking at cron line (removed before upgrade)

Code:
>cat /etc/cron.daily/custombuild
#!/bin/sh
cd /usr/local/directadmin/custombuild
./build update >/dev/null 2>&1
AVAIL_UPDATES="`./build versions | grep -c -e 'update is available.'`"
if [ "${AVAIL_UPDATES}" -gt 0 ]; then
./build versions | grep 'update is available.' | mail -s "${AVAIL_UPDATES} updates available for `hostname`" [email protected]
fi
exit 0;

Seems that still call versions wihout _nobolds option

Regards
 
John once said, it takes up to 24 hours for all mirrors to get synced. So just wait a bit.... and later we will see.
 
Right, just select files.directadmin.com in options.conf and do the update.. then restore the previous doing
Code:
./build set_fastest

Regards :)
 
Back
Top