Cron <root@server> test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cro

allower

Verified User
Joined
Mar 27, 2008
Messages
29
Cron <root@server> test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cro

I get a error from custombuild.

Cron <root@server> test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )

/etc/cron.daily/custombuild:
/etc/cron.daily/custombuild: line 6: mail: command not found


And this line 6 in /etc/cron.daily/custombuild
./build versions | grep 'update is available.' | mail -s "${AVAIL_UPDATES} updates available for `hostname`" [email protected]

I tryed to use command mail but "command not found". Can i use exim here instead? or how can i correct this? Where is my mail command? I get this error mailed to my email.

Someone help me please? When I update DA I type ./build all. Is this correct or what is the correct way to update DA?

If someone could help me here with som information i would be very happy.


Thanks!
/Christian, Sweden.
 
what os are you using?

For reinstall software with custombuild you have to:

Code:
cd /usr/local/directadmin/custombuild
./build clean
./build update
./build all

For just update the new version you should run

Code:
cd /usr/local/directadmin/custombuild
./build clean
./build update
./build update_versions

For mail command i think is qmail you missing for the command, but, someone should confirm it cause im not sure

Hope it help :)
 
I'm using Debian 5. Can I just change mail to exim in /etc/cron.daily/custombuild?

I think I got this error after a update. I updated both Debian and DA

apt-get update
apt-get upgrade

and DA from Controlpanel.
 
You've got me incredibly confused because you shouldn't ever have had qmail listed in any custombuild file on your server.

Jeff
 
It's not qmail, it's just mail. (look at my first notice.)
How should a /etc/cron.daily/custombuild look like?


Thanks so far.
/Christian
 
Since when is there a /etc/cron.daily/custombuild?
 
I don't know, you tell me scsi. Your the professional :) I'm just sucking up all information trying to learn.

Here is the complete file if it helps. "/etc/cron.daily/custombuild"

Code:
#!/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} upda$
./build update_da
./build update_webapps
fi
exit 0;


Thank you guys for trying to help

/Christian
 
You've got me incredibly confused because you shouldn't ever have had qmail listed in any custombuild file on your server.
I was referring to user SeLLeRoNe into wrote:
For mail command i think is qmail you missing for the command, but, someone should confirm it cause im not sure

Jeff
 
The mail program should be part of any Linux/BSD system. It may not be in the correct path.

Search for an executable file named "mail" and post where you find it.

Jeff
 
Thanks the problem disappeared when I manually did
./build clean
./build update
./build update_versions

I haven't seen the problem since.

So problem solved, I think? :confused:

Thanks for all your help.

/Christian.
 
Hi there,

I got a similar problem, I get a mail (ever since I enabled the CustomBuild cron job) from cron saying:

Code:
/etc/cron.daily/custombuild:
PHP5 (CLI) 5.2.6 to 5.2.13 update is available.

That last line is included in the daily "[number] updates available for [host]" email as well by the way.
 
Just for others that might be looking for a fix for the above issue I posted, John just fixed it this week, the double email thing was due to a small bug in "./build update_webapps".
 
Code:
/etc/cron.daily/custombuild: line 6: mail: command not found

Still seeing this error on a brand new directadmin custombuild install after turning on the cron option in versions.cfg (which is completely up to date and tried build update/update version and the -d option)

Seems this is still a bug? Please let me know how to fix this.
 
Code:
root@webserver:~# apt-get install mailx
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package mailx is a virtual package provided by:
  mailutils 1:2.1+dfsg1-7
  heirloom-mailx 12.4-2
  bsd-mailx 8.1.2-0.20100314cvs-1
You should explicitly select one to install.

E: Package 'mailx' has no installation candidate

This doesn't work :( Why would I need to run another mail package btw just to ignore a error in the cron daily? My e-mail is working fine on this server, also these cron logs are being mailed..
 
Last edited:
Back
Top