- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Automate FTP
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 02:33 AM
тАО11-10-2005 02:33 AM
Re: Automate FTP
You will want filename expansion for the mget sequence.
This is a tricky one. I would have thought the 'newer' would work. This is how the MAN quotes it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 02:48 AM
тАО11-10-2005 02:48 AM
Re: Automate FTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 03:01 AM
тАО11-10-2005 03:01 AM
Re: Automate FTP
OK. It appears that 'mget' and 'newer' do not mix. 'newer' is a variation of the simple 'get'. Re-reading your original post, I see that you said, "...then the old one remains until the new arrives (different name each time)."
So, I assume that you don't know what the new file's name will be. I missed that the first time.
One workaround is to query the remote server for the file(s) you might find. You CAN use globbing to do this (e.g. 'ls /tmp/my*'). The file list so obtained must be written to a file on the local server. Then, have your script start a second 'ftp' session with the remote server to perform either 'get filename' or 'newer filename' to transfer the *exact* file of interest.
I have used this technique of runnning a query of a directory on a remote server; building an indexed list for a user; and then allowing the user to see and select files by that index in a second menu driving a second 'ftp' session.
BTW, "globbing" is the term used to describe the shell's expansion of filenames based on metacharacter notation (e.g. 'ls my*' would return all files beginning with "my").
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 03:18 AM
тАО11-10-2005 03:18 AM
Re: Automate FTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 03:30 AM
тАО11-10-2005 03:30 AM
Re: Automate FTP
Anyway, the final part of my problem is how to send out an email if it actually downloads a file. No email is needed, of course, if it finds nothing, but if it does find something and downloads, I need an email.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 03:37 AM
тАО11-10-2005 03:37 AM
Re: Automate FTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 03:53 AM
тАО11-10-2005 03:53 AM
Re: Automate FTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-10-2005 07:28 AM
тАО11-10-2005 07:28 AM
Re: Automate FTP
Thanks for all the help everyone.
- « Previous
- Next »