🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
1 messages
1 total messages Started by charliek Sat, 21 Mar 1998 00:00
Automating slrnpull
#39686
Author: charliek
Date: Sat, 21 Mar 1998 00:00
81 lines
3323 bytes
Background: I'm running slrn0.9.3.2 & slrnpull on an AMD586 with
32MBram, RH4.2, kernel 2.0.30 & 3hd's.

To avoid hogging our only phone line and to keep peace in the family
:-), I have been using a variation of slrnpull.sh to download groups.
I know my variation should include something other than the'sleep 60'
command to allow ppp-on to connect to my isp. I can't use a cron file
because I dl at random times, and shut down the system when it's not
being used. Both my version of slrnpull.sh and ppp-on are given
below. TIA for any suggestions. Incidently, the connect time to the
isp varies considerably.

#!/bin/sh

# I run this file from cron every night to pull a few newsgroups from my
# news server.  It does the following:
#
#     1.  Runs slrnpull in expire mode to expire old articles
#     2.  Starts up ppp via a ppp-on script (not provided)
#     3.  Runs slrnpull to grab articles from the server
#     4.  Turns off ppp via a ppp-off script (not provided)

#	Modified by cck 2/22/98
#	renamed getnews and put in /usr/sbin

# Configuration variables.  Change these!!!
dir=/var/spool/slrnpull
server=news.nccoast.net
slrnpull=/usr/local/bin/slrnpull

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

# Before getting new articles, perform expiration.
$slrnpull -d $dir --expire
wait

if /usr/local/bin/ppp-on; then
	sleep 60							# needed for isp connect before
										# slrnpull starts 
#	trap $slrnpull "$@"
 $slrnpull -d $dir -h $server
 /usr/local/bin/ppp-off
else
 exit 1
fi
#--------------------------------

#!/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 parameters. Change as needed.
TELEPHONE=287-7040	# The telephone number for the connection
ACCOUNT=charliek		# The account name for logon (as in 'George Burns')
PASSWORD=mypassword	# The password for this account (and 'Gracie Allen')
LOCAL_IP=0.0.0.0	# 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
# 
DIALER_SCRIPT=/etc/ppp/ppp-on-dialer
#
# Initiate the connection
# 
exec /usr/sbin/pppd debug lock modem crtscts /dev/ttyS0 38400 \
	asyncmap 20A0000 escape FF mru 296 kdebug 0 $LOCAL_IP:$REMOTE_IP \
	noipdefault netmask $NETMASK defaultroute connect $DIALER_SCRIPT

-- 
---------
|       |
|   C   |  "Csquared K" alias cck 
|       |   charliek@nccoast.net	
---------

Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads