[Simh] MicroVAX 3900 networking problem on Mac OS X
Vorländer, Martin
MV at pdv-systeme.de
Fri Jan 2 05:04:00 EST 2015
A Happy New Year to everyone around!
I'm in the process of updating my SIMH installation (on Mac OS X.9.5 and
X.10.1), and have run into troubles with the microvax3900 networking.
I'm using a git clone of the simh/simh repository:
MicroVAX 3900 simulator V4.0-0 Beta
Simulator Framework Capabilities:
64b data
64b addresses
Ethernet Packet transport:PCAP:TAP:UDP
Idle/Throttling support is available
Virtual Hard Disk (VHD) support
Asynchronous I/O support
Host Platform:
Compiler: GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.56)
Simulator Compiled: Dec 30 2014 at 14:59:06
Memory Access: Little Endian
Memory Pointer Size: 64 bits
Large File (>2GB) support
PCRE RegEx support for EXPECT commands
OS clock tick size (time taken by msleep(1)): 2ms
OS: Darwin macmv.goslar.hit.pdv 13.4.0 Darwin Kernel Version 13.4.0: Sun Aug 17 19:50:11 PDT 2014; root:xnu-2422.115.4~1/RELEASE_X86_64 x86_64
git commit id: d5f02124
My network setup looks like
; (outside world)
SET XQ ENABLED
SET XQ MAC=08-00-2B-AA-BB-CC
SET XQ TYPE=DELQA
ATTACH XQ0 en0
;
; (host connection)
! /sbin/kextload -v /Library/Extensions/tap.kext
SET XQB ENABLE
SET XQB MAC=08-00-2B-AA-BB-CE
SET XQB TYPE=DELQA
ATTACH XQB0 tap:tap0
! /sbin/ifconfig tap0 192.168.11.100 netmask 255.255.255.0 up
When I boot the VAX, the DECnet startup hangs at "NCL enable dns clerk"
in NET$DNS_CLERK_STARTUP.NCL, so I disabled it for now.
TCP/IP startup does not hang, but takes a long time defining the
interfaces (I suspect a timeout) and the DHCP client throws
%TCPIP-I-DHCPC_STRD_CLNT, DHCP client started with PID 00000112
[...]tcpip$dhcp_client_conf.exe;1: internal error in DHCP agent
%TCPIP-E-DHCPC_SYSERR, unexpected system error
%TCPIP-E-DHCPCONFERR, DHCP client failed to configure interface QE0
The VMS TCP/IP setup really is standard:
$ tcpip show interface
Packets
Interface IP_Addr Network mask Receive Send MTU
LO0 127.0.0.1 255.0.0.0 2 2 4096
QE0 0 0 0
QE1 192.168.11.6 255.255.255.0 0 1 0
Trying to ping the Mac through QE1 (i.e. XQB0) results in
$ tcpip ping 192.168.11.100
PING 192.168.11.100 (192.168.11.100): 56 data bytes
ping: sendto: message too long
ping: wrote 192.168.11.100 64 chars, ret=-1
After booting the CPU the network stats look like
sim> SHOW XQ STATS
XQ Ethernet statistics:
Recv: 0
Dropped: 0
Xmit: 0
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 0
Setup: 0
Loopback: 0
ReadQ count: 0
ReadQ high: 0
Ethernet Device:
Name: en0
Reflections: 1
Self Loopbacks Sent: 2
Self Loopbacks Rcvd: 2
Host NIC Address: 00:25:4B:A8:3B:FC
Packets Sent: 3
Packets Received: 1
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 1
Read Queue: Loss: 0
Peak Write Queue Size: 1
BPF Filter: (((ether dst 08:00:2B:AA:BB:CC)) and not ((ether src 08:00:2B:AA:BB:CC))) or ((ether dst 08:00:2B:AA:BB:CC) and (ether src 08:00:2B:AA:BB:CC)) or ((ether dst 00:25:4B:A8:3B:FC) and (ether proto 0x9000))
sim> SHOW XQB STATS
XQ Ethernet statistics:
Recv: 0
Dropped: 0
Xmit: 0
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 0
Setup: 0
Loopback: 0
ReadQ count: 0
ReadQ high: 0
Ethernet Device:
Name: tap0
Reflections: 0
Self Loopbacks Sent: 2
Self Loopbacks Rcvd: 0
Packets Sent: 3
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 0
Read Queue: Loss: 0
Peak Write Queue Size: 1
After VMS boot and shutdown (with supposedly some traffic caused by the
DHCP client and the pings), this looks like
sim> SHOW XQ STATS
XQ Ethernet statistics:
Recv: 0
Dropped: 0
Xmit: 0
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 1
Setup: 0
Loopback: 0
ReadQ count: 0
ReadQ high: 0
Ethernet Device:
Name: en0
Reflections: 1
Self Loopbacks Sent: 2
Self Loopbacks Rcvd: 2
Host NIC Address: 00:25:4B:A8:3B:FC
Packets Sent: 3
Packets Received: 1
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 1
Read Queue: Loss: 0
Peak Write Queue Size: 1
BPF Filter: (((ether dst 08:00:2B:AA:BB:CC)) and not ((ether src 08:00:2B:AA:BB:CC))) or ((ether dst 08:00:2B:AA:BB:CC) and (ether src 08:00:2B:AA:BB:CC)) or ((ether dst 00:25:4B:A8:3B:FC) and (ether proto 0x9000))
sim> SHOW XQB STATS
XQ Ethernet statistics:
Recv: 0
Dropped: 0
Xmit: 0
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 1
Setup: 0
Loopback: 0
ReadQ count: 0
ReadQ high: 0
Ethernet Device:
Name: tap0
Reflections: 0
Self Loopbacks Sent: 2
Self Loopbacks Rcvd: 0
Packets Sent: 3
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 0
Read Queue: Loss: 0
Peak Write Queue Size: 1
which I would interpret as "no packets delivered".
Using a working SIMH/VAX version (VAX MP, based on 3.8-2) with the same system disk, this comes out as
sim> SHOW XQ STATS
XQ Ethernet statistics:
Recv: 553
Dropped: 0
Xmit: 21
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 2
Setup: 4
Loopback: 0
ReadQ count: 0
ReadQ high: 2
Ethernet Device:
Name: en0
Reflections: 1
Self Loopbacks Sent: 4
Self Loopbacks Rcvd: 4
Host NIC Address: 00:25:4B:A8:3B:FC
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 2
Read Queue: Loss: 0
Peak Write Queue Size: 1
sim> > SHOW XQB STATS
XQ Ethernet statistics:
Recv: 0
Dropped: 0
Xmit: 3
Xmit Fail: 0
Runts: 0
Oversize: 0
SW Reset: 2
Setup: 4
Loopback: 0
ReadQ count: 0
ReadQ high: 1
Ethernet Device:
Name: tap0
Reflections: 0
Self Loopbacks Sent: 4
Self Loopbacks Rcvd: 0
Host NIC Address: C6:4A:FE:85:23:BD
Asynch Interrupts: Disabled
Read Queue: Count: 0
Read Queue: High: 0
Read Queue: Loss: 0
Peak Write Queue Size: 1
I'm at a loss how to proceed. Anyone got some hints where to look?
TIA,
Martin
P.S.: Trying to get this to work I tried disabling the threaded version like
diff --git a/makefile b/makefile
index 871cea5..2895360 100644
--- a/makefile
+++ b/makefile
@@ -310,6 +310,7 @@ ifeq ($(WIN32),) #*nix Environments (&& cygwin)
OS_LDFLAGS += -lrt
$(info using librt: $(call find_lib,rt))
endif
+ ifeq (,$(DONT_USE_READER_THREAD))
ifneq (,$(call find_include,pthread))
ifneq (,$(call find_lib,pthread))
OS_CCDEFS += -DUSE_READER_THREAD
@@ -340,6 +341,7 @@ ifeq ($(WIN32),) #*nix Environments (&& cygwin)
LIBEXT = $(LIBEXTSAVE)
endif
endif
+ endif
# Find available RegEx library. Prefer libpcreposix.
ifneq (,$(call find_include,pcreposix))
ifneq (,$(call find_lib,pcreposix))
and think I found a bug in sim_ether.c:
diff --git a/sim_ether.c b/sim_ether.c
index 059f7ac..f5d9b8c 100644
--- a/sim_ether.c
+++ b/sim_ether.c
@@ -1934,7 +1934,7 @@ else
#if !defined (USE_READER_THREAD)
#ifdef USE_SETNONBLOCK
/* set ethernet device non-blocking so pcap_dispatch() doesn't hang */
- if (pcap_setnonblock (dev->handle, 1, errbuf) == -1) {
+ if (pcap_setnonblock (*handle, 1, errbuf) == -1) {
sim_printf ("Eth: Failed to set non-blocking: %s\r\n", errbuf);
}
#endif
@@ -1946,7 +1946,7 @@ else
* the tcpdump mailinglist: http://seclists.org/tcpdump/2010/q1/110
*/
int v = 1;
- ioctl(pcap_fileno(dev->handle), BIOCIMMEDIATE, &v);
+ ioctl(pcap_fileno(*handle), BIOCIMMEDIATE, &v);
}
#endif /* defined (__APPLE__) */
#endif /* !defined (USE_READER_THREAD) */
Martin Vorländer
Software-Entwicklung
PDV-Systeme GmbH
Dörntener Straße 2 A
DE-38644 Goslar
Tel +49 (0) 5321 3703-33
Fax +49 (0) 5321 8924
E-Mail MV at pdv-systeme.de
www.pdv-systeme.de
Geschäftsführer: Christian Daniel, Amtsgericht Braunschweig HRB 110209
Unsere Allgemeinen Geschäftsbedingungen finden Sie unter: www.pdv-systeme.de/kontakt/agb.htm
Hinweis:
Diese E-Mail ist vertraulich. Wenn Sie nicht der vorgesehene Empfänger sind, verwenden Sie bitte keine Inhalte dieser E-Mail und leiten Sie diese auch nicht weiter. Wenn Sie fälschlicherweise diese E-Mail bekommen haben, informieren Sie uns bitte umgehend und löschen dieses Dokument.
More information about the Simh
mailing list