Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sub-second timestamp seems variable, random? #132

Open
tomjridge opened this issue Sep 18, 2017 · 0 comments
Open

Sub-second timestamp seems variable, random? #132

tomjridge opened this issue Sep 18, 2017 · 0 comments

Comments

@tomjridge
Copy link

Running main.native server, mounting with Ubuntu 16.04.2 kernel 9p client:

 sudo mount -t 9p -o trans=tcp,port=5640,dfltuid=5945,dfltgid=5945 127.0.0.1 /mnt/9p

Consecutive stats are OK, except for access/modify/change times which are seemingly random. For example, two consecutive stats:

$ mnt $ stat 9p/tmp.txt 
  File: 9p/tmp.txt
  Size: 141       	Blocks: 1          IO Block: 8192   regular file
Device: 100085h/1048709d	Inode: 1357078     Links: 1
Access: (0660/-rw-rw----)  Uid: ( 5945/    tr61)   Gid: ( 5945/    tr61)
Access: 2017-09-18 12:09:03.655666165 +0100
Modify: 2017-09-18 12:09:01.655666165 +0100
Change: 2017-09-18 12:09:01.655666165 +0100
 Birth: -

# (h:pc1177) (p:/mnt) (d:/dev/sda2)  
$ mnt $ stat 9p/tmp.txt 
  File: 9p/tmp.txt
  Size: 141       	Blocks: 1          IO Block: 8192   regular file
Device: 100085h/1048709d	Inode: 1357078     Links: 1
Access: (0660/-rw-rw----)  Uid: ( 5945/    tr61)   Gid: ( 5945/    tr61)
Access: 2017-09-18 12:09:03.775758325 +0100
Modify: 2017-09-18 12:09:01.775758325 +0100
Change: 2017-09-18 12:09:01.775758325 +0100
 Birth: -

Intentional behaviour? Or bug?

lofs9p.ml has the following:

  let set_times path atime mtime =
    (* TODO: this can block on Unix.utimes and we shouldn't but
       Lwt_unix does not yet wrap Unix.utimes. *)
    (* NOTE: The behavior of this is slightly wrong as 'any' means
       "don't change" but 0 means "set to now". *)

but we are not setting, only reading (?) so this shouldn't matter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant