9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Re: [9fans] wstat and atomic directory change
@ 2015-02-05  4:26 sl
  2015-02-05  8:08 ` Giacomo Tesio
  0 siblings, 1 reply; 28+ messages in thread
From: sl @ 2015-02-05  4:26 UTC (permalink / raw)
  To: 9fans

> But why we don't have Tmove for example?

http://9front.org/img/tmove.jpg

sl



^ permalink raw reply	[flat|nested] 28+ messages in thread
* Re: [9fans] wstat and atomic directory change
@ 2015-02-05  4:26 sl
  0 siblings, 0 replies; 28+ messages in thread
From: sl @ 2015-02-05  4:26 UTC (permalink / raw)
  To: 9fans

> But why we don't have Tmove for example?

http://9front.org/img/9tmove01.png

sl



^ permalink raw reply	[flat|nested] 28+ messages in thread
* [9fans] wstat and atomic directory change
@ 2015-01-30 11:21 Giacomo Tesio
  2015-01-30 14:13 ` erik quanstrom
  0 siblings, 1 reply; 28+ messages in thread
From: Giacomo Tesio @ 2015-01-30 11:21 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

[-- Attachment #1: Type: text/plain, Size: 1504 bytes --]

Hi, I'm wondering about the validity of an interpretation of intro(5) and
stat(5) that could allow a server to atomically change the directory of a
file.

>From intro(5) <http://man.cat-v.org/9front/5/intro>

The notation
string[s] (using a literal s character) is shorthand for
s[2] followed by s bytes of UTF-8 text.  (Systems may choose
to reduce the set of legal characters to reduce syntactic
problems, for example to remove slashes from name compo-
nents, *but the protocol has no such restriction*.  Plan 9
names may contain any printable character (that is, any
character outside hexadecimal 00-1F and 80-9F) except
slash.).


 wstat(5) <http://man.cat-v.org/9front/5/stat> on the other hand does not
say much about the name field of Fcall:

The name can be changed by anyone with write
permission in the parent directory; it is an error to change
the name to that of an existing file.

Now, since the protocol does not restrict names (even if Plan 9 does it),
I'm wondering if setting the name to a full path starting from root could
be used to change atomically the directory of a file (given the write
permission on both original and target directory).

Obviously I'm not referring to Plan 9 file servers (I guess this would be a
non retrocompatbile change), but I'm considering if such interpretation
would be wrong (according to the official specifications).

A server supporting such behaviour could be considered a 9p2000 conformant
server?


Giacomo

[-- Attachment #2: Type: text/html, Size: 1982 bytes --]

^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2015-02-05 17:22 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-05  4:26 [9fans] wstat and atomic directory change sl
2015-02-05  8:08 ` Giacomo Tesio
  -- strict thread matches above, loose matches on Subject: below --
2015-02-05  4:26 sl
2015-01-30 11:21 Giacomo Tesio
2015-01-30 14:13 ` erik quanstrom
2015-01-30 15:59   ` Giacomo Tesio
2015-01-30 20:19     ` Joel C. Salomon
2015-01-30 22:49     ` Anthony Sorace
2015-02-03  8:53       ` Giacomo Tesio
2015-02-03  9:04         ` Quintile
2015-02-04  3:51           ` erik quanstrom
2015-02-04  8:28             ` Giacomo Tesio
2015-02-04 14:06               ` erik quanstrom
2015-02-04 14:29                 ` Giacomo Tesio
2015-02-04 16:30                   ` Skip Tavakkolian
2015-02-04 19:23                     ` erik quanstrom
2015-02-04 21:24                       ` Giacomo Tesio
2015-02-05  4:13                         ` lucio
2015-02-05  8:21                           ` Giacomo Tesio
2015-02-05  8:37                             ` Giacomo Tesio
2015-02-05  8:59                               ` lucio
2015-02-05  8:54                             ` lucio
2015-02-05 16:13                               ` erik quanstrom
2015-02-05  4:15                         ` lucio
2015-02-05 16:20                         ` erik quanstrom
2015-02-05 16:46                           ` Giacomo Tesio
2015-02-05 17:22                             ` Skip Tavakkolian
2015-02-05 17:20                           ` Bakul Shah

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).