Linux-Networking Digest #689, Volume #9          Sun, 27 Dec 98 17:13:44 EST

Contents:
  US modem in UK machine says "NO DIAL TONE" (Chris Rankin)
  Re: PPP problem (Paul B. Brown)
  eql_enslave cannot find libc.so.4? (Jon & Barry Gilman)
  Re: IP (Paul B. Brown)
  Re: How do you do multiple ISPs through PPP. (Paul B. Brown)
  Re: pppd problem (Paul B. Brown)
  Re: IP Masquerading (Mattias Axelsson)
  Re: Modem choice for Linux (Duncan Simpson)
  Re: US Robotics Model 5686 (Duncan Simpson)
  Re: Please Help..... (Liang-Shing Ng)
  Re: Can anyone tell me how can I setup the dialup network connection in linux (Paul 
B. Brown)
  Re: Time Synch (Ivo Naninck)

----------------------------------------------------------------------------

From: Chris Rankin <net.bellsouth@{no.spam}rankinc>
Subject: US modem in UK machine says "NO DIAL TONE"
Date: Sun, 27 Dec 1998 20:20:06 +0000

Hi,
I have tried to install an old 33.6 Kbps modem into an even older UK
machine. The card goes in; I use isapnp and setserial to put the thing
on COM4, IRQ 5, port 0x2e8; I tell pppd to use /dev/ttyS3; the phone
line IS plugged in. This is what I see in my message log:

Dec 27 17:02:07 WittsEnd chat[421]: abort on (\nBUSY\r)
Dec 27 17:02:07 WittsEnd chat[421]: abort on (\nVOICE\r)
Dec 27 17:02:07 WittsEnd chat[421]: abort on (\nNO ANSWER\r)
Dec 27 17:02:07 WittsEnd chat[421]: abort on (\nNO DIALTONE\r)
Dec 27 17:02:07 WittsEnd chat[421]: abort on (\nNO DIAL TONE\r)
Dec 27 17:02:07 WittsEnd chat[421]: abort on
(\nRINGING\r\n\r\nRINGING\r)
Dec 27 17:02:07 WittsEnd chat[421]: send (^MATZ^M)
Dec 27 17:02:07 WittsEnd chat[421]: expect (OK)
Dec 27 17:02:07 WittsEnd chat[421]:
Dec 27 17:02:07 WittsEnd chat[421]: ^MATZ^M^M
Dec 27 17:02:07 WittsEnd chat[421]: OK
Dec 27 17:02:07 WittsEnd chat[421]:  -- got it
Dec 27 17:02:07 WittsEnd chat[421]: send (ATH0^M)
Dec 27 17:02:07 WittsEnd chat[421]: timeout set to 60 seconds
Dec 27 17:02:07 WittsEnd chat[421]: expect (OK)
Dec 27 17:02:07 WittsEnd chat[421]: ^M
Dec 27 17:02:07 WittsEnd chat[421]: ATH0^M^M
Dec 27 17:02:07 WittsEnd chat[421]: OK
Dec 27 17:02:07 WittsEnd chat[421]:  -- got it
Dec 27 17:02:07 WittsEnd chat[421]: send (ATDT08450798666^M)
Dec 27 17:02:07 WittsEnd chat[421]: expect (CONNECT)
Dec 27 17:02:07 WittsEnd chat[421]: ^M
Dec 27 17:02:09 WittsEnd chat[421]: ATDT08450798666^M^M
Dec 27 17:02:09 WittsEnd chat[421]: NO DIAL TONE^M
Dec 27 17:02:09 WittsEnd chat[421]:  -- failed
Dec 27 17:02:09 WittsEnd chat[421]: Failed ( NO DIAL TONE^M)

The modem seems to be talking to the motherboard OK, so is there some
subtle difference between the phone-jacks on each side of the Atlantic?

Cheers,
Chris.

PS I have exactly the same problem under Windows 95 too.

------------------------------

From: [EMAIL PROTECTED] (Paul B. Brown)
Subject: Re: PPP problem
Date: 27 Dec 1998 20:31:34 GMT

Andrew,

