LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 11-29-2012, 02:04 AM   #31
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751

That's because in lftp -c " some cmds" ; all cmds within " " MUST be lftp (sub) cmds. You can't insert bash cmds
 
Old 11-29-2012, 12:32 PM   #32
Ubunter
Member
 
Registered: Mar 2012
Posts: 36

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by chrism01 View Post
That's because in lftp -c " some cmds" ; all cmds within " " MUST be lftp (sub) cmds. You can't insert bash cmds
Thanks for your prompt Chris,
So, I have to setup another bash scrip to delete the older files, then I did, within the following line:
Quote:
lftp -c "open $ftphostname && user $ftpusername $ftppassword && find /backups/ -mtime +7 -delete {} \;"
where I still having the unknow command "mtime"...
 
Old 11-29-2012, 07:51 PM   #33
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
You've done exactly the same thing again; re-read my post above.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Setting up a cron for transferring a file through FTP at 5 PM daily arjundey AIX 26 11-18-2015 03:41 AM
Setting up a cron for transferring a file through FTP at 5 PM daily arjundey Programming 1 03-15-2012 01:43 PM
find and update an meeting date from daily schelude and send reminder to members smahb001 Linux - Newbie 4 02-06-2012 08:13 PM
Advice? Best way to move files daily to a daily "date" named directory ziphem Linux - Newbie 2 04-15-2007 08:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration