This has probably been said before, but... Yow! This a great Linux resource site!:
http://www-jerry.oit.duke.edu
I'm still distractedly exploring. It'll take awhile before i dig into the following.
Thanks.
At 15:44 2001.11.11 -0500, Jerry Winegarden wrote:
>On Mon, 12 Nov 2001, AD Marshall wrote:
>
>> Could someone offer some quick tips to get ppp dial-on-demand (to ISP) working from
>boot-up via the command-line and how to configure it (ppp?) to kill the dial-up link
>after x minutes of TCP/IP inactivity -- not input (kb, mouse) inactivity, if not
>inadvisable... -- maybe?
>>
>
>The key to pppd hanging up after an idle time is the "idle" option in the
>PPPOPTIONS line of /etc/sysconfig/network-scripts/ifcfg-ppp0:
>
>/etc/syconfig/network-scripts/ifcfg-ppp0:
>
>DEVICE="ppp0"
>ONBOOT="yes"
>USERCTL="no"
>MODEMPORT="/dev/ttyS0" (for external, use /dev/ttyS3 for internal set to
>COM4)
>LINESPEED="115200"
>PERSIST="yes"
>DEFABORT="yes"
>DEBUG="no"
>INITSTRING="ATZ"
>DEFROUTE="yes"
>HARDFLOWCTL="yes"
>ESCAPECHARS="no"
>PPPOPTIONS="ipcp-accept-local ipcp-accept-remote demand idle 3000"
>OAPNAME="yourispaccountusername"
>REMIP="10.0.0.2" (this is temporary number!)
>NETMASK=""
>IPADDR="10.0.0.1" (this is a temporary number!)
>MRU=""
>MTU=""
>DISCONNECTTIMEOUT="60"
>RETRYTIMEOUT="5"
>BOOTPROTO="dhcp"
>PEERDNS="yes"
>
> Note: the above assumes that your IP Masq LAN is
> set to 192.168.1.x (something besides 10.0.0.x anyway)
> since the temporary assignment of 10.0.0.1 and 10.0.0.2
> is necessary to get connected and then the real numbers
> dynamically assigned by the ISP's dhcp service to your
> IP Masq box.
>
> Note 2: the idle time is in seconds; it is the time
> that your box will wait before dropping the
> connection if there is no activity on the line.
> Your ISP may have a shorter drop time (e.g. 10
>Minutes)
> In testing your set up, set the idle time to 200
>or 300
> In operations you will want to set it longer
> (e.g. 3000 seconds = 50 minutes)
>
>This info can be found at:
>
>http://www-jerry.oit.duke.edu/linux/HOWTO/AAAfirewall_configure_with_ppp_v62.txt
>
>Although this is for RH v 6.2, the ppp config should be the same.
>
>I created an ip-up.local file which is called by ip-up (which is called
>when you try to dial). ip-up.local calls my firewall script
>(/etc/rc.firewall), so that the correct gateway gets defined each time I
>connect.
>
>The behavior is that ppp0 startup will appear to fail at start up, but it
>will actually background it, and it will go ahead and start up correctly
>upon demand.
>
>
>> I've got RH7.1 with bind-9.1.3, ppp-2.4.0-2, iptables-1.2.1a-1 on a 386 box with
>one modem (ttyS0) to POTS and eth0 to hub to one Win2K and one Win98 workstation. ISP
>is using PAP, assigning dynamic IPs.
>>
>> I have an iptables-forwarding script that i can run before or after establishing a
>ppp link to my ISP to give the workstations automatic internet access, but i can't
>remember how to get it to execute on boot-up.
>>
>> I also can't remember how to have ppp killed if it's idle (presumably in terms of
>TCP/IP traffic) for a specifed interval.
>>
>> Here's the script, "ipfwdmasq.sh" -- mainly ripped from www.yolinux.com:
>>
>> #!/bin/sh
>> # Enable packet forwarding
>> echo 1 > /proc/sys/net/ipv4/ip_forward
>> # Flush all the rules in filter and nat tables
>> /sbin/iptables --flush
>> /sbin/iptables --table nat --flush
>> # Delete all chains that are not in default filter and nat table
>> /sbin/iptables --delete-chain
>> # Set up IP FORWARDing and Masquerading
>> /sbin/iptables --table nat --delete-chain
>> /sbin/iptables --table nat --append POSTROUTING --out-interface ppp0 -j MASQUERADE
>> # Assuming one NIC to local LAN
>> /sbin/iptables --append FORWARD --in-interface eth0 -j ACCEPT
>> #eof
>>
>> Thanks,
>> AD
>>
>> PS: I have read the ppp-howto and various other ppp references, esp.
>http://axion.physics.ubc.ca/ppp-linux.html. But i couldn't quite figure out what
>would be best for RH7.1, bind-9.x and iptables. I also didn't want to introduce diald
>into the works until i can see how it works with ppp first.
>>
>> PPS: Just in case, here's /etc/resolv.conf --
>>
>> search localhost vdc-hn01.vnn.vn hcm-server1-vnn.vn
>> nameserver 127.0.0.1
>> nameserver 203.162.0.11
>> nameserver 203.162.4.1
>>
>>
>>
>> _______________________________________________
>> Redhat-list mailing list
>> [EMAIL PROTECTED]
>> https://listman.redhat.com/mailman/listinfo/redhat-list
>>
>
>--
>***************************************************************************
>Jerry Winegarden OIT/Technical Support Duke University
>[EMAIL PROTECTED] http://www-jerry.oit.duke.edu
>***************************************************************************
>
>
>
>_______________________________________________
>Redhat-list mailing list
>[EMAIL PROTECTED]
>https://listman.redhat.com/mailman/listinfo/redhat-list
*--------------------------------------------------*
AD Marshall, VietInfoComm&Edu [VICE]-8 Consulting
mailto:[EMAIL PROTECTED]
Web: HTTP://ParadoxCafe.Net
_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list