From watnews1.watson.ibm.com!watnews.watson.ibm.com!locutus.rchland.ibm.com!ibmboulder!juniper.almaden.ibm.com!garlic.com!nic.scruz.net!hilbert.dnai.com!emf.emf.net!overload.lbl.gov!agate!newsxfer.itd.umich.edu!gatech!swrinde!news.uh.edu!uuneo.neosoft.c Tue Mar  7 14:53:15 1995
Article: 27979 of comp.os.linux.admin
Path: watnews1.watson.ibm.com!watnews.watson.ibm.com!locutus.rchland.ibm.com!ibmboulder!juniper.almaden.ibm.com!garlic.com!nic.scruz.net!hilbert.dnai.com!emf.emf.net!overload.lbl.gov!agate!newsxfer.itd.umich.edu!gatech!swrinde!news.uh.edu!uuneo.neosoft.com!praline.no.NeoSoft.com!smann
From: smann@praline.no.NeoSoft.com (Scott Mann)
Newsgroups: comp.os.linux.admin,comp.os.linux.networking
Subject: Re: RE-dialing SLIP/PPP (not dial on demand)
Followup-To: comp.os.linux.admin,comp.os.linux.networking
Date: 5 Mar 1995 21:57:33 GMT
Organization: NeoSoft Internet Services   +1 713 968 5800
Lines: 41
Message-ID: <3jdc4d$43k@uuneo.neosoft.com>
References: <3imcl7$hbt@zeus.fasttax.com> <3j4us7$8rt@uuneo.neosoft.com> <MEISSNER.95Mar3151413@tiktok.cygnus.com> <Pine.SUN.3.91.950305115523.1176B-100000@aindev.gtd.eds.com>
NNTP-Posting-Host: praline.no.neosoft.com
X-Newsreader: TIN [version 1.2 PL2]
Xref: watnews1.watson.ibm.com comp.os.linux.admin:27979 comp.os.linux.networking:3545

Scott J. Ellentuch (tuc@aindev.gtd.eds.com) wrote:
: On 3 Mar 1995, Michael Meissner wrote:

: > In article <3j4us7$8rt@uuneo.neosoft.com> smann@praline.no.NeoSoft.com (Scott Mann) writes:
: > 
: > | Phil Howard (phil@zeus.fasttax.com) wrote:
: > | 
: > | : Ideas?  Particular programs to suggest?
: >
: 	(Sunsite ls removed)
: >
: 	This also may not be very elegant, but I use this on an AIX box and 
: expect it will work on dip.  Pseudocode follows:

: 	PING Well.Known.Host.Thats.ALWAYS.up 5 times > SLIPCHECK
: 	IF WC -L of SLIPCHECK isn't a certain number of lines
: 		RESET SLIP by shutting it down
: 		BRING SLIP back up
: 	ELSE
: 		echo "This_program" | at now + 5 minutes

: 				Scott
Here is a short program that I am using to keep my slip up:

/* checklink.c                -- William Gladnick               */
/* This program assumes you have one modem line dedicated       */
/* to SLIP. If the modem is not locked, dip needs to be run.    */
/* The time between checks is 10 seconds but this can be        */
/* changed easily. Change /root/server.dip to your script name. */ 
#include <stdio.h>
main(){
int     n=0;
FILE    *inf;
do{
if((inf = fopen("/var/spool/uucp/LCK..modem","r")) == NULL)
                system("/sbin/dip /root/server.dip");
else
                fclose(inf);
sleep(10);
}while(n==0);
}


