Home Blog About Contact

UNIX V2 Beta

Dennis Ritchie sent dumps of various DECtapes read by Keith Bostic and Paul Vixie to Warren Toomey in 1997, which later ended up on TUHS's Unix Archive. Two of those tapes, labelled s1 and s2, contain a basic install of a UNIX version between V1 and V2.

I call this version of UNIX the "V2 beta". Of course, "beta" is a modern term that doesn't really fit UNIX, as early UNIX releases were just snapshots of the development system at the time a particular tape was made. The manuals are the only properly dated releases, so everything after the release of the V1 manual and before the V2 manual is "V1", with only the snapshot from when the V1 manual was released being the actual V1. However, since this version of UNIX has traits of V2, such as the V2 a.out(5) format, I call it "V2 beta", to signify that it's not just V1. Some people would call it "V1.5" (like calling the Utah V4 tape "V4.5").

The tapes s1 and s2 have been around for quite a while, however the focus had been on s2 and the overwritten files from s1. From the metadata, these tapes were written in roughly 1973/02. Before these tapes were written, they contained backups of /usr/source/s1 and /usr/source/s2 from a version around V3, hence the labels s1 and s2. The s1 tape was then overwritten with a UNIX INIT DECtape created from a V2 beta system, and the s2 tape was overwritten with a backup of the RF11/RS11 disk of that V2 beta system in the tap(1) format. Given that UNIX INIT DECtapes store files in a not easily recognisable way, the partially overwritten source code backup on s1 had been mistaken for a middle reel of an rkd(1) backup.

UNIX INIT DECtape

UNIX INIT DECtape is a special form of UNIX DECtape which is bootable. It is documented in bproc(7). Essentially, it was used to perform a clean install of UNIX. When you boot from one of these tapes, it will copy the boot data (vcboot, bos, wunix, cunix, and unassigned) into the read-only portion of the RF, then perform a cold boot from the Cold UNIX kernel (cunix), which allows the rest of the RF to be initialised with a UNIX filesystem. Afterwards, it loads a minimal set of programs from the tape, creating a pre-installation environment to allow actual installation tapes to be restored.

The important point is that UNIX kernels (Cold UNIX and Warm UNIX) are only found in UNIX INIT DECtapes, because early UNIX did not have kernels as disk files and hence they were not included in installation/backup tapes.

Knowing that s1 is a UNIX INIT DECtape, it can be parsed and extracted (note that timestamps are not stored in UNIX INIT DECtapes, hence the placeholder 1970/01/01 is used):

Mode       UID GID  Size Date                Name
---------- --- --- ----- ------------------- ------------
-rw-rw-rw-   0   0   512 1970-01-01 00:00:00 [vcboot]
-rw-rw-rw-   0   0  2048 1970-01-01 00:00:00 [bos]
-rw-rw-rw-   0   0 12288 1970-01-01 00:00:00 [wunix]
-rw-rw-rw-   0   0 12288 1970-01-01 00:00:00 [cunix]
-rw-rw-rw-   0   0  3072 1970-01-01 00:00:00 [unassigned]
-rwxr-xr-x   1   0   424 1970-01-01 00:00:00 /etc/init
-rwxrwxrwx   3   0   446 1970-01-01 00:00:00 /etc/getty
-rwxr-xr-x   3   0    82 1970-01-01 00:00:00 /bin/chmod
-rwsr-xr-x   0   0   794 1970-01-01 00:00:00 /bin/date
-rwsr-xr-x   0   0  1290 1970-01-01 00:00:00 /bin/login
-rwsr-xr-x   0   0   232 1970-01-01 00:00:00 /bin/mkdir
-rwxr-xr-x   1   0   954 1970-01-01 00:00:00 /bin/sh
-rwsr-xr-x   0   0  3678 1970-01-01 00:00:00 /bin/tap
-rwxr-xr-x   3   0  2010 1970-01-01 00:00:00 /bin/ls

