Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ls -l won't give me seconds

Status
Not open for further replies.

lmcatech

Technical User
Jul 17, 2002
1
US
ls -l returns the file modify time only down to the minute. How can I get the modify time of a file as hour, minutes and seconds? I'm running Solaris 2.6. Thanks,
 
As far as I know ls -lt will only give modification times to the minute. I think I've seen a request similar to this in one of the forums on Tek-Tips, but I haven't been able to find it yet. I'll keep looking, but you could try searching the Solaris forum for words which might be associated with modifiaction times. Cheers.
 
Found it. Use:

truss -vlstat -tlstat ls -l <filename>

See Thread60-214609 for a fuller explanation. Cheers.
 
Hello !

JoseJ, this (
Code:
ls -lt
) does not seems to work.
From the man and the test I have done the -t option only sort the files by date instead of alphabetical order but does not display the seconds. I have tried on HP UX and Solaris 2.8. What Unix do you use ?
 
I use UNIX SCO 3.2v4.2. I thought that the command ls -lt could work
I am sorry

Saludos

JoseJ
 
I use UNIX SCO 3.2v4.2. I thought that the command ls -lt could work.
sorry

Saludos

JoseJ
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top