The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > The UNIX Forums - Contact Us > Post Here to Contact Site Administrators and Moderators
Google UNIX.COM


Post Here to Contact Site Administrators and Moderators Make Suggestions About Forums, Features, or Content here. Discuss Rules and Guidelines. Get Forum Support Here. (Registered Users Only)

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
ftp command to get latest file laiko UNIX for Dummies Questions & Answers 2 05-14-2008 03:10 AM
how can i pick the latest log file as per below mail2sant Shell Programming and Scripting 1 04-05-2008 05:29 AM
Getting latest file from ftp arunavlp UNIX for Dummies Questions & Answers 3 02-08-2008 07:19 AM
want to cat the latest log file created vkandati UNIX for Dummies Questions & Answers 1 03-08-2005 03:13 PM
get latest file inquirer Shell Programming and Scripting 3 07-06-2003 09:44 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 01-25-2006
alx alx is offline
Registered User
 

Join Date: Jan 2006
Posts: 9
get latest file via ftp command

Hi,

The task that I need to do is connect from Unix box to Windows server and get the latest *.txt file (there might be several files in a directory on Windows server). From what I understand ftp does not allow to pass "ls -lt" and therefore I am unable to determine which file is the latest and therefore the one I need to get.
Another option is to bring all *.txt files from Windows into Unix box - but this way the files loose their time stamp and I am still unable to determine which file is the latest.
Any help will be greatly appreciated
Reply With Quote
Forum Sponsor
  #2  
Old 01-26-2006
RTM's Avatar
RTM RTM is offline
Hog Hunter
 
Join Date: Apr 2002
Location: On my motorcycle
Posts: 3,039
Since I don't have a Windows system running ftp, I can't check this but normally, ftp has two commands to show a directory and files, dir and ls.

ls will show just files.

dir will show files with timestamps. A quick test shows that it is the modified timestamp - maybe this will help.
Reply With Quote
  #3  
Old 01-26-2006
alx alx is offline
Registered User
 

Join Date: Jan 2006
Posts: 9
Thank you very much
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 08:55 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0