The Care and Feeding of ISDN4BSD
previous up next
11.2 Overview 11 Setting up an 11.4 ipr0 Setup in


11.3 isdnd.rc Setup

#---------------------------------------

#       isdn config file for gateway

#       --------------

#       last edit-date: [Sat Aug  1 15:20:32 1998]

#---------------------------------------

#==============================================================================

# SYSTEM section: isdnd global configuration parameters

#==============================================================================

system

ratesfile       = /etc/isdn/isdnd.rates # name & location of rates file

useacctfile     = yes                   # generate accounting info to file

acctall         = on                    # generate info for everything

acctfile        = /var/log/isdnd.acct   # name & location of accounting file

regexpr         = "PROVIDER outgoing call active"    # look for matches in log messages

regprog         = connectPROVIDER       # execute program whan match is found

rtprio          = 25                    # modify isdnd's priority

#==============================================================================

# PROVIDER - we call back

#==============================================================================

entry                           

name                    = PROVIDER      # name for reference

usrdevicename           = ipr           # ipr, tel, rbch

usrdeviceunit           = 0             # unit number

isdncontroller          = 0             # controller to use or -1 to use any

isdnchannel             = -1            # channel (1/2) to use or 0 or -1 for any

                                        # numbers used to verify at DIAL IN

local-phone-incoming    = 28            # this is my number

remote-phone-incoming   = 0040890123    # this one can call in

                                        # numbers used to DIAL OUT

local-phone-dialout     = 28            # this is my number

remote-phone-dialout    = 0040890123    # i call this number

remdial-handling        = first         # first, last or next

dialin-reaction         = callback      # accept, reject, ignore, answer, callback

dialout-type            = normal        # normal / calledback

b1protocol              = hdlc          # hdlc, raw

idletime-incoming       = 120           # incoming call idle timeout

idletime-outgoing       = 30            # outgoing call idle timeout

ratetype                = 0             # ratesfile entry to use

unitlength              = 90            # unitlength to assume

unitlengthsrc           = aocd          # none, rate, cmdl, conf, aocd

dialretries             = 3             # # of dial retries

recoverytime            = 5             # time to wait between 2 dial tries

callbackwait            = 1             # time to wait when calling back

What it does:

First, the system section specifies some obvious things you already know: the location of my ratesfile, i want to use an accounting file and the type of accounting information and the location of my accounting file. Also, i'd like to run my isdnd at realtime priority and this priority shall be 25.

Because i exchange mail by using UUCP over IP, i trigger the uucico program to look for work every time a connection is made. This is done in a small shell script named connectPROVIDER which is located under the /etc/isdn directory. The name of this script is given as a parameter to the regprog keyword. The parameter to the regexpr keyword specifies an expression which is searched for in isdnd's logging output, and if a match is found, the corresponding program is run. For my setup, this means that every time a connection is made, the script runs and checks for UUCP mail to be exchanged.

Thats all for the system section.

The entry section first defines the symbolic name PROVIDER. This name is used in the accounting records or on the full screen display.

Then the usrdevicename and the usedevicenumber are configured. This two items configure the device and unit number a B-channel is connected to (in the kernel) after a successful connection is made to a remote site.

The isdncontroller and isdnchannel specify which ISDN card (in case multiple ISDN cards are installed in a PC) and which B-channel on the card is to be used.

The telephone numbers contain the number of my extension at the PBX and the number of my provider. Please note the ``0'' in the number of my provider prepended to it for both cases! It is necessary for my PBX to dial a ``0'' to get a dial tone for outgoing calls and the PBX will add a ``0'' to each incoming call.

The b1protocol keyword is mandatory and is used to configure the Layer 1 protocol on the B-channel, for IP over raw HDLC it must be set to hdlc.

The keyword dialin-reaction is set to callback: when my provider has an IP packet for me, he will call me. With this setup, i4b will reject the call and call back immediately to setup the connection so i will get charged for the connection and not my provider: if my provider would get charged, he would charge me 1.5 time the money he would be charged.

The other keywords are relatively unimportant for the example and are explained in detail in section 6.1.3 of this handbook.


previous index next

Hellmuth Michaelis 2000-08-30