I-Appliance BBS
The Official Source for Internet Appliance Upgrades and Mods
Amazon Honor System Click Here to Pay Learn More
BBS Main List | Sign In | Sign Up | Search | Help | Linux-Hacker.netReply to Thread | Printer |

Home / I-Opener Areas / I-Opener Technical Stuff
ppp
/etc/init.d/ppp.sh

New Messageppp (modified 0 times) boopalooper
Profile | Email
Hi,
Just installed Jailbait & was surprised that
root administration is required to get a ppp connection. Here's a partially working init to avoid that. A better solution would be to have a Blackbox "menu" item that allows a non-root user to click on "Internet Up", "Internet Down" options.

It might be nice to have the installer ask if we want persistent isp as well (echo persist >> /etc/ppp/options), which shouldn't be too hard to add:



# Add this to /etc/rcS.d/S55bootmisc
# Startup Internet connection
echo "Bringing up Internet Connection; Plug in your modem/phone"
/etc/init.d/ppp.sh start &

# initscript: /etc/init.d/ppp.sh
# why: bring up ppp connection upon bootup
# to avoid manual root administration of ppp.
#
# Bug: If user hits enter at login prompt,
# Jailbait tinylogin bails out and LEM login
# only displays login in all caps. Hitting
# enter again returns to Jailbait login.
# Things to do: add sylinks for rc.d start &
# kill levels.
#
#!/bin/bash
test -f /etc/ppp/ppp-up || exit 0
test -e /dev/ttyS0 || exit 0
# processname: ppp
# pidfile: /var/run/ppp.pid
# config: /etc/ppp
# source function library

PPPUP=/etc/ppp/ppp-up
PPPDOWN=/etc/ppp/ppp-down

case "$1" in
start)
echo -n "Starting PPP Internet connection: "
if [ -f "$PPPUP" ]; then
. "$PPPUP" &
else
echo "(PPP not configured)"
exit 0
fi

echo
touch /var/lock/subsys/ppp
;;
stop)
echo -n "Shutting down PPP Internet connection: "
. "$PPPDOWN" &
echo -n "ppp"
rm -f /var/lock/subsys/ppp
echo
;;
restart|reload)
$0 stop
$0 start
;;
*)
echo "Usage: ppp {start|stop|status|restart|reload}"
exit 1
esac
exit 0


05-21-2001 18:12:32

Reply to Thread | Printer |
All times are PSTPowered by UltraBoard v1.62



Copyright © 2000, Netmake Inc. All Rights Reserved.
See Terms and Conditions for more information.




i-opener opener laptop notebook computer help drivers dll free windows dos repair fix linux mac macintosh 2000 95 98 nt pc configure hardware software sound video netscape explorer network networking lan wan software cmos fat bios printer card mouse modem ide scsi cd rom controllers scanner tape hard drive cgi scripts source code mp3