Minix2 16bit ppp demo

From DOSBoxWiki
Revision as of 11:27, 18 October 2017 by Naszvadi (talk | contribs) (Minix2 networking test drive - slip setup)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

DOSBox supports nullmodem connection using tcp sockets. In this page, we describe a simple networking slip configuration on linux (ubuntu) host, but for Minix 2.0.2 guest operating system. With socat or similar tools on host's side, you can connect these sockets with slattach, and the DOSBox guest can access internet as well.


The included script and manual is dangerous. It needs sudo or root access to the target host, uses external dependencies, can cause damage and irrecoverable package dependency problems via apt installing, and may be harmful when you are not familiar with tcp/ip ipv4 networking or linux iptables/slattach/etc. tools.

Prerequisities under ubuntu

Internet settings

A working internet connection is essential. network must be unused! Otherwise network range collision will happen, causing unpredictable results!

Required ubuntu packages

The followings need to be installed:

apt-get install bash dosbox iptables socat sudo

The main script:

The content of

#! /bin/bash
flushipt() {
  for i in $( iptables -t nat -n --line-numbers -L \
    | awk '/^Chain POSTROUTING/,/^$/{if(/^[0-9].*[^0-9]10\.1\.1\./)print $1}' | tac )
    iptables -t nat -D POSTROUTING "$i"
  for i in $( iptables -t nat -n --line-numbers -L \
    | awk '/^Chain PREROUTING/,/^$/{if(/^[0-9].*[^0-9]10\.1\.1\./)print $1}' | tac )
    iptables -t nat -D PREROUTING "$i"
if id -u | grep -q '^0'; then
  echo 'dosbox slip deployment for minix2 guest'
  echo 'Author(s): Naszvadi Peter et al'
  echo "Please run $0 as root!"
  exit 1
set -e
echo Checking necessary applications:
which dosbox
which iptables
which slattach
which socat
which sudo
which tac
set +e
Dev_Pts="$(mktemp -u /tmp/slipXXX)"
socat PTY,link="$Dev_Pts",raw,echo=0 TCP-LISTEN:8040 &
sleep 1
Uid="$(find "$0" -printf '%U' -quit)"
sudo -u "#$Uid" dosbox -conf mnxslip.cnf &
grep -q 1 /proc/sys/net/ipv4/ip_forward || ( echo 1 1>/proc/sys/net/ipv4/ip_forward )
slattach -d -s 9600 -p adaptive "$Dev_Pts" 1>/dev/null 2>/dev/null &
sleep 3
ifconfig sl0 dstaddr netmask mtu 576 up 1>/dev/null 2>/dev/null
set -x
iptables -t nat -A POSTROUTING -s -j MASQUERADE 1>/dev/null 2>/dev/null
set +x
while ps "$Pid_Saved" 1>/dev/null 2>/dev/null; do sleep 5
done 1>/dev/null 2>/dev/null
kill -9 "$Pid_Saved_2" "$Pid_Saved_3" 1>/dev/null 2>/dev/null
exit 0

The custom configuration file: mnxslip.cnf

The content of mnxslip.cnf:

serial1=nullmodem server:localhost port:8040 transparent:1
mount C .

Launch a networked session under ubuntu

Creating working directory

Create a standalone folder, e.g. mkdir ~/minixslip

Creating files

Necessary files:

  • mnxslip.cnf

The latters should be saved from this site.

Set attributes of

chmod 755

Download and extract link and checksums at the bottom of this page

Till this, the above were the once time steps.

Launch ./

Do it with sudo:

sudo ./

If everything is okay, you can get similar results like these - setup slip in minix2 prompt after logging in with passwordless root account:

slip.drv -b 38400 -c -i /dev/tty00 & echo nameserver >/etc/resolv.conf

Press enters after entering command till getting command prompt back.

Dosbox minix2 slipsetup.gif



Dosbox minix2 telnetbbs.gif

IRC client

Dosbox minix2 minirc.gif


Graceful shutdown of guest in guest CLI:

# sync
# shutdown

Then type exit + ENTER at the appearing prompts!