Discussion:
[9fans] I found this discussion pretty funny
(too old to reply)
dexen deVries
2012-10-17 13:49:41 UTC
Permalink
get to the part about why it's so great that pipe is a system call,
not a device.
This is the sort of back-and-forth that reminds me why I can't quite
give up on plan 9 ...
http://yarchive.net/comp/linux/everything_is_file.html
"Do we create pipes by opening /dev/pipe? No. "
and
"Yes, some old-timers could argue that original UNIX didn't have sockets,
and that the BSD interface is ugly and an abomination and that it _should_
have been a namespace thing, but that argument falls flat on its face when
you realize that the "pipe()" system call _was_ in original UNIX, and has
all the same issues."
ah well. It seems that the guy who wrote pipe() might not agree that
he does not know much about Unix ... but so it goes.
a technical and organizational problem: back then Linux' /dev consisted of
special files held on drive, its MAJOR/MINOR schema* getting dangerously
cramped.

those days Linux' /dev is usually mounted at boot and maintained by kernel,
somewhat alike /proc; adding some more entries probably isn't that much of a
problem.
--
dexen deVries

[[[↓][→]]]

* MAJOR/MINOR being an unmountable namespace is quite ironic.
erik quanstrom
2012-10-17 13:47:05 UTC
Permalink
"Yes, some old-timers could argue that original UNIX didn't have sockets,
and that the BSD interface is ugly and an abomination and that it _should_
have been a namespace thing, but that argument falls flat on its face when
you realize that the "pipe()" system call _was_ in original UNIX, and has
all the same issues."
appeal to the authority of the unix authors as a defense of sockets?
surely someone has missed a bit.

or another way, since the original was broken, we must not work correctly?

i'm tempted to draw one of those ascii slashdot memes

unix →

\o/
|
/\

woosh!

- erik
c***@gmx.de
2012-10-17 14:23:23 UTC
Permalink
whats the issue? plan9 has a syscall to create anonymous pipes:

#define PIPE 21

--
cinap
Charles Forsyth
2012-10-17 16:31:29 UTC
Permalink
but that just turns round and uses the name space (like a few other system
calls).
c***@gmx.de
2012-10-17 18:28:32 UTC
Permalink
yeah, like mount... its files all the way down :)

linux is like windows... everything is a HANDL^Wfiledescriptor

--
cinap
Francisco J Ballesteros
2012-10-17 19:47:51 UTC
Permalink
did you notice the discussion was from this century?
surprising!
Post by c***@gmx.de
yeah, like mount... its files all the way down :)
linux is like windows... everything is a HANDL^Wfiledescriptor
--
cinap
t***@polynum.com
2012-10-17 17:54:25 UTC
Permalink
get to the part about why it's so great that pipe is a system call,
not a device.
This is the sort of back-and-forth that reminds me why I can't quite
give up on plan 9 ...
http://yarchive.net/comp/linux/everything_is_file.html
I like the way the discussion goes. From an outspoken Linus Torvalds
saying "nonsense", to a diving into details that progressively gives
points to some operating system with both "a lot of things are files",
and namespaces---these are related, but not identical.
--
Thierry Laronde <tlaronde +AT+ polynum +dot+ com>
http://www.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C
Bakul Shah
2012-10-17 19:04:43 UTC
Permalink
Post by dexen deVries
a technical and organizational problem: back then Linux' /dev consisted of
special files held on drive, its MAJOR/MINOR schema* getting dangerously
cramped.
those days Linux' /dev is usually mounted at boot and maintained by kernel,
somewhat alike /proc; adding some more entries probably isn't that much of a
problem.
You should explore /sys on Linux. They've embraced namespaces in a major way.

$ df /sys
Filesystem 1K-blocks Used Available Use% Mounted on
sysfs 0K 0K 0K - /sys
$ ls -lR /sys |wc
10485 63451 419873
$ ls -l /sys/dev/block/8:1
lrwxrwxrwx. 1 root root 0 Oct 17 11:31 /sys/dev/block/8:1 -> ../../devices/pci0000:00/0000:00:0d.0/host2/target2:0:0/2:0:0:0/block/sda/sda1

Let us see where this leads:

$ ls -Ll /sys/dev/block/8:1
total 0K
-r--r--r--. 1 root root 4096 Oct 17 11:31 alignment_offset
-r--r--r--. 1 root root 4096 Oct 17 11:31 dev
-r--r--r--. 1 root root 4096 Oct 17 11:31 discard_alignment
drwxr-xr-x. 2 root root 0 Oct 17 11:26 holders
-r--r--r--. 1 root root 4096 Oct 17 11:31 inflight
-r--r--r--. 1 root root 4096 Oct 17 11:31 partition
drwxr-xr-x. 2 root root 0 Oct 17 11:31 power
-r--r--r--. 1 root root 4096 Oct 17 11:25 size
-r--r--r--. 1 root root 4096 Oct 17 11:31 start
-r--r--r--. 1 root root 4096 Oct 17 11:31 stat
drwxr-xr-x. 2 root root 0 Oct 17 11:31 subsystem
drwxr-xr-x. 2 root root 0 Oct 17 11:31 trace
-rw-r--r--. 1 root root 4096 Oct 17 11:31 uevent

Exploring further...

$ ls -l /sys/dev/block/8:1/subsystem
lrwxrwxrwx. 1 root root 0 Oct 17 11:31 /sys/dev/block/8:1/subsystem -> ../../../../../../../../../class/block

Editorial comments left as an exercise to the reader!
erik quanstrom
2012-10-18 00:35:12 UTC
Permalink
Post by Bakul Shah
You should explore /sys on Linux. They've embraced namespaces in a major way.
what am i missing. linux' /sys is just a synthetic filesystem. where do you
see this exploring the idea of namespace?

- erik
Bakul Shah
2012-10-18 01:10:28 UTC
Permalink
Post by erik quanstrom
Post by Bakul Shah
You should explore /sys on Linux. They've embraced namespaces in a major way.
what am i missing. linux' /sys is just a synthetic filesystem. where do you
see this exploring the idea of namespace?
Oops. s/namespace/synthetic filesystem/
David Leimbach
2012-10-18 20:31:29 UTC
Permalink
Post by Bakul Shah
Post by erik quanstrom
Post by Bakul Shah
You should explore /sys on Linux. They've embraced namespaces in a
major way.
Post by erik quanstrom
what am i missing. linux' /sys is just a synthetic filesystem. where
do you
Post by erik quanstrom
see this exploring the idea of namespace?
Oops. s/namespace/synthetic filesystem/
It'd be a lot better if it was a synthetic file system in a restricted
namespace. I don't think 100% of the processes need to or should have the
opportunity to mess with /sys. But maybe that's just all this stuff I
learned from Plan 9. :-)

Dave
Charles Forsyth
2012-10-18 20:45:49 UTC
Permalink
http://planb.lsub.org/ls/octopus.html

is a user interface that includes graphics, exploits name space
representations, and doesn't just mimic the xerox desktop.

Continue reading on narkive:
Loading...