I had an external USR Sportster 33.6 and the factory default settings
worked for me.  I used the following to startup my ppp connection:

TELEPHONE=555-1212      # The only telephone number
ACCOUNT=<username>      # The account name for logon
PASSWORD=<password>     # The password for this account
export TELEPHONE ACCOUNT PASSWORD

DIALER_SCRIPT=/etc/ppp/ppp-on-dialer

exec /usr/sbin/pppd debug lock modem crtscts /dev/ttyS1 38400 \
        asyncmap 20A0000 escape FF kdebug 0 0.0.0.0:0.0.0.0 \
        noipdefault netmask 255.255.255.0 defaultroute connect \
        $DIALER_SCRIPT

======================= /etc/ppp/ppp=on=dialer ============================
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
exec chat -v                                            \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         60                              \
        OK              ATE1Q0S0=0M0DT$TELEPHONE        \
        CONNECT         ''                              \
        ogin:--ogin:    $ACCOUNT                        \
        assword:        \\q$PASSWORD
===========================================================================

. . . and it should work.  Of course, this assumes that you do not have a
static IP address and that your modem is on COM2.  Change the parameters
above to suit your taste.

Try it and let me know . . . .

Paul

===========================================================================
Paul B. Brown                          [EMAIL PROTECTED]
President
Brown Technologies Network, Inc.       http://www.btechnet.com/

Unix Systems Administration            "Sailing is a state of mind . . . ."
===========================================================================

In article <[EMAIL PROTECTED]>,
        "Andrew L. Kopec" <[EMAIL PROTECTED]> writes:
