This directory also contains examples of ${DPCONF_DIR}/conf. conf.hub is an example of a central machine with several dp interfaces and a few modems. conf.leaf is an example of a machine with one dp interface and one modem. See the section on ${DPCONF_DIR}/conf for more information on this file.
The shell script dpctl is included in this directory. This can be used for starting, stopping, loading, unloading, reconfiguring, etc. See the section on dpctl for more information.
The dpconfig program is here as well. This is used in order to configure
interfaces into the system at run time, and to do the equivalent of
ifconfig dpX plumb.
The modifications to the standard PPP are small, but are necessary
for this mode of operation. The ppp program takes all the flags
that apply to the standard ppp program. In addition, if the dialup flag
is given to dp, it modifies the behavior in the following ways:
The BBN code had a good expect script capability for doing the
dialing. This capability has been expanded somewhat to allow better
error handling. The recv directive has been modified to accept any
number of alternative strings. One use this to accept all known
return codes from the modem. In addition, the timeout value on the
recv can now take on a value of 0. This means to only receive input
that has been already received when the recv is executed. Use of a
replay followed by a recv string 0 will immediately either succeed
or fail based on input received since the last mark. An example of this
is the following:
The connection requests sent from the kernel to the dpd program
include more than just the IP header. In fact, the whole packet is
usually transferred. Future versions could screen on all sorts of
criteria if people feel the need.
The uucp locking conventions have been updated to match those in use
by the Sun version of uucp. The Solaris 2.X version is quite different
from the Solaris 1.X version. Both of them seem to handle things properly
with uucp and friends. This is important to allow several programs to share
the available modems with the kernel networking.
A new flexible configuration file allows setting of many new options.
A later section devoted to this configuration file which will describe
the options in detail.
The timeout mechanisms have been expanded. A call wait timeout is
supported for the maximum waiting period between a call request and
the completion of the call. Once a call has failed, a failed call
timeout indicates the time to wait before initiating a new call. The
activity timeout is represented by one of 3 timeouts including
inactivity, tcp close, and non tcp, representing the conditions
when TCP connections are active, no TCP connections are active, and
non TCP traffic is active.
The concept of a modem has been expanded to include a modem rotary. A
rotary is a group of modems that are used in a round robin fashion.
With a bank of modems and phone lines, there are basically two ways
to pick which modem to use next: first available and next available.
The next available option corresponds to a rotary, a
round robin selection, and can be used in order to be more tolerant
of a single modem or phone failure. Given modems 1 to N, if modem
number 1 fails, the first available selection will always fail and
the next available selection will fail 1 out of N times.
Solaris allows use of a single modem for both dial in and dial out
through the use of two minor device numbers for each port. This
facility has been completely integrated into this software so that a
single port can be easily used for both incoming and outgoing calls.
A new program dplogin is included which shares a number of
functions with dpd. dplogin is used as a login shell for
incoming calls and uses the same configuration file as dpd. It
handles locking and logging in a compatible way.
A call log file is now generated for both incoming and outgoing
calls. Each line of the file corresponds to a successful call and
includes the following information: remote site name, tty device,
date and time of initiation of connection, total connect time,
initiating program (dpd or dplogin), protocol and port of initiating
request (like ip/tcp/smtp), and for both input and output, a report is
given of number of packets, bytes, and errors. The protocol and port
information is only available for outgoing calls. This information
can be very useful for analyzing call patterns and minimizing costs.
An auxiliary program facility is provided. If so configured,
whenever a modem connection is made, an auxiliary program can be
run. This program could, for instance, check queues for outgoing
traffic and make use of the the connection to transfer mail, print
jobs, or other similar queued files. This could be easily tuned in a
site-specific way to reduce the number of calls needed by taking advantage
of connections already established.
The sys-sunos5 directory includes the kernel modules for Solaris 2.X,
including the following:
The connection status of each interface is handled and a number
of timeouts are implemented. The timeouts include the following:
The timeouts can be set from the dp configuration file.
The dp_activity function keeps track of TCP connections
in progress and will notice when all connections close and the line
can be disconnected using one of the fast timeouts (tcp_close or
non_tcp).
The sys-sunos4 directory includes the kernel modules for Solaris 1.X,
including the following:
The connection status of each interface is handled and a number
of timeouts are implemented as in the sunos5 version.
This is a driver for the pppdial streams device
that allows the kernel to request the initiation of calls from the
dpd program.
The files dpif.c and ppp_dial.c are compiled into the dpif
loadable module.
Scripts for the US Robotics Courier and Telebit T1600, T3000, and WorldBlazer modems are provided
and have been tested.
You can modify these further to suit your configuration.
We provide a program called ckmailq. This looks in the mail spool
directory for outgoing mail that is not currently being processed. If
such mail exists, it starts up sendmail with the proper options.
Other similar programs could be written for other queued traffic such
as print jobs or uucp requests. This can be used to "poll" for SMTP
mail when a remote site can't initiate calls on its own.
We also provide a shell script called reset_ttymon which can be used
to get around some bugs in the Solaris 2.X tty subsystem. This script
will disable and enable a port monitor on the specific line and seems
to bring back ports that would otherwise mysteriously disable themselves.
h
This directory contains include files that are used by several of the
programs that comprise this distribution.
ppp
This directory contains a slightly modified version of the public
domain PPP code. This is based on ppp-2.1.2.
dpd
This is originally based on the diald program from BBN. It has been
heavily modified to handle PPP rather than slip, and to handle the
different kernel interfaces. This section will describe the major
differences in functionality.
mark
{
alternate
recv "CONNECT" "BUSY" "NO CARRIER" 30
alternate
log "Modem Timeout"
abort
}
{
alternate
replay
recv "CONNECT" 0
go
alternate
replay
recv "BUSY" 0
log "Busy"
busy
alternate
replay
recv "NO CARRIER" 0
log "No Carrier"
abort
}
This segment of a script will wait up to 30 seconds to accept either
CONNECT, BUSY, or NO CARRIER, then immediately do the correct
branch. This was impossible to handle in a timely way using the
original code.
sys-sunos5
pppasync.c
The pppasync streams module, which packetizes data and does
PPP header compression. It talks to the serial port module
below, and the vjc module above.
vjc.c
This is the Van Jacobson TCP header compression software that has
been incorporated into a streams driver. It talks to the pppasync
module below, and talks to the lower half of the dp driver above.
dp.c
This file is a cloneable, modloadable, multiplexing streams driver.
It supports the DLPI (Data Link Provider Interface, Version 2.0).
sys-sunos4
pppasync.c
The pppasync streams module, which packetizes data and does
PPP header compression. It talks to the serial port module
below, and the vjc module above.
This is linked to the sunos5 version.
vjc.c
This is the Van Jacobson TCP header compression software that has
been incorporated into a streams driver. It talks to the pppasync
module below, and talks to the lower half of the dp driver above.
This is linked to the sunos5 version.
dpif.c
This file contains a streams module and a BSD network device driver.
ppp_dial.c
dptrace
Dptrace is a simple program that prints the request trace file. As
each dialup request arrives, the dpd program writes
the current time and the current request to the file
${DPLOG_DIR}/req.trace. This program reads that file and formats the
requests into a human-readable format. The program can be helpful in
debugging and tuning the network.
modem
This directory contains a program to set modem options on Hayes
compatible modems. The setmodem command can be invoked as:
setmodem [-v] scriptfile device [baud]
Scriptfile contains a number of AT commands that will be fed to the
modem. The setmodem program knows enough to expect OK returns from
the modem and waits until the OK to proceed to the next AT command.
aux
The aux directory contains the sources for auxiliary programs that
can be run when connections are established. If so configured in the
${DP_CONFDIR}/conf file, whenever a modem connection is made,
an auxiliary program can be run.
access
The access directory contains several example files for controlling
remote access and timeouts. These are installed in ${DPACCESS_DIR}.
script
The script directory contains several dialing and login scripts.
These can be used as examples for your particular modems, etc.
These files are installed in ${DPSCRIPT_DIR}.
cron
The cron directory contains two shell programs (daily and monthly)
that can be run via crontab in order to keep the ${DPLOG_DIR} directory
from getting too large. The file dp.crontab contains the two entries
that need to be manually entered into root's crontab in order for these
programs to be run via cron.
Kirk Smith / ks@acn.purdue.edu
Last updated: 28 July 1995