Discussion:
[9fans] p9p vs. linux 9fs mount
(too old to reply)
dexen deVries
2013-04-04 13:59:33 UTC
Permalink
p9p/linux question.

i can't get seem to get write access to acme's files as mounted via linux 9p
driver (v9fs). read works OK, but writes are rejected.


# mount -t 9p '/tmp/ns.root.localhost:13/acme' /mnt/acme -o
'trans=unix,uname=root'
# ls /mnt/acme
1/ 2/ 3/ 4/ acme/ cons consctl draw/ editout index label new/
# echo delete > /mnt/acme/1/ctl
-bash: /mnt/acme/1/ctl: Permission denied


when mounted with debug=0x04, i see in dmesg that TRSTAT gets passed
`uname=root', but TWSTAT gets `uname=(null)'.


what am i doing wrong?


tested with linux kernel version 3.9.0-rc3 and 3.5.0 and with recent p9p
version.
--
dexen deVries

[[[↓][→]]]
erik quanstrom
2013-04-04 15:19:53 UTC
Permalink
Post by dexen deVries
p9p/linux question.
i can't get seem to get write access to acme's files as mounted via linux 9p
driver (v9fs). read works OK, but writes are rejected.
I understand my next question is not quite related, but do you need just to
mount Acme's file system or to mount the file system via v9fs?
Acme has an experimental feature to mount the file system via FUSE, and
this solution works almost without troubles, you need just to specify a
mount point with flag '-m'.
guess. try >> instead of >. > may try to remove the file first.

- erik
dexen deVries
2013-04-04 15:37:16 UTC
Permalink
Post by erik quanstrom
guess. try >> instead of >. > may try to remove the file first.
...

how do i send you cookies? ;-)


# strace for `>'
open("/mnt/acme/2/ctl", O_WRONLY|O_CREAT|O_TRUNC|O_LARGEFILE, 0666) = -1
EACCES (Permission denied)

# strace for `>>'
open("/mnt/acme/2/ctl", O_WRONLY|O_CREAT|O_APPEND|O_LARGEFILE, 0666) = 3

with the difference being `O_TRUNC'.


cheers,
--
dexen deVries

[[[↓][→]]]
Alexander Sychev
2013-04-04 15:13:06 UTC
Permalink
Hi,
Post by dexen deVries
p9p/linux question.
i can't get seem to get write access to acme's files as mounted via linux 9p
driver (v9fs). read works OK, but writes are rejected.
I understand my next question is not quite related, but do you need just to
mount Acme's file system or to mount the file system via v9fs?
Acme has an experimental feature to mount the file system via FUSE, and
this solution works almost without troubles, you need just to specify a
mount point with flag '-m'.
--
Best regards,
santucco
Loading...