>I have installed Caldera's OpenLinux 1.3.  I tried to
>configure PPP using vi command as shown on the instructions from the manual
>and books, using KDE's PPP program, and X Window's X-ISP but nothing seem to
>work.
>
>According to both KDE and X-ISP, I was able to connect to my ISP server but
>dropped to dead after 30 seconds.  I am not exactly sure what's wrong.
>
>I discovered that my modem was not set up so I had to run LISA to set it up
>but found that a few modems are listed.
>
>I sent the e-mail to my ISP administrator and he said that he's not familiar
>with LINUX.  He said that several of his LINUX customers are connecting to
>his server without any problem.  He gave me the procedure to make sure how
>to set up PPP properly.  It's the same method I use to set it up in Windows
>98/98 and NT.  I don't have any problem with 95/98 and NT so far.
>
>I am going to give you the information about my modem and ISP's settings.
>
>My modem is USR Sportster 33.6 internal.  (It's not in LISA so I tried both
>Hayes comptabile and not on the list)
>
>My ISP -- IPs are automatically assigned so it has to be dynamic IP.
>               Only DNS entries are required (there's 2 entries) and I am
>postivie they are correct.
>               Domain name and host name are required to be entered along
>with DNS entries.
>
>I am using XON/XOFF handshake instead of RTC/STC(?).  I have tried both but
>no luck.
>
>I have set the speed to 38400 instead of 57600.
>
>Any suggestion?  I can't wait to run PPP via LINUX.
>
>Later!
>
>--andrew
>
>PS: My e-mail address is [EMAIL PROTECTED]  Thanks!


------------------------------

From: Jon & Barry Gilman <[EMAIL PROTECTED]>
Subject: eql_enslave cannot find libc.so.4?
Date: Sun, 27 Dec 1998 11:48:57 -0500

Hello everyone and Happy Holidays!

    I have been beating my head against the wall trying to figure out
why I get the following message after issuing the command, eql_enslave
ppp1 mtu xxx (where xxx is the mtu number):

            The message reads as follows: libc.so.4 cannot be
found......

Does anyone know how to get rid of this message? ie. putting this
library in the right place or re-compiling this utility so it knows
where to find the library?

Here is a list of what I have tried so far......
    I can use this utility on my home machine so and I have located the
libc.so.4 library. It is found in /usr/i486-linuxaout.....Therefore, I
made this directory at work and filled it with the all the libraries
from my home machine.....As you may have guessed this did not work.
    Next, I tried moving the file into the same directory as the
utility....Again, no luck.....

    So, now I'm out of ideas. HELP! Thanks!
                                                        Sincerely,
                                                                Brian
Gilman


------------------------------

From: [EMAIL PROTECTED] (Paul B. Brown)
Subject: Re: IP
Date: 27 Dec 1998 20:35:44 GMT

>Everytime i login on my ISP i receive a different IP number
>I can't receive emails on my linux comp
>is there a way to combine linux standard mail with email?

Hi,

If you are trying to setup a mail sever with a DHCP address, you are in
for a difficult time.  No, let's face it, you're screwed.  E-mail servers
require MX records in the DNS and thus a static IP address for the host.

Bottom line: no static IP address = no e-mail server.

However, you could get your ISP to use their e-mail server for your MX
record resolution.  This way your e-mail goes to their server and you can
use a POP3 or IMAP4 client to read your e-mail.  Will this do?

Paul

===========================================================================
Paul B. Brown                          [EMAIL PROTECTED]
President
Brown Technologies Network, Inc.       http://www.btechnet.com/

Unix Systems Administration            "Sailing is a state of mind . . . ."
===========================================================================


------------------------------

From: [EMAIL PROTECTED] (Paul B. Brown)
Subject: Re: How do you do multiple ISPs through PPP.
Date: 27 Dec 1998 20:38:58 GMT

>I don't know enough about linux to know if this would work but I've done
>stuff like this with dos/win31. Set up a different ppd script for each isp,
>and add lines in each one to copy a custom resolv.conf, say from
>resolv1.conf to resolv.conf.

It's all in the way you execute your pppd command.  pppd will look to see
if you are using ppp0 when it connects.  If it doesn't then ppp0 is used.
If it does then ppp1 is used and so on.  The trick is how to setup the
routing.  Only one can be your default gateway.  The other MUST be
dedicated to vairous ranges of IP addresses.  How are you going to handle
the routing?

Paul

===========================================================================
Paul B. Brown                          [EMAIL PROTECTED]
President
Brown Technologies Network, Inc.       http://www.btechnet.com/

Unix Systems Administration            "Sailing is a state of mind . . . ."
===========================================================================


------------------------------

From: [EMAIL PROTECTED] (Paul B. Brown)
Subject: Re: pppd problem
Date: 27 Dec 1998 20:42:07 GMT

>OK - here is the great problem!
>
>I am currently connected to the internet through win95 dial-up networking.
>However, I am trying to get PPP up on Linux.  PPP is compiled into the
>kernel - I have PPP version 2.3.1 - yes, the beta.  I got my PnP modem
>working with Linux, making me feel very proud.  However, when I connect to
>my ISP using kppp, minicom, ddial, or ezdial, and start a PPP session, the
>ppp daemon dies.  This especially upsets me when I use ezDial, because the
>terminal screen says 'pppd really did die.'  Well, though I don't like the
>feelings engendered by the remark, I'll go on.
>
>OK, I have a kppp script all ready to go.  I have PPP set up, and the
>connection goes all the way down to the garbage characters.  When pppd kicks
>in, it DISCONNECTS me from my ISP <it's not a PAP/CHAP thing>.  This ONLY
>happens when pppd kicks in.  I've tried this manually with minicom and it
>STILL does it.
>
>The commands I use are:
>
>pppd -d -detach /dev/ttyS3
>
>PPP is definitely set up in my kernel!  Additionally, if I just run pppd
>without any commands, garbage characters come up on the screen.  Please, oh
>Linux gods, help me.

What about the other information that pppd wants before connecting to the
other pppd?  Here is my pppd command with associated chat script:

TELEPHONE=555-1212      # The only telephone number
ACCOUNT=username        # The account name for logon
PASSWORD=password       # The password for this account
export TELEPHONE ACCOUNT PASSWORD

DIALER_SCRIPT=/etc/ppp/ppp-on-dialer

exec /usr/sbin/pppd debug lock modem crtscts /dev/ttyS1 38400 \
        asyncmap 20A0000 escape FF kdebug 0 0.0.0.0:0.0.0.0 \
        noipdefault netmask 255.255.255.0 defaultroute connect \
        $DIALER_SCRIPT

======================= /etc/ppp/ppp=on=dialer ============================
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
exec chat -v                                            \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         60                              \
        OK              ATE1Q0S0=0M1DT$TELEPHONE        \
        CONNECT         ''                              \
        ogin:--ogin:    $ACCOUNT                        \
        assword:        \\q$PASSWORD
===========================================================================

Let me know . . . .

Paul

===========================================================================
Paul B. Brown                          [EMAIL PROTECTED]
President
Brown Technologies Network, Inc.       http://www.btechnet.com/

Unix Systems Administration            "Sailing is a state of mind . . . ."
===========================================================================


------------------------------

From: Mattias Axelsson <[EMAIL PROTECTED]>
Subject: Re: IP Masquerading
Date: Sun, 27 Dec 1998 21:49:09 +0100

If you compile with 'make zImage',
try with 'make bzImage' instead.

/Mattias Axelsson
[EMAIL PROTECTED]


Gary Blydenburgh Jr wrote:
> 
>  I am trying to setup IP Masquerading  for RH 5.2.
> I ran into a problem with setting up my kernel per the HOW TO doc.
> When I run /sbin/lilo to allow my new kernel to boot I get the following
> error
> "Kernel Too Big" and then it stops.  Can someone tell me why this is
> happening, and
> more importantly how do I get around it.  I have no problem
> re-installing th OS if needed.

------------------------------

From: [EMAIL PROTECTED] (Duncan Simpson)
Subject: Re: Modem choice for Linux
Date: 21 Dec 1998 16:49:43 GMT

In <[EMAIL PROTECTED]> Kazin <[EMAIL PROTECTED]> writes:

>David Shepherd wrote:
>> 
>> I need to buy a modem by the end of this week. Although I will initially
>> be using it under Win NT to access a Dec Alpha based Unix cluster at
>> work, I would like in due course to have it running under Linux as well.
>> 
>> Choosing for NT compatibility would appear to be reasonably
>> straightforward, but is there anything important I need to bear in mind
>> for Linux compatibility? Will voice/fax modems work under Linux, or
>> would I be better off with a plain no-frills modem?

>       I've always been of the opinion that the only modem worth buying at all
>is the USR (now 3Com) Courier v.Everything.  I've been using the same
>two modems for the past 4 years now, upgrading for free along the way. 
>I bought them when I was running a BBS full-time, and the ability to
>connect reliably to anything on the planet was a key factor.  I still
>find that they perform better and more reliably than anything else, and
>you can always upgrade them for free.

Assuming your budget is not big enough for one of those get an
external modem. Almost any model will speak Hayes AT commands enough
for you to send FAXes, connect any ISP, and most stuff you care
about. You also get the benefit of ebing able to power cycle the modem
when your computer is unwilling to hang up and light that tell you
want is happening (in particular whether you are increasing your phone
bill).

Duncan (-:

------------------------------

From: [EMAIL PROTECTED] (Duncan Simpson)
Crossposted-To: comp.os.linux.hardware,comp.os.linux.misc,comp.os.linux.setup
Subject: Re: US Robotics Model 5686
Date: 21 Dec 1998 16:33:43 GMT

In <75k2ff$[EMAIL PROTECTED]> "Art" <[EMAIL PROTECTED]> writes:


>Doug wrote in message <[EMAIL PROTECTED]>...
>>Have a question. I know some US Robotics runm with Linux. I know model#
>>5685,5687 do.
>>I can get a 5686,it is an external fax Modem. I know they say all
>>externals worek but had problems with some company's . Soince my ISP
>>uses US Robotics X2 and V90,I figured I would go with this mode,m. Just
>>would like to know if anyone is using this modem or who knows if model
>>5686 will run. I have been to a lot of web pages about modems
>>researching did not see this one
>Hmm.

>I'm having a problem logging on!

>I am using EzPPP V1.09b, but I didn't have an option for selecting modems.
>I just accepted the defaults, but it's not working!

You have been fooled by windows. All modems speak Hayes commands. If windows
had a "generic hayes" option it would work with any current modem. You rarely
need more than an option for any hayes modem for most of the rest of the features
too. (FAX has been standardised and ATZ generally enables all speeds anyway).

Connect with kermit next time and keep a record of the prompts. This
will allow you to write a good expect script. There are 3 major
vairants I know of:

1st variation: authenticate with PAP when connected (what my ISP used to like)
ATZ OK
"ATDT <phone number>" CONNECT
[now hit pppd and it will use PAP, CHAP or MSCHAP]

2nd: unix shell and some portmasters (my ISP's current configuration)
ATZ OK
"ATDT <phone number>"
ogin: me
ssword: secret
[now hit pppd]

3rd varaiton: Various others sorts of annexes (old ECS annex)
ATZ OK
"ATDT <phone number>"
ogin: me
ssword: secret
otocol: ppp
[Now hit pppd]

me and secret are not a valid user and password combination. (Actually I
have 3 dail-up accounts at present...). My USR external olnly works reliably
with the lid taken off. I will be getting a V90 modem from someone other than
USR (according to my ISP people using USR modems have trouble connecting to
them).



------------------------------

From: [EMAIL PROTECTED] (Liang-Shing Ng)
Crossposted-To: comp.os.linux.questions,comp.os.linux.setup,comp.os.linux.advocacy
Subject: Re: Please Help.....
Date: 23 Dec 1998 21:22:22 -0000


When I installed an IP masquarade network, this was pretty much what I
needed:

http://metalab.unc.edu/mdw/HOWTO/mini/IP-Masquerade.html

I will be surprised if you haven't seen it yet.

It should provide you sufficient details to get it done. Just to
summarise:

1) Have you had all your PCs networked together? e.g. You are able to
telnet into your Linux box from your Windows box?

2) (This was from about a year ago. Maybe the procedure is still the
same.) You need to recompile the kernel to enable the IP-masquerade. In
the old kernels those days, you have to enable the "EXPERIMENTAL" part
of kernel config before you can see "IP-MASQUERADE" in the menu. This
was quite a stupid kernel config setup. Beware.

3) After reinstalling the kernel, your kernel is now capable of doing
the IP-masq. But you need to follow the Howto instructions, run the
"ipfwadm" commands etc to actually activate it. During testing, you
might want to do it on command line. After you are sure, you could write
it into your /etc/rc.d/rc* files.

