Bug 666403 - mailx breaks atime with mbox on encfs filesystem
Summary: mailx breaks atime with mbox on encfs filesystem
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: mailx
Version: 16
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
Assignee: Peter Schiffer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 782068
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-12-30 14:30 UTC by jurek.bajor
Modified: 2013-02-14 02:44 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-02-14 02:44:16 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description jurek.bajor 2010-12-30 14:30:43 UTC
Description of problem:

The objective is to test time attributes of non-encrypted (ext4 fs) and
encfs-encrypted files depending on who created/acted upon them.

Non-encrypted (ext4 fs) files test.
-----------------------------------

$ df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/sda7             14420896   6992248   7282168  49% /
tmpfs                  1025992       428   1025564   1% /dev/shm

$ cat /proc/mounts
...
tmpfs /dev/shm tmpfs rw,relatime 0 0
/dev/sda7 / ext4 rw,relatime,barrier=1,data=ordered 0 0

Note: relatime - default mount option

/home/jb/file1.txt       - file acted upon by myself
/home/jb/my-mbox         - file acted upon by mailx's 'save' command 

- I created/acted upon a file file1.txt

  Initial file creation:
  $ touch file1.txt
  $ ls -lc file1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 10:31 file1.txt
  $ ls -l file1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 10:31 file1.txt
  $ ls -lu file1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 10:31 file1.txt

  Now file is appended with text:
  $ echo "append" >> file1.txt 
  $ ls -lc file1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 10:34 file1.txt
  $ ls -l file1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 10:34 file1.txt
  $ ls -lu file1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 10:31 file1.txt

  Result: only ctime and mtime changed - as expected.

- mailx's 'save n /home/jb/my-mbox' created/acted upon a file my-mbox

  Initial my-mbox file creation by mail client's save command:
  $ ls -lc my-mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 10:39 my-mbox
  $ ls -l my-mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 10:39 my-mbox
  $ ls -lu my-mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 10:39 my-mbox

  After my-mbox appended with mail message by mail client's save command:
  $ ls -lc my-mbox 
  -rw-rw-r-- 1 jb jb 1556 Dec 30 10:43 my-mbox
  $ ls -l my-mbox 
  -rw-rw-r-- 1 jb jb 1556 Dec 30 10:43 my-mbox
  $ ls -lu my-mbox 
  -rw-rw-r-- 1 jb jb 1556 Dec 30 10:39 my-mbox

  Result: only ctime and mtime changed - as expected.

encfs-encrypted files test.
---------------------------

$ encfs ~/.crypt-raw ~/mbox

$ df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/sda7             14420896   6992248   7282168  49% /
tmpfs                  1025992       428   1025564   1% /dev/shm
encfs                 14420896   6992248   7282168  49% /home/jb/mbox

$ cat /proc/mounts
...
tmpfs /dev/shm tmpfs rw,relatime 0 0
/dev/sda7 / ext4 rw,relatime,barrier=1,data=ordered 0 0
encfs /home/jb/mbox fuse.encfs
rw,nosuid,nodev,relatime,user_id=500,group_id=500,default_permissions 0 0

Note: relatime - default mount option

/home/jb/mbox/             - mountpoint dir
/home/jb/mbox/test1.txt    - file acted upon by myself
/home/jb/mbox/mbox         - file acted upon by mailx's 'save' command 

- I created/acted upon a file test1.txt

  Initial file creation:
  $ touch mbox/test1.txt
  $ ls -lc mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 11:00 mbox/test1.txt
  $ ls -l mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 11:00 mbox/test1.txt
  $ ls -lu mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 0 Dec 30 11:00 mbox/test1.txt

  Now file is appended with text:
  $ echo "append" >> mbox/test1.txt 
  $ ls -lc mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 11:02 mbox/test1.txt
  $ ls -l mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 11:02 mbox/test1.txt
  $ ls -lu mbox/test1.txt 
  -rw-rw-r-- 1 jb jb 7 Dec 30 11:00 mbox/test1.txt

  $ ls -al .crypt-raw/
  total 24
  drwx------   2 jb jb  4096 Dec 30 11:00 .
  drwx------. 56 jb jb 12288 Dec 30 11:03 ..
  -rw-rw-r--   1 jb jb  1076 Dec 29 21:58 .encfs6.xml
  -rw-rw-r--   1 jb jb    15 Dec 30 11:02 NN-MKpwsiu50nui4b9XByy5C

  Result: only ctime and mtime changed - as expected.

