|
|
Log in / Subscribe / Register

Garrett: ext4, application expectations and power management

Garrett: ext4, application expectations and power management

Posted Mar 16, 2009 8:46 UTC (Mon) by gdt (subscriber, #6284)
In reply to: Garrett: ext4, application expectations and power management by flewellyn
Parent article: Garrett: ext4, application expectations and power management

So how do you propose to retain ownership, permission bits, creation time and other attributes? Or is your's one of those annoying applications which alter the permissions that I set manually?


to post comments

Garrett: ext4, application expectations and power management

Posted Mar 16, 2009 14:40 UTC (Mon) by flewellyn (subscriber, #5047) [Link] (3 responses)

Reading the ownership, permissions, and other attributes from the existing file is not an onerous task. As for creation time, if it's a config file in the "one setting per file" mode, that really doesn't need to be preserved.

Garrett: ext4, application expectations and power management

Posted Mar 16, 2009 15:40 UTC (Mon) by cortana (subscriber, #24596) [Link] (2 responses)

It is very onorous!

You have to replicate *all* of the following!

* user and group owner
* mode
* ACLs
* XFS ACLs (it uses its own non-posix API I think)
* attributes (some of which only root may set)
* extended attributes (some of which only root may set, and some of which only root may read!)
* user extended attributes
* XML user extended attributes (again, it uses its own non-posix API)
* reiserfs extended attributes (again, I believe it uses its own non-posix API. And probably reiser3 and reiser4 use different APIs...)

And this is just for apps for Linux. If you want your program to run on Windows, Mac OS X, FreeBSD, etc. etc., you have an entirely different set of tasks to perform...

Garrett: ext4, application expectations and power management

Posted Mar 17, 2009 12:13 UTC (Tue) by nye (guest, #51576) [Link] (1 responses)

Surely you can make a copy of the file and truncate that - or am I being naive?

Garrett: ext4, application expectations and power management

Posted Mar 17, 2009 13:23 UTC (Tue) by cortana (subscriber, #24596) [Link]

Is there a system call to duplicate a file and all those properties?


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds