Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

i need to have ftp transfer using ncftp, with crond that execute it. but it failed to work...

i tried with ncftp and ncftpput, and scripts works ok if start them manually, but failed when cron executed them.....

simple example is

[root@myserver sbin]# more mik.sh 
#!/bin/sh
/usr/local/bin/ncftpput -u remoteserver -p123 xxx.xxx.xxx.xxx /backup /tmp/backup.6558/*
[root@myserver sbin]# 

cron is defined like

* * * * * /usr/local/sbin/mik.sh

can you tell me where i'm wrong please....

tnx in adv!

share|improve this question

1 Answer 1

up vote 0 down vote accepted

ok, i make it. so, cron looks like:

0       2       *       *       *       /usr/local/sbin/mik.sh >/dev/null 2>&1

and in mik.sh i defined FULL path of ncftp, like /usr/local/bin/ncftp

tnx anw!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.