LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-02-2009, 04:58 PM   #1
snail
LQ Newbie
 
Registered: Jun 2009
Posts: 2

Rep: Reputation: 0
Question File creation date of vfat / fat32 files on linux


I have a vfat USB drive mounted on linux as vfat.
Since the vfat / fat32 timestamps also have a file creation time, is there any way to get the file creation time for all files on the USB ?
I tried using the FAT_IOCTL_GET_ATTRIBUTES ioctl which returns the dos attributes.
However I did not get any system call / ioctl / tool which will read the dos timestamps in linux.
 
Old 06-03-2009, 03:55 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Isn't it just a conceptual case of MAC times being handled differently? Doesn't 'stat -c "%Z %N" /path/to/file' return a ctime value which VFAT and NTFS use as creation time?
 
Old 06-03-2009, 12:37 PM   #3
snail
LQ Newbie
 
Registered: Jun 2009
Posts: 2

Original Poster
Rep: Reputation: 0
No it does not.
From my windows box when I checked the creation time of the file on the USB it gave this -- Tue May 26 13:33:49 PDT 2009

And none of the timestamps returned by the stat match this --
stat download.JPG
File: `download.JPG'
Size: 223271 Blocks: 440 IO Block: 4096 regular file
Device: 801h/2049d Inode: 28 Links: 1
Access: (0777/-rwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2009-05-26 13:37:47.000000000 -0700
Modify: 2009-05-26 13:37:47.000000000 -0700
Change: 2009-06-03 10:31:13.000000000 -0700
 
Old 06-03-2009, 05:56 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
When I do a 'stat' on a file on a VFAT USB stick and run a forensic imager they both show the same MAC times.
Without more details from you there's not much else to help you with I think.
 
  


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
File creation date Jay5487 Linux - Newbie 2 03-25-2008 07:47 AM
Listing of files on creation date ZAMO Linux - General 1 01-25-2008 06:45 AM
file creation date prashantbhushan Linux - General 2 05-29-2007 08:32 AM
File Creation Date in linux jayukanna General 5 08-21-2006 07:08 AM
ls -al file creation date blackzone Linux - Newbie 2 08-23-2004 01:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:56 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