>For some strange reason, cron has stopped running Amdump for me at
>night.  ...
>Here is Amanda's crontab:
>0 16 * * 1-5    /usr/sbin/amcheck -m BIG1
>45 0 * * 2-6    /usr/sbin/amdump BIG1

Here are some debugging things I would try:

  * Change the amdump line to something like this:
  
    45 0 * * 2-6    echo Starting amdump ; /usr/sbin/amdump BIG1 ; echo amdump status: 
$?

    This will generate some output to stdout which, in theory, cron should
    E-mail to the crontab owner ("amanda" in your case).  If you don't
    get that E-mail, then you may not have mail set up properly for that
    user on that machine (e.g. you need an aliases entry or something
    like that).  You may even find the E-mail has been accumulating
    someplace you didn't expect :-).

  * Another alternative:

    45 0 * * 2-6    /bin/sh -x /usr/sbin/amdump BIG1 > /tmp/amdump.$$ 2>&1

    This will run amdump via sh with the "trace" (-x) flag set.  Two
    things will happen.  First, you should get the /tmp/amanda.$$ file
    created.  If you don't then I don't think cron actually tried to run
    the process (or it died before ever getting started for some reason).

    If you do get the /tmp/amdump.$$ file, take a look at it and see if
    it has anything interesting to say about why amdump bailed out.

  * Another possibility would be to temporarily change your crontab
    entry to start a couple of minutes from now and then run strace
    on cron itself to watch it start amdump.  You probably want -f to
    follow forks and "-o output-file" to save the output someplace as
    it may be large.

>I changed group permissions for Amanda about a week ago.  ...

It's possible cron has cached some information about the Amanda user.
You might try re-submitting the crontab to (hopefully) make it refresh
things.  If that doesn't help, you might stop and restart cron.

You might also check the "amanda" home directory and shell to see if
they are valid.  This would be a quick test (as root):

  su - amanda -c pwd

The first '-' tells "su" to set up the environment as though the user
had logged in, which is closer to what cron does than "su amanda -c ...".

>Karl Bellve

John R. Jackson, Technical Software Specialist, [EMAIL PROTECTED]

Reply via email to