SSHFS
Nick Edwards
nick.z.edwards at gmail.com
Thu Oct 14 04:19:23 UTC 2010
Hi,
Has anyone got this working from inside perl script successfully via cron ?
It works fine if I run it by hand, but doesn't do anything via cron.
strace shows connection reset by peer, but, tailing the server shows no
connections.
It is a key system and yes, I can happily ssh to the other pc without
password or any prompting.
Yes, they are fully pathed. I prefer use system(), it didn't work either,
but to get it to work I am using backticks with a simple ls, so I can see
when it works
getting the darn thing connecting properly, then i'll re-insert my "real
code" of what to do when it connects
I'm trying to remove the need to have a NFS mount all time, as if it goes
away, ubuntus task bar locks (thankfully I have a terminal icon so I can
"reboot")
I know it is going to be something simple, but i'm new to sshfs, and it just
loses the plot when run as a (root) cron job
#!/usr/bin/perl
use Sys::Syslog;
`/usr/bin/sshfs root\@lozza:/ /mnt/lozza`;
$result = `ls /mnt/lozza`;
syslog('info',"$result");
`/bin/fusermount -u /mnt/lozza`;
Nick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20101014/c66aa2de/attachment.html>
More information about the ubuntu-users
mailing list