Solved

FTP DIR list with and without Year and/or Time

Posted on 2000-03-03
3
484 Views
Last Modified: 2008-03-03
I use FTP sessions to a UNIX box to capture the Date/Time stamp of files for a monitoring application.  I use a DIR list which I belive is similar to an ls -l command.  UNIX for some reason gives me the Year if the file is older than I think 6 months and gives me the time if the file is younger than 6 months old.  This is causing processing problems with this application for year end processing and times when my monitoring system thinks it is just before midnight and the other system thinks it is just after midnight. (Due to systems being out of synch with their dates)

My question is this, do all or most unix system function this way (Showing time or year in the dir list)?
 And do they all use 6 months as the determination to display the time or year?
0
Comment
Question by:louy
3 Comments
 

Accepted Solution

by:
sivaran earned 100 total points
ID: 2581537
Yes all the unix m/c do give the time format in 'month date year' for
files which are > 6 months old.   Files  modified within six months show
`month date time'.  
0
 

Author Comment

by:louy
ID: 2581597
Is it 180 days they use or 182 or 183 for 1/2 of a year?
0
 
LVL 40

Expert Comment

by:jlevie
ID: 2586555
If you've got login privs on the remote (as opposed to anon ftp access) there are better, less ambiguous, ways to get the file dates. As to how the data/no date determination is done, well it depends on what ftp server is in use. I don't think it's documented for any of the servers (at least I've never seen such documentation).
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
sed -- search an replace multiple pattern 11 76
aix tls version 6 308
aix unix tar error 3 65
Adding a continue option in a script 9 39
Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question