578 blocks, 98 (16.96%) used, 480 (83.04%) free.
B = boot; D = directory;
. = free; X = file data;
O = bos; W = wunix;
C = cunix; S = rf slack;
U = unassigned program;

  |0123456789ABCDEF
--+----------------
00|BOOOOWWWWWWWWWWW
01|WWWWWWWWWWWWWCCC
02|CCCCCCCCCCCCCCCC
03|CCCCCUUUUUUSSSSS
04|SDXDXDXDXXDXXXDX
05|DXXDXXXXXXXXDXXX
06|XD..............
07|................

<...>

The notable thing about the UNIX kernels here is that they are the earliest UNIX kernels to exist in binary form - all the earlier ones came from printed source listings.

The kernels offer a 16 KiB (8K word) user core and support for UNIX V2 (0407) a.out(5) formatted executables, with none of the V2 syscalls implemented. This puts it in between V1 and V2 in terms of functionality.

Further evidence that it sits between V1 and V2 is the bos program accepting a mix of V1 and V2 switches:

                      | UNIX V1  | s1    | UNIX V2
----------------------+----------+-------+---------
Warm boot             | [1]73700 | ???   | ???
Cold boot             | 1        | 1     | 1
Unassigned 3K prog    | 2        | 2     |
Dump core & halt      | 10       | 10    | 10
Boot from RK          |          | 20    | 20
Dump core & warm boot |          | 40    | 40
Boot from paper tape  | 0        | 0     | 0
Load DEC loaders      | 57500    | 57500 | 77500
----------------------+----------+-------+---------
UNIX load address     | 400      | 400   | 600
----------------------+----------+-------+---------

The boot-from-unassigned-3K-program option was probably in the process of being deprecated, as the 3K of space is also loaded as part of the Cold UNIX despite it not being used by the Cold UNIX kernel. The list of files on the UNIX INIT DECtape also appears to be between V1 and V2:

           | V1  | s1  | V2
-----------+-----+-----+-----
/etc/init  | Yes | Yes | Yes
/etc/getty | No  | Yes | Y/N
/bin/chmod | Yes | Yes | Yes
/bin/chown | Yes | No  | No
/bin/date  | No  | Yes | Yes
/bin/login | No  | Yes | Yes
/bin/cp    | Yes | No  | No
/bin/ln    | Yes | No  | No
/bin/ls    | Yes | Yes | Yes
/bin/mkdir | Yes | Yes | Yes
/bin/mv    | Yes | No  | No
/bin/rm    | Yes | No  | No
/bin/rmdir | Yes | No  | No
/etc/mount | No  | No  | Yes
/bin/sh    | Yes | Yes | Yes
/bin/stat  | Yes | No  | No
/bin/tap   | Yes | Yes | Yes
-----------+-----+-----+-----

Functional System

The s1 and s2 tapes were created together from the same installation of UNIX, as the files extracted from s1 match the corresponding files from s2 exactly, and the s2 tape has temporary files used for creating the s1 tape.

If one boots from s1 to restore the s2 tape, the end result should be a fully bootable copy of this UNIX V2 beta, however, it's not that easy. While the s1 tape does boot and function correctly, it is missing /etc/passwd and hence will not allow anyone to log in if booted from it.

Since the UNIX V1/V2 filesystem is sufficiently simple, I have manually created a bootable RF disk image with the kernels from s1 and the files from s2 - exactly what you would get if s2 was restored after booting from s1.

Click to see file list
Mode       UID GID  Size Date                Name
---------- --- --- ----- ------------------- ----------------
-rw-rw-rw-   0   0   512 1970-01-01 00:00:00 [vcboot]
-rw-rw-rw-   0   0  2048 1970-01-01 00:00:00 [bos]
-rw-rw-rw-   0   0 12288 1970-01-01 00:00:00 [wunix]
-rw-rw-rw-   0   0 12288 1970-01-01 00:00:00 [cunix]
-rw-rw-rw-   0   0  3072 1970-01-01 00:00:00 [unassigned]
-rwxr-xr-x   3   0    82 1972-01-17 17:53:35 /bin/chmod
-rwsr-xr-x   0   0   794 1972-04-19 23:45:12 /bin/date
-rwsr-xr-x   0   0  1290 1972-03-28 15:19:21 /bin/login
-rwsr-xr-x   0   0   232 1972-11-05 21:42:18 /bin/mkdir
-rwxr-xr-x   1   0   954 1972-01-19 17:20:54 /bin/sh
-rwsr-xr-x   0   0  3678 1972-12-30 04:08:39 /bin/tap
-rwxr-xr-x   3   0  2010 1972-01-17 17:53:39 /bin/ls
-rwxr-xr-x   3   0   718 1972-11-21 22:51:32 /bin/chown
-rwxr-xr-x   3   0   160 1972-01-17 17:53:36 /bin/cp
-rwxr-xr-x   3   0   104 1972-01-17 17:53:39 /bin/ln
-rwsr-xr-x   0   0   784 1972-01-17 17:46:57 /bin/mv
-rwxr-xr-x   3   0    93 1972-01-17 17:53:41 /bin/rm
-rwsr-xr-x   0   0   282 1972-09-27 21:37:12 /bin/rmdir
-rwxr-xr-x   3   0  1026 1972-01-17 17:53:42 /bin/stat
-rwxr-xr-x   3   0   524 1972-01-17 17:53:45 /bin/write
-rwxr-xr-x   3   0   480 1972-05-26 00:21:13 /bin/strip
-rwxr-xr-x   3   0   244 1972-01-17 17:56:30 /bin/dsw
-rwxr-xr-x   4   0  7154 1972-07-20 12:42:42 /bin/roff
-rwxr-xr-x   3   0   518 1972-06-29 20:09:07 /bin/nm
-rwxr-xr-x   3   0   560 1972-01-17 17:54:56 /bin/who
-rwxr-xr-x   3   0   464 1972-01-17 17:53:37 /bin/du
-rwxr-xr-x   3   0  5922 1972-01-17 17:56:30 /bin/bas
-rwsr-xr-x   1   0   192 1972-11-21 19:35:16 /bin/df
-rwxr-xr-x   3   0   420 1972-01-17 17:53:35 /bin/cmp
-rwxrwxrwx   3   0    76 1972-04-05 19:42:00 /bin/chball
-rwxr-xr-x   3   0  4066 1972-03-28 16:42:29 /bin/db
-rwxr-xr-x   3   0  2310 1972-01-26 17:20:48 /bin/ar
-rwxr-xr-x   3   0  2942 1972-06-29 19:26:31 /bin/ld
-rwxr-xr-x   3   0   134 1972-01-17 17:53:35 /bin/cat
-rwxr-xr-x   3   0  1166 1972-01-17 17:54:56 /bin/pr
-rwxr-xr-x   3   0   238 1972-06-29 18:37:31 /bin/un
-rwsr-xr-x   1   0   790 1972-11-25 14:24:14 /bin/tm
-rwxr-xr-x   3   0    70 1972-01-17 17:53:41 /bin/rew
-rwsr-xr-x   1   0  1084 1972-11-21 19:35:16 /bin/check
-rwxr-xr-x   3   0    80 1972-01-17 17:53:43 /bin/tty
-rwxr-xr-x   3   0   154 1972-01-17 17:53:40 /bin/mesg
-rwxr-xr-x   3   0  3998 1972-05-09 15:23:19 /bin/ed
-rwxr-xr-x   3   0  1912 1972-01-04 17:05:31 /bin/form
-rwxr-xr-x   3   0   644 1972-01-17 17:54:56 /bin/wc
-rwxr-xr-x   3   0   300 1972-01-17 17:54:56 /bin/od
-rwsr-xr-x   0   0  3940 1972-01-05 19:26:54 /bin/mail
-rwxr-xr-x   3   0   604 1972-11-21 22:51:32 /bin/sort
-rwxr-xr-x   3   0    16 1972-01-17 17:56:30 /bin/:
-rwxr-xr-x   3   0  1054 1972-01-17 17:56:30 /bin/echo
-rwxr-xr-x   3   0  1154 1972-01-17 17:56:29 /bin/goto
-rwxr-xr-x   3   0  1844 1972-01-17 17:56:29 /bin/if
-rwxr-xr-x   3   0   276 1972-01-17 17:56:30 /bin/exit
-rwxr-xr-x   3   0   750 1972-01-17 17:54:56 /bin/skip
-rwxr-xr-x   3   0  1048 1972-01-31 18:14:08 /bin/stty
-rwxrwxrwx   6   0  2860 1972-03-06 12:23:39 /bin/cal
-rwxrwxrwx   3   0   214 1972-07-14 01:21:57 /bin/sum
-rwxr-xr-x   3   0  6846 1972-04-13 20:50:45 /bin/dc
-rwsr-xr-x   0   0   746 1972-05-02 22:54:21 /bin/su
-rwxr-xr-x  10   0  2730 1972-05-26 23:37:25 /bin/fc
-rwxrwxrwx   3   0  4672 1972-06-29 21:53:34 /bin/cc
-rwxr-xr-x   3   0  1446 1972-06-29 20:15:35 /bin/size
-rwsr-xr-x   1   0   872 1972-05-26 00:26:05 /bin/ds
-rwxr-xr-x   3   0   330 1972-05-26 00:21:08 /bin/find
-rwxr-xr-x   3   0  7582 1972-06-29 17:45:21 /bin/as
-rwxrwxrwx   0   0   698 1972-01-01 01:35:34 /bin/maki
-rwxr-xr-x   1   0   424 1973-02-05 14:50:16 /etc/init
-rwxrwxrwx   3   0   446 1972-04-06 16:40:13 /etc/getty
-rw-r--r--   3   0  2082 1972-03-27 16:42:26 /etc/suftab
-rw-r--r--   1   0    70 1973-02-05 14:38:57 /etc/uids
-rw-------   1   0   221 1973-02-05 14:35:10 /etc/passwd
-rwxr-xr-x   1   0   186 1972-01-06 18:01:18 /etc/msh
-rwxr-xr-x   1   0  2662 1972-01-06 18:01:17 /etc/glob
-rwxrwxrwx   3   0  5778 1972-06-29 17:47:16 /etc/as2
-rw-rw-rw-   0   0   512 1972-01-01 01:33:59 /etc/std0
-rw-rw-rw-   0   0 16448 1972-01-01 01:36:34 /usr/sys/core
-rwxrwxrwx   0   0  2192 1972-01-01 01:37:02 /usr/sys/a.out
-rw-r--r--   1   0  1928 1972-01-01 01:36:55 /usr/sys/maki.s
-rw-rw-rw-   0   0 12158 1972-06-29 18:40:35 /usr/lib/liba.a
-rw-rw-rw-   0   0  6626 1972-06-19 10:47:35 /usr/lib/libb.a
-rw-rw-rw-   0   0  3498 1972-06-08 17:10:05 /usr/lib/bilib.a
-rwxrwxrwx   3   0 17092 1972-06-05 21:26:04 /usr/lib/c1
-rwxrwxrwx   3   0 19948 1972-06-29 21:21:47 /usr/lib/c0
-rw-rw-rw-  28   0  9158 1972-06-29 20:46:07 /usr/lib/libf.a
-rw-rw-rw-   0   0  5242 1972-06-29 21:20:00 /usr/lib/libc.a
-rw-rw-rw-  28   0   304 1972-06-29 20:31:32 /usr/lib/fr0.o
-rw-rw-rw-  28   0 12222 1972-06-29 20:37:02 /usr/lib/filib.a
-rw-rw-rw-   0   0   108 1972-06-29 21:11:20 /usr/lib/crt0.o
-rw-rw-rw-  10   0    84 1972-01-01 00:58:12 /usr/jack/x.f
-rwxrwxrwx   0   0  7514 1972-01-01 00:58:33 /usr/jack/a.out
-rw-rw-rw-   0   0   312 1972-01-01 00:58:26 /usr/jack/x.o
-rwxr-xr-x  28   0  3462 1972-06-30 16:35:35 /usr/fort/fc1
-rwxr-xr-x  28   0  3238 1972-06-30 16:35:36 /usr/fort/fc2
-rwxr-xr-x  28   0  6840 1972-06-30 16:35:41 /usr/fort/fc3
-rwxr-xr-x  28   0  4918 1972-06-30 16:35:43 /usr/fort/fc4
-rw-rw-rw-  10   0    54 1972-01-01 00:52:29 /usr/x
-rw-rw-rw-   1   0   670 1972-01-01 01:33:33 /usr/ken/maki.s
-rw-r--r--   0   0   142 1972-01-01 01:33:53 /tmp/utmp
-r--r--r--   1   0  1664 1972-01-01 01:31:19 /tmp/etma
-rw-rw-rw-   0   0    26 1972-01-01 01:35:47 /tmp/ttmp
-rw-rw-rw-   0   0 16448 1972-01-01 00:33:51 /core