4) Finally, go to control panel on your windows box to setup the gateway
info.



In article <[EMAIL PROTECTED]>,
Ralph H. Stoos Jr. <[EMAIL PROTECTED]> wrote:
>To all potential helpers,
>
>My sons are driving me crazy asking to use my main computer to 'surf'
>all the time.  They each have their own machines on the home network but
>mine is the only one with a modem and an ISP account.  I know it is
>possible to set a machine up as a router to route all my network through
>the modem.
>
>I have a slower Pentium (AMD K2 actually) machine that I can dedicate to
>this task.  I have reams of RedHat and general Linux documentation that
>talks all about IP Masquerading and routing and all that.  Which pieces
>of this do I need?  Recently, I downloaded Squid from a web site to
>provide the firewalling for security.   For a short time I would even be
>willing to have a security breach until I got the whole network routed.
>
>IP masquerading will be necessary because all the machines on my network
>have IP addresses set to  10.10.10.XXX
>
>Is there adefinitive document that explains this whole process?  If
>someone can get me there I promise to write a complete procedure and
>publish it to all the Linux newsgroups.
>
>
>Thank you and Happy holidays
>
>
>Ralph
>



------------------------------

From: [EMAIL PROTECTED] (Paul B. Brown)
Crossposted-To: alt.linux,alt.os.linux,hk.comp.os.linux,tw.bbs.comp.linux
Subject: Re: Can anyone tell me how can I setup the dialup network connection in linux
Date: 27 Dec 1998 20:19:04 GMT

Hello,

>Can anyone tell me how can I setup the dialup network connection in linux?

That's kind of an open ended question.  Can you clarify a little:

1. Is your connection 24x7?
2. Do you want to use On Demand Dialing?
3. Do you want to manually connect and then disconnect?

I can tell you my case.  I have a 24x7 connection using a v.90 modem.  I
use 4 scripts to do this plus a couple of commands in my bootup scripts.

Excerpts from two of my boot scripts:

========================= /etc/rc.d/rc.serial =============================
cd /dev
SETSERIAL="/bin/setserial -b"
PORTS=`echo cua? cua??`
${SETSERIAL} -bg ${PORTS}
===========================================================================

========================= /etc/rc.d/rc.local ==============================
/bin/setserial /dev/cua1 spd_vhi
/usr/sbin/apppd >> /var/log/apppd.log 2>&1 &
===========================================================================

The four scripts that control my PPP connection:

========================= /usr/sbin/apppd =================================
#!/bin/bash
#
# apppd: This script is the wrapper around the ppp-on and ppp-off shell
#        scripts.  These scripts will make sure a PPP connection stays
#        active.  If a down PPP state is detected the phone is redialed
#        and the PPP connection is re-established.
#
PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/X11/bin
PATH=$PATH:/usr/openwin/bin:/etc
export PATH

