From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from minnie.tuhs.org (minnie.tuhs.org [45.79.103.53]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id cc2e4a57 for ; Mon, 21 Oct 2019 11:39:17 +0000 (UTC) Received: by minnie.tuhs.org (Postfix, from userid 112) id 5290C9B92F; Mon, 21 Oct 2019 21:39:15 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id CC94E93D91; Mon, 21 Oct 2019 21:38:52 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="cgZOEetJ"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id C5FB393D91; Mon, 21 Oct 2019 21:38:50 +1000 (AEST) Received: from mail-ed1-f47.google.com (mail-ed1-f47.google.com [209.85.208.47]) by minnie.tuhs.org (Postfix) with ESMTPS id DA86793D8C for ; Mon, 21 Oct 2019 21:38:49 +1000 (AEST) Received: by mail-ed1-f47.google.com with SMTP id m4so2597925edr.6 for ; Mon, 21 Oct 2019 04:38:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=YiLs6shcfQ3he/te97R4DmM9vNIGCmpwtzvWwwydNUI=; b=cgZOEetJ71b1p72CYkxePNcOQGkba5q7O+wckzc3kC6XhqXO9jb0EWr1gnBwRwLc3z LuUFDNCrfkCd69tHUJFb7fP4W4WUZlP6/+wW5x8WQGuJxViv6vzvvILz/1d+PJEelyqB nYWf3cqapwJi0kn8ZqpD5fSf6lAcZmpIIdLlZ+Y0NobE+VoeNxlqy6A76z5jnIhvmtPq zd9t3vNtrJ0vR92788vgcKSpkw/g/OaS8MkxLGNKhaJBllxOR3iBmZ/cTtzoB4CHlMyg AGtcHkdmmKVRdEtuk9uv8UUQF1MtQGkhDfEZwfH/2KRZ5akXZYwqSIPKTXe5fkg6aPSy vSpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=YiLs6shcfQ3he/te97R4DmM9vNIGCmpwtzvWwwydNUI=; b=LHkvQGy35fVwi3IT0IxFwST1zSC+OmM1jvgXBkREzhonJXNkoE7Xs+lcd2aneZVMxM zDeo+HDP6xveIswNVxp14a4JlCTS8Fq2ZXswf5UmJT8areK+JSDWcAAW7PtLHK4QpwBL DG7swN7XD8v1W6JGY5HKxGiiwOwO0S9RUrHTiCUZlEviP8j5b8/FaxT1X2vgfmyAPtqn EL7gmsUFTKqMmq94Kh+GfL1lKiaboFcEy/OhxX+ugGjOm1zyJP+rZvJ2OBtxfh9mxKhc dEzqH4CBiabek0hgMFvbmumnVALxBzRLO/XC/MSZGrA7BZ73PnMUdIBMNr+/vc06E31K +ZgQ== X-Gm-Message-State: APjAAAVvFJmh31q8Tw16GrLKr8jbrJC3Af4fc9uQcwrfKPiifVlLzt06 3xZTgl36gZxIqjKvKdBpBWQpgW8Zl1IODo0x/lSJuRP8Hi4= X-Google-Smtp-Source: APXvYqzUP7IXVdLA+TG+ufiRkM6YtlcGGmqv+8uGovDSGd4dvCgNe0urXq8nKzi64KfMApspFn1fK7879g+ZK6mdEFU= X-Received: by 2002:aa7:cd71:: with SMTP id ca17mr3063890edb.1.1571657928322; Mon, 21 Oct 2019 04:38:48 -0700 (PDT) MIME-Version: 1.0 References: <20191021062242.GA91599@indra.papnet.eu> In-Reply-To: From: Abhinav Rajagopalan Date: Mon, 21 Oct 2019 17:08:11 +0530 Message-ID: To: Angelo Papenhoff , tuhs@tuhs.org Content-Type: multipart/alternative; boundary="00000000000086b29c05956a20c3" Subject: Re: [TUHS] PDP-7 UNIX filesystem X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --00000000000086b29c05956a20c3 Content-Type: text/plain; charset="UTF-8" Also, I only now realized that only mknod existed, up until a long time, only later on with the GNU coreutils did mkdir as a command come into existence. Running the PDP-11 v7 on SIMH showed that, gotten so accustomed to the Linux env that thinking backwards seemed suddenly arcane. On Mon, Oct 21, 2019 at 4:13 PM Abhinav Rajagopalan < abhinavrajagopalan@gmail.com> wrote: > > >> . and .. >> >> Was this introduced first with PDP-11 unix or did the convention >> start on the PDP-7 already? It certainly seems to be the case with . >> but how about ..? the dd directory seems to take on the role of a sort >> of root directory and the now discovered program pd actually creates a >> file .. (haven't tried to understand what it does though yet) >> What does dd stand for, dotdot? directory directory? >> >> >> > . and .. are quite intuitive the more I think about it, they're > essentially acting as symbolic representations of the 'current' and > 'parent' dirs as in, when we look at it from / : > > / > |--|--|--|--|--|--|--|--| > /etc /bin /root /home /mnt /dev /usr > |--|--|--|--|--|--|--|--| > ../ ../ ../ ../ ../ ../ ../ ../ > > As we see, each of the subdirectories hold a / prefix to them as we're > used to seeing, and this translated to the subfolders having their ../ > descriptor denoting their parent (I think of them as recursive pointers to > parent dirs), where the parent holds ../ and child dir has a name like /.. > and invoking > > I don't know if it wasn't until the mkdir() syscall was added this > approach took form. There was an earlier 'Aha, Unix!' thread where Ken had > mentioned a similar thing, where invoking pwd gave only the /usr/name > directory even if the directory had been changed with chdir, essentially > stemming out of only the forked child changing dirs, when the cd wasn't > built into the shell (this was in the PDP-11 when he was writing the > initial set utilities like cd, ls) > > Also, depending on the implementation of 'ls' we were to try this out > today, these are bound to have their differences. The original syscalls on > the PDP-7 had chdir, > > swp: " system call dispatch table > jmp . " base instruction > .save; .getuid; .open; .read; .write; .creat; .seek; .tell > .close; .link; .unlink; .setuid; .rename; .exit; .time; .intrp > .chdir; .chmod; .chown; badcal; .sysloc; badcal; .capt; .rele > .status; badcal; .smes; .rmes; .fork > > > mkdir was probably in the works at this stage. > > We should also touch upon the "cd -" as this one takes you back like a > back button into the directory you were last inside, whereas the cd ../.. > takes you up or down the hierarchy depending on the placement of the / and > adding placeholders i.e directory names in place of the .. (dots). > > Of course, only the creators can embark upon the design details of the > hierarchical system and the reasons behind all the above and more. > > Since you mentioned the word dd, the utility which serves me like none > other for my frequent rewrites of images, it too has an interesting past, > it seems like 'dd' was non-unixy in it's design approach, if I'm to believe > the lores around, which leads me to think that this might have been another > one of the many idiosyncratic naming conventions used back then. More on > the dd stuff: http://www.catb.org/jargon/html/D/dd.html > > Personally, I just like to think of it in my head as disk-disk. > > -- > > Abhinav Rajagopalan > > > -- Abhinav Rajagopalan --00000000000086b29c05956a20c3 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Also, I only now realized that only mknod ex= isted, up until a long time, only later on with the GNU coreutils did mkdir= as a command come into existence. Running the PDP-11 v7 on SIMH showed tha= t, gotten so accustomed to the Linux env that thinking backwards seemed sud= denly arcane.

On Mon, Oct 21, 2019 at 4:13 PM Abhinav Rajagopalan = <abhinavrajagopalan@gmai= l.com> wrote:


. and ..

=C2=A0 =C2=A0 =C2=A0 =C2=A0 Was this introduced first with PDP-11 unix or d= id the convention
start on the PDP-7 already? It certainly seems to be the case with .
but how about ..? the dd directory seems to take on the role of a sort
of root directory and the now discovered program pd actually creates a
file .. (haven't tried to understand what it does though yet)
What does dd stand for, dotdot? directory directory?



. and .= . are quite intuitive the more I think about it, they're essentially ac= ting as symbolic representations of the 'current' and 'parent&#= 39; dirs as in, when we look at it from / :
=C2=A0
<= /div>
=C2=A0 =C2=A0 =C2=A0=C2=A0=C2=A0 =C2=A0 =C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /
=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 |--|--|--|--|--|--|--|--|
=C2= =A0 =C2=A0=C2=A0 /et= c /bin /root /home /mnt /dev /usr
=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |--|--|--|--|--|--|--|--|
=C2=A0=C2=A0=C2=A0=C2=A0 ../ ../ ../ ../ ../ ../ ../ ../

As we see, each of the subdirectories hol= d a / prefix to them as we're used to seeing, and this translated to th= e subfolders having their ../ descriptor denoting their parent (I think of = them as recursive pointers to parent dirs), where the parent holds ../ and = child dir has a name like /..
and invoking

I don't know if it wasn't until = the mkdir() syscall was added this approach took form. There was an earlier= 'Aha, Unix!' thread where Ken had mentioned a similar thing, where= invoking pwd gave only the /usr/name directory even if the directory had b= een changed with chdir, essentially stemming out of only the forked child c= hanging dirs, when the cd wasn't built into the shell (this was in the = PDP-11 when he was writing the initial set utilities like cd, ls)
=

Also, depending on the implementation= of 'ls' we were to try this out today, these are bound to have the= ir differences. The original syscalls on the PDP-7 had chdir,

swp:			" system call dispatch t=
able
   jmp .		" base instruction
   .save; .getuid; .open; .read; .write; .creat; .seek; .tell
   .close; .link; .unlink; .setuid; .rename; .exit; .time; .intrp
   .chdir; .chmod; .chown; badcal; .sysloc; badcal; .capt; .rele
   .status; badcal; .smes; .rmes; .fork

=
mkdir was probably in the works at this stage.

We should also touch upon the "cd -&q= uot; as this one takes you back like a back button into the directory you w= ere last inside, whereas the cd ../.. takes you up or down the hierarchy de= pending on the placement of the / and adding placeholders i.e directory nam= es in place of the .. (dots).

Of course, only the creators can embark upon the design details of the = hierarchical system and the reasons behind all the above and more.
=C2=A0 =C2=A0=C2=A0=C2=A0=C2=A0
Sinc= e you mentioned the word dd, the utility which serves me like none other fo= r my frequent rewrites of images, it too has an interesting past, it seems = like 'dd' was non-unixy in it's design approach, if I'm to = believe the lores around, which leads me to think that this might have been= another one of the many idiosyncratic naming conventions used back then. M= ore on the dd stuff: http://www.catb.org/jargon/html/D/dd.html
=C2=A0=
Personally, I just like to think of it in my head as disk= -disk.

--

=
Abhinav Rajagopalan


=


--

Abhinav Rajagopalan

=

--00000000000086b29c05956a20c3--