Download: https://github.com/TheBrokenPipe/Research-UNIX-V2-Beta

Emulation

There are two emulators known to boot this version of UNIX - SIMH and aap's PDP-11 emulator.

I used this SIMH config:

set cr disabled
set xq disabled
set rk disabled
set hk disabled
set rha disabled
set tm disabled
set rx disabled
set rl disabled
set tq disabled
set dci disabled
set cpu 11/20
set cpu 32K
set ke enabled
set rf 2p
set rf enabled
att rf s1s2unix_rf.img         <-- RF disk image
set tc enabled
set tc locked
att tc s1.itp                  <-- s1 tape
load m792low.load              <-- Modified UNIX ROM from unix-june72 project
dep system sr 173700
go 73700                       <-- Low address used by the modded ROM

This version of UNIX strictly uses LF for line endings, even terminal inputs, so it does not like CRs or CRLFs which most terminals send when you hit the ENTER key. If pressing ENTER does not work for you, try Ctrl + J (which hopefully sends the LF character).

Demo

login: root
root
# ls -la
total   42
 41 sdrwrw  7 root     80 Jan  1 00:02:02 .
 41 sdrwrw  7 root     80 Jan  1 00:02:02 ..
 43 sdrwrw  2 root    620 Jan  1 00:01:30 bin