WHOAMI=`whoami`

if [ "$WHOAMI" != "root" ] ; then
   echo "apppd: you must be root to run this process.  (user="$WHOAMI")"
   logger "apppd: you must be root to run this process.  (user="$WHOAMI")"
   exit 1
fi

logger "apppd: begin pppd process."

NO=""
CLEANUP_TIME=5
SNOOZE_TIME=300
old_packet_count=0

is_ppp_active=`ifconfig ppp0 | grep "UP POINTOPOINT RUNNING"`

if [ "$is_ppp_active" = "$NO" ] ; then
   logger "apppd: clean up the pppd daemon."
   ppp-off
   sleep $CLEANUP_TIME

   logger "apppd: bring up the pppd daemon."
   ppp-on
fi

while true ; do
   sleep $SNOOZE_TIME
   is_ppp_active=`ifconfig ppp0 | grep "UP POINTOPOINT RUNNING"`
   cur_packet_count=`ifconfig ppp0 | grep RX | cut -d":" -f2 | cut -d" " -f1`

#  check to see if the ppp connection is down, if so then cycle the ppp
#  connection.
   if [ "$is_ppp_active" = "$NO" ] ; then
      logger "apppd: checking pppd status: inactive (ifconfig test)."
      logger "apppd: clean up the pppd daemon."
      ppp-off
      sleep 15
      logger "apppd: bring up the pppd daemon."
      ppp-on
      old_packet_count=0

#  check to see if there is any activity on the line during the last five
#  minutes, if so then do nothing.  If not, ping target
   elif [ $cur_packet_count -ne $old_packet_count ] ; then
      old_packet_count=$cur_packet_count

#  Ping target 5 times and check status, cycle ppp if needed.
   else
      TS=`ifconfig ppp0 | grep "P-t-P" | cut -d: -f3 | cut -d" " -f1`
      ping -c5 -i6 -q $TS > /dev/null 2>&1
      cur_packet_count=`ifconfig ppp0 | grep RX | cut -d":" -f2 | cut -d" " -f1`

      if [ $cur_packet_count -ne $old_packet_count ] ; then
         old_packet_count=$cur_packet_count
      else
         logger "apppd: checking pppd status: inactive (ping test)."
         logger "apppd: clean up the pppd daemon."
         ppp-off
         sleep 15
         logger "apppd: bring up the pppd daemon."
         ppp-on
         old_packet_count=0
      fi
   fi
done

exit 0
===========================================================================

