The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: rminnich@gmail.com (ron minnich)
Subject: [TUHS] Sockets and the true UNIX
Date: Thu, 21 Sep 2017 20:15:42 +0000	[thread overview]
Message-ID: <CAP6exYJd9NNiLhRtnYa5ZeNoykAE+8UEgZY8PQXRmTnF4coZ9Q@mail.gmail.com> (raw)
In-Reply-To: <AE3CB5A3-EF97-480E-8D6C-050EBF606FB3@bitblocks.com>

you can go back and find an early RFC which discusses the notion of
/dev/tcp etc. I think I referenced it the last time this question came up.

In that rfc, the idea of /dev/tcp and so on was advanced. To connect to
harv, one might create /dev/tcp/harv, for example. It was not quite right.
How do you name a port? What file system operation in Unix corresponds to
what socket operation? There were lots of efforts from 77 or so on to get
sockets APIs done in a Unix style, i.e. not the style we ended up with, but
AFAIK nobody really worked it out until Plan 9 did it.

While it is true that socket()/bind/listen/accept/connect have stood the
test of time, I know when they were introduced many people thought of that
API as the first break in the Unix model, and a wrong turn, one that was
never fixed.

It's very easy to create a "file system" model for the network in a way
that doesn't make sense, e.g. if I have /dev/tcp/harv, and mv it to
/dev/tcp/prep, does that mean I close the connection to harv and open one
to prep? And so on. These issues were covered really nicely in a talk Rob
Pike gave in the 90s, but I can't find those slides any more and neither
can he. They're probably still on the venti server in the Unix room ... :-)

For an example of (IMHO) not getting it right, see:
http://www.cs.vu.nl/~herbertb/papers/osreview2008-2.pdf

I think anyone looking to put something like a network stack in the name
space should study on what Plan 9 did, not because it's the "right" or
"only' way to do it, but it's a way that worked.

But overall, in the 1977 timeframe, when (IIRC) there were no synthetic
file systems, I think we did not know how to think about "networks in the
file system" and we got what we got. By the time it was worked out, well,
it was too late to change.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://minnie.tuhs.org/pipermail/tuhs/attachments/20170921/143613a4/attachment.html>


  reply	other threads:[~2017-09-21 20:15 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-21 16:01 Ian Zimmerman
2017-09-21 16:07 ` Chet Ramey
2017-09-21 16:10 ` Larry McVoy
2017-09-21 16:20   ` David Edmondson
2017-09-21 16:25   ` Clem Cole
2017-09-21 16:27     ` Larry McVoy
2017-09-21 16:37     ` [TUHS] Sockets and the true UNIX [ actually carping about streams ] Jon Steinhart
2017-09-21 18:26   ` [TUHS] Sockets and the true UNIX Chet Ramey
2017-09-21 16:13 ` Jon Steinhart
2017-09-21 16:17   ` Larry McVoy
2017-09-21 20:36     ` Chris Torek
2017-09-21 18:56   ` Bakul Shah
2017-09-21 19:13     ` Steve Simon
2017-09-21 19:31       ` Bakul Shah
2017-09-21 20:15         ` ron minnich [this message]
2017-09-21 20:34           ` Clem Cole
2017-09-21 23:26   ` Dave Horsfall
     [not found] <mailman.1105.1506026200.3779.tuhs@minnie.tuhs.org>
2017-09-22 10:36 ` Paul Ruizendaal
2017-09-22 14:32   ` Clem Cole
2017-09-22 14:42     ` Chet Ramey
2017-09-22 14:47       ` Chet Ramey
2017-09-22 14:52         ` Lars Brinkhoff
2017-09-22 14:49       ` Larry McVoy
2017-09-22 14:57         ` Chet Ramey
2017-09-22 18:14           ` Chris Torek
2017-09-22 18:43             ` Clem Cole
2017-09-22 19:08             ` Chet Ramey
2017-09-22 20:57               ` Chris Torek
2017-09-24 18:04                 ` Chet Ramey
2017-09-22 18:00   ` Chris Torek
2017-09-25 17:57 Norman Wilson
2017-09-25 18:55 ` Clem Cole

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAP6exYJd9NNiLhRtnYa5ZeNoykAE+8UEgZY8PQXRmTnF4coZ9Q@mail.gmail.com \
    --to=rminnich@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).