147 l-rwrw  1 root  16448 Jan  1 00:33:51 core
 42 sdrwrw  2 root    250 Jan  1 00:01:51 dev
 49 sdrwrw  2 root    110 Jan  1 00:01:55 etc
 54 sdrwrw  2 root     50 Jan  1 00:00:52 tmp
 55 sdrwrw  7 root     80 Jan  1 00:00:52 usr
# ls -la usr
total    8
 55 sdrwrw  7 root     80 Jan  1 00:00:52 .
 41 sdrwrw  7 root     80 Jan  1 00:02:02 ..
 56 sdrwrw  2  28      60 Jan  1 00:02:22 fort
 57 sdrwrw  2 jack     50 Jan  1 00:02:39 jack
 58 sdrwrw  2   6      30 Jan  1 00:02:36 ken
 59 sdrwrw  2 root    120 Jan  1 00:00:52 lib
 60 sdrwrw  2 sys      50 Jan  1 00:02:45 sys
142 s-rwrw  1 jack     54 Jan  1 00:52:29 x
# ed
a
main() printf("hello world!\n");
.
w hello.c
33
q
# cc hello.c
I
II
# ls -l a.out
total    3
153 sxrwrw  1 root   1328 Jan  1 00:02:12 a.out
# a.out
hello world!
#

Page written by Yufeng Gao. Last updated: 2026/04/11.