Sunlink DNI 7.0 to DNI 8.0 port problems

Sunlink DNI 7.0 to DNI 8.0 port problems

Post by Kevin Niederberg » Tue, 11 Aug 1998 04:00:00



I am doing a software port of a DNI 7.0 C program, running on SunOS on a
SPARC 2, to DNI 8.0 running on Solaris 2.6 on a SPARC 5.
The DNI 8.0 C API is considerably different to the calls that were
required for DNI 7.0 and so the software required major changes.
Initially I had a simulation program, that acted as a remote machine,
and sent messages to the DNI 8.0 program. This simulation program was
also running on the SPARC 5 and was able to send and receive messages
successfully using DECNet protocol within the same machine.
However when I shifted the SPARC 5 to site and connected it to a VAX the
program was unable to receive the messages sent to it from the VAX. The
DECNet software on the SPARC 5 receives the connect request (as this is
reported by 'dnincp') but it appears as though it does not know which
custom program to route the connect request to. I have included a
section of the of the software and the DECNet services file below.

C Source:

        /* Post the name of this DECnet Server */
        fdDNI = t_open("/dev/dni", O_RDWR, NULL);
        if (fdDNI == -1)
                LogErrorNoTB99("/dev/dni", "main", OPEN_FAILED, (long)
t_errno);

        /* Get the DECnet address for this service */
        if (!(sdn = (struct sockaddr_dn *)dni_getobject(NULL,
"LF_RCV")))
        {
                fprintf(stderr, "dniRcv: bad object LF_RCV\n",
                exit(1);
        }

        memset(&DNIBind, 0, sizeof(struct t_bind));
        DNIBind.addr.buf = (char *) sdn;
        DNIBind.addr.len = sizeof(struct sockaddr_dn);
        DNIBind.addr.maxlen = sizeof(struct sockaddr_dn);
        DNIBind.qlen = 1;

        /* Bind to the server address */
        error = t_bind(fdDNI, &DNIBind, &DNIBind);
        if (error < 0)
                LogErrorNoTB99(DNIERROR_MSG(t_errno), "main",
NAME_SET_FAILED, (long) t_errno);

        call = (struct t_call *) t_alloc(fdDNI, T_CALL, T_ALL);
        if (call == (struct t_call *) 0)
                LogErrorNoTB99(DNIERROR_MSG(t_errno), "main",
ALLOC_FAILED, (long) t_errno);

        /* Listen for a connection request */
        error = t_listen(fdDNI, call);
        if (error == -1)
        {  
                (void) t_free((char *)call, T_CALL);
                LogErrorNoTB99(DNIERROR_MSG(t_errno), "main",
LISTEN_FAILED, (long) t_errno);
        }

Services File:

#

#
# Copyright (c) 1991 by Sun Microsystems, Inc.
#

#Object         Number  Name            # Comment
#----           ------  ----            ---------

FAL             17                      # File Access (FAL/DAP-Version4)
NICE            19                      # NICE Process
MIRROR          25                      # Loopback Mirror
MAIL            27                      # VAX/VMS Personal Message Utility
CTERM           42                      # cterm protocol
DTR             63                      # DECnet Testing Tool
XDISPLAY        0       X$X0            # X Display Server (Server 0)

#
# The following lines were added Kevin Niederberger-Foxboro
# March 3, 1998
# MOHK OIS Upgrade Project
#
FL_RCV.EXE      0       FL_RCV.EXE              # Link from FCS to LCS
LF_RCV  0       LF_RCV          # Link from LCS to FCS
LW_RCV  0       LW_RCV          # Link from LCS to WCS
LB_RCV  0       LB_RCV          # Link from LCS to BS
WL_RCV  0       WL_RCV          # Link from WCS to LCS
WB_RCV  0       WB_RCV          # Link from WCS to BS
BL_RCV.EXE      0       BL_RCV.EXE              # Link from BS to LCS
BW_RCV  0       BW_RCV          # Link from BS to WCS

------------------- End of services file
--------------------------------------------------

The software sits and waits at the t_listen() call. When a connect
request for the service LF_RCV comes in, DECNet does not know to send it
to the above program. DNI 7.0 did not have a services file and appears
to allow you to create names arbitrarily within the software.
Is there anything that is missing from the software that is causing it
not to work? The software is based on the example source code that is
provided with Sunlink DNI 8.0.
I am now aware that there are a number of patches that need to be
installed for DNI 8.0. These have not yet been installed but is it
likely that this is what is causing the problem?

Please reply by email to :

Thankyou,
Kevin Niederberger,
Systems Engineer,
W. Arthur Fisher,
New Zealand.

 
 
 

1. Sunlink DNI (ver 7.0 to ver 8.0)

I am porting programs using Sunlink DNI 7.0 API to ver 8.0 API.
A requirment by the later was that a services file
(/etc/SUNWconn/dni/services) needs to be configured.
This was not required in the earlier version. I was therefore unsure about
how to go about in doing this.

Anyone out there...any experience??

Thanks in advance.

2. Q: C++ IDE & WP

3. SunLink DNI 8.0 Pobleme

4. Enlightenment 16

5. SunLink DNI 8.0 for Solaris 2.4_x86 ??

6. Creative Labs VideoBlaster driver ?

7. Help with SunLink DNI

8. csh: need help parsing variables

9. SunLink DNI - Desperate! Please help!

10. X with Decnet on Solaris (DNI 8.0)

11. DNI PROBLEMS

12. Cabletron DNI E2100-X