Very odd 'user not found' messages

disoft

Verified User
Joined
Jun 4, 2003
Messages
28
Location
UK
I added a domain name to one of my DA accounts and then added a few pointers for that domain name.

Now I think the above may be a red herring, but I've mentioned it because it's the only thing I've done.

Now, however, all the cron jobs seem to be failing with:

root: not found

Or

anyuser: not found

Examples of cron jobs failing are:

- dataskq
- atrun
- newsyslog

The users in question do exist because I can login as them and have domains under them which work okay, it just appears that cron can't seem to make itself that user at the command line from within crontab. Executing the commands directly from the command (without the user specification on the front) works okay.

Tried removing the domain and pointers, but that didn't make any difference.

Tried a reboot too, but that didn't help either.

I'd be grateful if anyone has any ideas or has seen this before. As I said, it's possible that the adding of the new domain isn't responsible and that it isn't a DA problem, but I'm starting out by looking at the most recent likely cause.

OS is FreeBSD 4.10.
 
Well this is bizarre.

Take, for example, the following crontab entry:

Code:
#
#minute hour    mday    month   wday    who     command
#
*/5     *       *       *       *       root    /usr/libexec/atrun
#

It's no longer reading 'root' as a userid under which it should run, but it's reading it as part of the path name, so it's trying to find 'root/usr/libexec/atrun' to run, which of course it can't.

A lot of config files are tab/space sensitive I know, but (a) this hasn't been changed for a while and (b) restoring an old one that's known to work doesn't help.
 
Figured out what's happening here.

Somehow the system crontab in /etc/crontab was also a user crontab in /var/cron/tabs, so everything was trying to run twice. The user version of it was failing because the 'who' field is invalid in user crontabs.

What I don't understand is how the 'crontab /etc/crontab' command was run to create it as a user crontab in the first place. I'm presuming there must be some utility on the box somewhere that runs that command, so I'll try to track it down.
 
Back
Top