- mailx's 'save n /home/jb/mbox/mbox' created/acted upon a file mbox

  Initial mbox file creation by mail client's save command:
  $ ls -lc mbox/mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 11:07 mbox/mbox
  $ ls -l mbox/mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 11:07 mbox/mbox
  $ ls -lu mbox/mbox 
  -rw-rw-r-- 1 jb jb 773 Dec 30 11:07 mbox/mbox

  After mbox appended with mail message by mail client's save command:
  $ ls -lc mbox/mbox 
  -rw-rw-r-- 1 jb jb 1546 Dec 30 11:11 mbox/mbox
  $ ls -l mbox/mbox 
  -rw-rw-r-- 1 jb jb 1546 Dec 30 11:11 mbox/mbox
  $ ls -lu mbox/mbox 
  -rw-rw-r-- 1 jb jb 1546 Dec 30 11:11 mbox/mbox

  $ ls -al .crypt-raw/
  total 28
  drwx------   2 jb jb  4096 Dec 30 11:07 .
  drwx------. 56 jb jb 12288 Dec 30 11:12 ..
  -rw-rw-r--   1 jb jb  1076 Dec 29 21:58 .encfs6.xml
  -rw-rw-r--   1 jb jb  1554 Dec 30 11:11 KvMcK-a1xgrvB36y5ebYEv7q
  -rw-rw-r--   1 jb jb    15 Dec 30 11:02 NN-MKpwsiu50nui4b9XByy5C

  Result: ctime, mtime, and atime changed - NOT as expected.

Conclusion:
On Linux, with file systems mounted with default mount option 'relatime',
with mbox on an encrypted file system (encfs), mailx deviates from conventional
rules of file times modifications.
This will cause some applications (like mutt mail client) that rely on mbox's
file times attributes to not work properly.

Version-Release number of selected component (if applicable):

I have tested it on Fedora 14.

Heirloom Mail version 12.5 7/5/10.
$ yum list installed mailx
mailx.i686                         12.5-1.fc14                        @updates

$ yum list installed fuse-encfs
fuse-encfs.i686                       1.7.2-1.fc14                    @fedora

How reproducible:

as above test plan

Steps to Reproduce:
1. as above test plan
2.
3.
  
Actual results:

as above test plan

Expected results:

as above test plan

Additional info:

This problem with atime has been initially reported for procmail:
see thread
http://lists.fedoraproject.org/pipermail/users/2010-December/389644.html

Comment 1 Fedora Admin XMLRPC Client 2011-07-12 11:43:36 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 2 Fedora End Of Life 2012-08-16 19:51:16 UTC
This message is a notice that Fedora 14 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 14. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained.  At this time, all open bugs with a Fedora 'version'
of '14' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this 
occurring, but we forgot to do that. A thousand apologies.)

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, feel free to reopen 
this bug and simply change the 'version' to a later Fedora version.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we were unable to fix it before Fedora 14 reached end of life. If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora, you are encouraged to click on 
"Clone This Bug" (top right of this page) and open it against that 
version of Fedora.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 3 Fedora End Of Life 2013-01-17 01:21:06 UTC
This message is a reminder that Fedora 16 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 16. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '16'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 16's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 16 is end of life. If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora, you are encouraged to click on 
"Clone This Bug" and open it against that version of Fedora.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 4 Fedora End Of Life 2013-02-14 02:44:19 UTC
Fedora 16 changed to end-of-life (EOL) status on 2013-02-12. Fedora 16 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.