- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Change time change?
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
тАО01-29-2007 08:10 AM
тАО01-29-2007 08:10 AM
I am very confused. I am updating a file inside a
Perl program and both the file change time and the modification time are being updated. I thought the change time was only supposed to change when the permissions or owner were changed.
Thanks,
Chad
Solved! Go to Solution.
- Tags:
- creation time
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2007 08:13 AM
тАО01-29-2007 08:13 AM
Solution- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2007 08:14 AM
тАО01-29-2007 08:14 AM
Re: Change time change?
't make the UNIX rules and this one is pretty dumb.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2007 08:54 AM
тАО01-29-2007 08:54 AM
Re: Change time change?
Thanks. That explains it. I was hoping to be able to use the change time as a creation time since I never was going to change the ownership or permissions of the files. Any ideas on how to capture the creation time of a file?
Thanks,
Chad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2007 09:00 AM
тАО01-29-2007 09:00 AM
Re: Change time change?
II) Get used to disappointment. See 1) above.
C) Use another file to record the creation time of the file that you are interested in.
Four) Use your convention but preallocate the file so that the length doesn't change. However, one chmod or chown and see 1) above.
------------------------------------------
The least evil of these is C) --- although it isn't foolproof. You might adopt a convention such that myfile.data is matched to myfile.ts (for timestamp).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2007 09:04 AM
тАО01-29-2007 09:04 AM
Re: Change time change?
Unis doesn't track a true creation time. When a file is first entered into a directory, its 'mtime' (modification) timestamp represents a creation time. As long as the file remains unmodified (metadata aside, as reflected in the 'ctime') then you can consider the 'mtime' to be a creation timestamp. However, any data change updates the 'mtime', obliterating the moment of creation. See the 'stat(2)' manpages for more information.
Beware that many backup utilities reset a file's last accesstime ('atime'). One such is 'fbackup'. While this is a seperate timestamp from the 'mtime', resetting the 'atime' *does* change the 'ctime'. Thus, it becomes virtually impossible, other than by documentation or tracking in your own database, to track anything like a creation timestamp in Unix.
Regards!
...JRF...
Regards!
...JRF...