========================= /usr/sbin/ppp=on ================================
#!/bin/sh
#
# Script to initiate a ppp connection. This is the first part of the
# pair of scripts. This is not a secure pair of scripts as the codes
# are visible with the 'ps' command.  However, it is simple.
#
# These are the dialin and login parameters for Erols. 
TELEPHONE=555-1212      # The only telephone number
ACCOUNT=username        # The account name for logon
PASSWORD=password       # The password for this account
LOCAL_IP=1.2.3.4        # Local IP address if known. Dynamic = 0.0.0.0
REMOTE_IP=0.0.0.0       # Remote IP address if desired. Normally 0.0.0.0
NETMASK=255.255.255.0   # The proper netmask if needed
#
# Export them so that they will be available at 'ppp-on-dialer' time.
export TELEPHONE ACCOUNT PASSWORD
# 
# This is the location of the script which dials the phone and logs
# in.  Please use the absolute file name as the $PATH variable is not
# used on the connect option.  (To do so on a 'root' account would be
# a security hole so don't ask.)
#
DIALER_SCRIPT=/etc/ppp/ppp-on-dialer
#
# Initiate the connection
# 
# I put most of the common options on this command. Please, don't
# forget the 'lock' option or some programs such as mgetty will not
# work. The asyncmap and escape will permit the PPP link to work with
# a telnet or rlogin connection. You are welcome to make any changes
# as desired. Don't use the 'defaultroute' option if you currently
# have a default route to an ethernet gateway.
#
exec /usr/sbin/pppd debug lock modem crtscts /dev/ttyS1 38400 \
        asyncmap 20A0000 escape FF kdebug 0 $LOCAL_IP:$REMOTE_IP \
        noipdefault netmask $NETMASK defaultroute connect $DIALER_SCRIPT
===========================================================================

========================= /usr/sbin/ppp=off ===============================
#!/bin/sh
######################################################################
#
# Determine the device to be terminated.
#
if [ "$1" = "" ]; then
   DEVICE=ppp0
else
   DEVICE=$1
fi

######################################################################
#
# If the ppp0 pid file is present then the program is running. Stop it.
if [ -r /var/run/$DEVICE.pid ]; then
   kill -INT `cat /var/run/$DEVICE.pid`
#
# If the kill did not work then there is no process running for this
# pid. It may also mean that the lock file will be left. You may wish
# to delete the lock file at the same time.
   if [ ! "$?" = "0" ]; then
      rm -f /var/run/$DEVICE.pid
      logger "ppp-off: ERROR -> Removed stale pid file"
      exit 1
   fi
#
# Success. Let pppd clean up its own junk.
   logger "ppp-off: PPP link to $DEVICE terminated."
   echo "PPP link to $DEVICE terminated."
   exit 0
fi
#
# The ppp process is not running for ppp0
logger "ppp-off: ERROR -> PPP link is not active on $DEVICE"
exit 1
===========================================================================

========================= /etc/ppp/ppp=on=dialer ==========================
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
exec chat -v                                            \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         60                              \
        OK              ATE1Q0S0=0M1DT$TELEPHONE        \
        CONNECT         ''                              \
        ogin:--ogin:    $ACCOUNT                        \
        assword:        \\q$PASSWORD
===========================================================================

Look through these scripts and let me know if you have any problems.

Enjoy!  :-)

Paul

===========================================================================
Paul B. Brown                          [EMAIL PROTECTED]
President
Brown Technologies Network, Inc.       http://www.btechnet.com/

Unix Systems Administration            "Sailing is a state of mind . . . ."
===========================================================================


------------------------------

From: Ivo Naninck <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.misc
Subject: Re: Time Synch
Date: Sun, 27 Dec 1998 22:20:54 +0100
Reply-To: [EMAIL PROTECTED]

Hi,

Look @ http://www.eecis.udel.edu/~ntp/

Then, in my ip-up script I have

# Synchronizing time with NTP-server
# next line updates the OS-time
/usr/local/bin/ntpdate -u ntp0.nl.net >> /var/adm/messages
/bin/date >> /var/adm/messages
/usr/bin/sleep 1
# next line updates the hardware-clock
/sbin/clock -w
/usr/bin/sleep 1
# End synchronizing          

Works flawlessly!

> David Steuber wrote:
> 
> I am looking for a little utility that I can run from cron to set the
> time on my Linux machine by connecting to port 13 or 37 on a standard
> time server on the east coast of the USA.
> 
> I've also noticed that I am not running either the daytime (port 13)
> or the time (port 37) services.  I would like those to start when the
> machine boots up.  How do I do that?
> 
> I have SuSE 5.3 distribution of Linux.

-- 
Best regards, and don't let the bits byte!
Ivo Naninck.
~
~
:wq!

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list (and comp.os.linux.networking) via:

    Internet: [EMAIL PROTECTED]

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Networking Digest
******************************

Reply via email to