>Hello,
>       I need a kick in the right direction regarding control.
>I have succesfully managed to either keep diald from working at all or have
>it dialing in all the time.
>What i need to have is: durning business hours the link should come up for
>any request and stay up for at least 10 minutes after.
>then during non hours it shouldn't come up at all.
>here is my diald.conf I use the same phone.filter that came with diald
>except i changed the values from 240 to 600 for http and ftp reqs.

I do this a bit differently: I use a restrict filter to assign a "calling
time-unit" for the phone line, and use block and unblock commands from a
crontab to block the line from 9 PM to to 7 AM.

The restrict filter is:
restrict 00:00:00 23:59:59 0-6 * *
impulse 600,15
restrict * * * * *

I call this from /etc/diald.conf BEFORE standard.filter, it didn't seem to
work when called after the filter rules.

Note the behavior of this system: when any packet opens the line, it will
stay up for at least 10 minutes. This means that a sendmail dns lookup will
keep the line up the full 10 minutes, even though the message that
generated it will be long gone by then. Also, if there is traffic on the
connection at the 10 minute mark, the line will stay up for another 10
minutes, even if there's no traffic after 11 minutes.

However, this system is justified for interactive Web use, especially when
bringing up the link is relatively difficult. For example, during
high-traffic times at some ISPs, getting a connection through can take two
or three attempts. Once the connection is up, though, you don't want it to
come back down while reading Web pages, because you'd have to wait for the
connection to be re-established before seeing the next page. This can take
up to three minutes (assuming three dial attempts before a connection)
which seems like a long time for an impatient interactive user. I kept
getting calls from frustrated users that "the Internet wasn't working". So
I now offer two configurations: better interactivity, or lower phone costs.

To avoid traffic during off hours, I block and unblock the connection with
simple shell scripts that echo "block" or "unblock" to the diald control
FIFO. I call these scripts with an appropriate crontab entry.

I find this more convienient, since if the link needs to be used in
off-hours, a user can override the block simply by issuing the unblock
command (which I make available in a simple dialog-based menu).

To avoid having the diald FIFO world-writable, I use the utility "super"
(currently ftp://ftp.ucolick.org/pub/users/will/super-3.12.1.tar.gz) to
define users (or groups) that can execute the block and unblock scripts as
root.

If you'd like a copy of the suite of scripts and configuration files I use
to do this, I'll be glad to send them, just ask.

John Seifarth

__________________________________________________________________
John Seifarth                               http://www.waw.be/waw/
Words & Wires SPRL                                     [EMAIL PROTECTED]
Computer Consulting & Language Services   Voice: (+) 32-2-660-3943
1160 Brussels, Belgium                      Fax: (+) 32-2-675-3922



-
To unsubscribe from this list: send the line "unsubscribe linux-diald" in
the body of a message to [EMAIL PROTECTED]

Reply via email to