Fully emulated and network-enabled SS-5 running Solaris 2.6 (--privileged & NET_ADMIN NOT required!)
10K+
This is a docker container running Solaris 2.6 on qemu-system-sparc (SS-5) and is network enabled using qemu's SLIRP networking. There are no additional capabilities or guest privileges required to run it, just do: docker run -it netcrave/sparcsolaris and an instance will be created for you. If you haven't started using docker yet, here's why you're missing out:
docker run -it netcrave/sparcsolaris
qemu-system-sparc:./vm.ini:3: warning: bus=0,unit=0 is deprecated with this machine type
qemu-system-sparc:./vm.ini:9: warning: bus=0,unit=2 is deprecated with this machine type
Configuration device id QEMU version 1 machine id 32
Probing SBus slot 0 offset 0
Probing SBus slot 1 offset 0
Probing SBus slot 2 offset 0
Probing SBus slot 3 offset 0
Probing SBus slot 4 offset 0
Probing SBus slot 5 offset 0
Invalid FCode start byte
CPUs: 1 x FMI,MB86904
UUID: 00000000-0000-0000-0000-000000000000
Welcome to OpenBIOS v1.1 built on Jan 17 2018 23:39
Type 'help' for detailed information
Trying disk:a...
Not a bootable ELF image
Loading a.out image...
Loaded 7680 bytes
entry point is 0x4000
bootpath: /iommu@0,10000000/sbus@0,10001000/espdma@5,8400000/esp@5,8800000/sd@0,0:a
switching to new context:
SunOS Release 5.6 Version Generic_105181-05 [UNIX(R) System V Release 4.0]
Copyright (c) 1983-1997, Sun Microsystems, Inc.
configuring network interfaces: le0.
Hostname: solaris.netcrave.internal
The / file system (/dev/rdsk/c0t0d0s0) is being checked.
/dev/rdsk/c0t0d0s0: FREE BLK COUNT(S) WRONG IN SUPERBLK (SALVAGED)
/dev/rdsk/c0t0d0s0: 2136 files, 22686 used, 58663 free
/dev/rdsk/c0t0d0s0: (159 frags, 7313 blocks, 0.1% fragmentation)
The system is coming up. Please wait.
checking ufs filesystems
/dev/rdsk/c0t0d0s7: is stable.
add net default: gateway 10.0.2.2
starting rpc services: rpcbind keyserv done.
Setting netmask of le0 to 255.255.255.0
Setting default interface for multicast: add net 224.0.0.0: gateway solaris.netcrave.internal
syslog service starting.
Print services started.
volume management starting.
The system is ready.
solaris.netcrave.internal console login:
when attached to the docker container you can detach using control+p+q but to switch between qemu monitor mode and qemu's SPARCStation 5 serial console press Control-a (release) then press c. The qemu monitor is handy for getting information and manipulating it's running state:
(qemu) info usernet
VLAN -1 (hostnet0):
Protocol[State] FD Source Address Port Dest. Address Port RecvQ SendQ
TCP[HOST_FORWARD] 34 * 21 10.0.2.15 21 0 0
TCP[HOST_FORWARD] 33 * 23 10.0.2.15 23 0 0
TCP[HOST_FORWARD] 32 * 111 10.0.2.15 111 0 0
TCP[HOST_FORWARD] 31 * 512 10.0.2.15 512 0 0
TCP[HOST_FORWARD] 30 * 513 10.0.2.15 513 0 0
TCP[HOST_FORWARD] 29 * 514 10.0.2.15 514 0 0
TCP[HOST_FORWARD] 28 * 540 10.0.2.15 540 0 0
TCP[HOST_FORWARD] 27 * 79 10.0.2.15 79 0 0
TCP[HOST_FORWARD] 26 * 37 10.0.2.15 37 0 0
TCP[HOST_FORWARD] 25 * 7 10.0.2.15 7 0 0
TCP[HOST_FORWARD] 24 * 9 10.0.2.15 9 0 0
TCP[HOST_FORWARD] 23 * 13 10.0.2.15 13 0 0
TCP[HOST_FORWARD] 22 * 29 10.0.2.15 29 0 0
TCP[HOST_FORWARD] 21 * 32771 10.0.2.15 32771 0 0
TCP[HOST_FORWARD] 20 * 32772 10.0.2.15 32772 0 0
TCP[HOST_FORWARD] 19 * 32773 10.0.2.15 32773 0 0
TCP[HOST_FORWARD] 18 * 7100 10.0.2.15 7100 0 0
TCP[HOST_FORWARD] 17 * 32774 10.0.2.15 32774 0 0
TCP[HOST_FORWARD] 16 * 515 10.0.2.15 515 0 0
TCP[HOST_FORWARD] 15 * 6112 10.0.2.15 6112 0 0
TCP[HOST_FORWARD] 14 * 1103 10.0.2.15 1103 0 0
TCP[HOST_FORWARD] 13 * 4045 10.0.2.15 4045 0 0
TCP[HOST_FORWARD] 12 * 32775 10.0.2.15 32775 0 0
TCP[HOST_FORWARD] 11 * 25 10.0.2.15 25 0 0
TCP[HOST_FORWARD] 10 * 32776 10.0.2.15 32776 0 0
TCP[HOST_FORWARD] 9 * 32777 10.0.2.15 32777 0 0
VLAN 0 (user.1):
Protocol[State] FD Source Address Port Dest. Address Port RecvQ SendQ
(qemu) info network
hub 0
\ hub0port1: user.1: index=0,type=user,net=10.0.2.0,restrict=off
\ hub0port0: lance.0: index=0,type=nic,model=lance,macaddr=52:54:00:12:34:56
hostnet0: index=0,type=user,net=10.0.2.0,restrict=off
(qemu)
type help in the monitor for more info.
the default root password is just password
if you want to make any changes to the vm configuration, here it is for reference:
# qemu config file
[drive]
media = "disk"
index = "0"
format = "raw"
file = "./disk.img"
[drive]
media = "cdrom"
index = "2"
file = "./solaris_2.6_598_sparc.iso"
[netdev "hostnet0"]
type = "user"
hostfwd = "tcp::21-:21"
hostfwd = "tcp::23-:23"
hostfwd = "tcp::111-:111"
hostfwd = "tcp::512-:512"
hostfwd = "tcp::513-:513"
hostfwd = "tcp::514-:514"
hostfwd = "tcp::540-:540"
hostfwd = "tcp::79-:79"
hostfwd = "tcp::37-:37"
hostfwd = "tcp::7-:7"
hostfwd = "tcp::9-:9"
hostfwd = "tcp::13-:13"
hostfwd = "tcp::29-:29"
hostfwd = "tcp::32771-:32771"
hostfwd = "tcp::32772-:32772"
hostfwd = "tcp::32773-:32773"
hostfwd = "tcp::7100-:7100"
hostfwd = "tcp::32774-:32774"
hostfwd = "tcp::515-:515"
hostfwd = "tcp::6112-:6112"
hostfwd = "tcp::1103-:1103"
hostfwd = "tcp::4045-:4045"
hostfwd = "tcp::32775-:32775"
hostfwd = "tcp::25-:25"
hostfwd = "tcp::32776-:32776""
hostfwd = "tcp::32777-:32777"
[machine]
graphics = "off"
type = "SS-5"
[memory]
size = "256"
[smp-opts]
cpus = "1"
cores = "1"
[boot-opts]
order = "c"
Not working yet. It must have something to do with the hostfwd option, I'll have to look into it.
Esoteric cloud and Netcrave Communications are not liable for loss, damage or any lawsuits that running this may incur. Use this warez your own risk!
paigeadele (at) gmail.com if you have any requests
SLIRP seems to rely on file descriptors per socket connection so it might be ideal to raise the ulimit for file handles for the container, add --ulimit nofile=1024000:1024000 when creating the container.
The first weird thing I noticed about this is how SLIRP emulates pings when pinging from the VM:
root@c5a2496df875:/# tcpdump -vvv -n -e -ttt -i eth0 -xX
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 262144 bytes
00:00:00.000000 02:42:ac:11:00:0a > 02:42:e4:c1:e7:5e, ethertype IPv4 (0x0800), length 123: (tos 0x0, ttl 64, id 13724, offset 0, flags [DF], proto UDP (17), length 109)
172.17.0.10.37517 > 216.58.209.206.7: [bad udp cksum 0x568f -> 0x6b34!] UDP, length 81
0x0000: 4500 006d 359c 4000 4011 aebf ac11 000a E..m5.@.@.......
0x0010: d83a d1ce 928d 0007 0059 568f 5468 6973 .:.......YV.This
0x0020: 2069 7320 6120 7073 6575 646f 2d50 494e .is.a.pseudo-PIN
0x0030: 4720 7061 636b 6574 2075 7365 6420 6279 G.packet.used.by
0x0040: 2053 6c69 7270 2074 6f20 656d 756c 6174 .Slirp.to.emulat
0x0050: 6520 4943 4d50 2045 4348 4f2d 5245 5155 e.ICMP.ECHO-REQU
0x0060: 4553 5420 7061 636b 6574 732e 0a EST.packets..
I recommend starting with a packet capture to debug any networking related problems, getting a connection out is possible, you can use docker exec -it <containerid> tcpdump -vvv -n -e -ttt -i eth0 -xX
# telnet google.com 80
Trying 216.58.209.206...
Connected to google.com.
Escape character is '^]'.
HTTP/1.1 GET / \r\n\r\n
HTTP/1.0 400 Bad Request
Content-Type: text/html; charset=UTF-8
Referrer-Policy: no-referrer
Content-Length: 1555
Date: Sat, 02 Mar 2019 04:32:22 GMT
<!DOCTYPE html>
<html lang=en>
<meta charset=utf-8>
<meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
<title>Error 400 (Bad Request)!!1</title>
<style>
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}@media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}@media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}@media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
</style>
<a href=//www.google.com/><span id=logo aria-label=Google></span></a>
<p><b>400.</b> <ins>That’s an error.</ins>
<p>Your client has issued a malformed or illegal request. <ins>That’s all we know.</ins>
Connection closed by foreign host.
#
SLIRP doesn't seem to be handling the port forward correctly though:
172.17.0.1.52484 > 172.17.0.10.23: Flags [P.], cksum 0x5860 (incorrect -> 0x2ba4), seq 1:25, ack 1, win 83, length 24
Telnet:
0x0000: fffd 03 DO SUPPRESS GO AHEAD
0x0003: fffb 18 WILL TERMINAL TYPE
0x0006: fffb 1f WILL NAWS
0x0009: fffb 20 WILL TSPEED
0x000c: fffb 21 WILL LFLOW
0x000f: fffb 22 WILL LINEMODE
0x0012: fffb 27 WILL NEW-ENVIRON
0x0015: fffd 05 DO STATUS [|telnet]
0x0000: 4510 0040 21fe 4000 4006 c07c ac11 0001 E..@!.@.@..|....
0x0010: ac11 000a cd04 0017 f176 a2fa aa5e c352 .........v...^.R
0x0020: 5018 0053 5860 0000 fffd 03ff fb18 fffb P..SX`..........
0x0030: 1fff fb20 fffb 21ff fb22 fffb 27ff fd05 ......!.."..'...
but the connection can be observed from the monitor
(qemu) info usernet
VLAN -1 (hostnet0):
Protocol[State] FD Source Address Port Dest. Address Port RecvQ SendQ
TCP[SYN_SENT] 39 172.17.0.10 23 10.0.2.15 23 0 0
the services are running
# netstat -a | grep telnet
*.telnet *.* 0 0 0 0 LISTEN
# grep telnet /etc/inetd.conf
# Ftp and telnet are standard Internet services.
telnet stream tcp nowait root /usr/sbin/in.telnetd in.telnetd
#
Solaris kindly provides a packet sniffer : /usr/sbin/snoop
Usage: snoop
[ -a ] # Listen to packets on audio
[ -d device ] # settable to le?, ie?, bf?, tr?
[ -s snaplen ] # Truncate packets
[ -c count ] # Quit after count packets
[ -P ] # Turn OFF promiscuous mode
[ -D ] # Report dropped packets
[ -S ] # Report packet size
[ -i file ] # Read previously captured packets
[ -o file ] # Capture packets in file
[ -n file ] # Load addr-to-name table from file
[ -N ] # Create addr-to-name table
[ -t r|a|d ] # Time: Relative, Absolute or Delta
[ -v ] # Verbose packet display
[ -V ] # Show all summary lines
[ -p first[,last] ] # Select packet(s) to display
[ -x offset[,length] ] # Hex dump from offset for length
[ -C ] # Print packet filter code
[ filter expression ]
Example:
snoop -o saved host fred
snoop -i saved -tr -v -p19
Can't figure out how to get it to work though
Content type
Image
Digest
Size
554.4 MB
Last updated
over 7 years ago
docker pull netcrave/sparcsolaris