Re: Can cron jobs share ssh-agent?

From: Neil W Rickert (rickert+nn_at_cs.niu.edu)
Date: 05/21/03


Date: 21 May 2003 12:17:28 GMT


"Joe Harrison" <joe.harrison@teamware.antisp4m.co.uk> writes:

>However even typing up-arrow / return every day can be too arduous for us
>notoriously bone-idle lollygagging sysadmins :) and I would really like to
>run it completely unattended as a cron job.

If ssh-agent is already running, your cron job need only define
SSH_AUTH_SOCK in the environment to the appropriate value. When you
startup ssh-agent, you could put that info into a file for your cron
script to use.



Relevant Pages

  • Re: Connect DB2 environment setting problem
    ... I execute the program by command line is OK, ... Connection failed with error: Total Environment allocation failure! ... Did you set up your DB2 client environment? ... the necessary variables in the cron job. ...
    (comp.lang.perl.misc)
  • Re: install_driver(Oracle) failed: wrong ELF class: DynaLoader.pm
    ... platforms (linux, solarias 8/9). ... if i run it as a cron job i get: ... cron does not set the environment, so you must do so for it. ... Install 32-bit Perl or 64-bit client libraries. ...
    (perl.dbi.users)
  • Re: How to debug cron jobs?
    ... the environment under which the cron job will run. ... Run the same command with the environment set the way cron does, ...
    (comp.unix.shell)
  • Re: CRON Script not working right.
    ... Most often this is because the environment in the cron job is ... command line, then compare the two. ...
    (freebsd-questions)
  • Re: odd persistent environmental bug
    ... of assuming that using sudo gave me a 'clean environment'. ... not sure what the 'clean environment' is that I should be restarting it ... For both cron and inetd, normally just a minimal path and TZ/Locale ... If you have another Sun box that's not hosed, just set up a cron job ...
    (comp.unix.solaris)