[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Re: Are we connected ? - Solution-idea more info (2)
From: Bjoern Kahl <Bjoern.Kahl () kiel ! netsurf ! de>
Date: 1999-05-15 12:08:45
[Download RAW message or body]
Note: This is a resend, first try don't appear at the list after more
than 14 hour.
On 14-May-99 Bjoern Kahl wrote:
>
> Hallo !
>
> I am working some time now on a way to manage Networkconnections to
> the internet, including a way to query the connection-state.
Hallo !
I think, some more info is better.
It work by having a little daemon running.
Each Programm "Client" (in my case: shell-scripts) that need
Networkaccess register itself (using a small C-Programm) to the daemon,
the daemon creates an connection to the Network (using system-provided
script, on SuSE-Linux /etc/suseppp/scripts/ppp-up, this is
configurable) and notify the Client about the link-state.
Of course, a lot of different Programms can register at the same time.
The connection is up, as long as one Client is registered.
(The advantage compared to dial on demand is, the link is only created,
if there is a Client that want to use to link, not if anything else trys
to send a packet (like DNS-querys)).
Clients are separated in two Groups:
- Request, made by a user-programm
The Programm register it self, and unregister when done
- request comming from the system, that is, Programm that are liste in
a configfile.
- marked as "system-job" (like Mail or Newstransfer in the early
morning, or when evver it is cheap to call the net).
- otherjobs, belonging to a single User
Such a Request starts, when the daemon starts a Programm listet in
the configfile, and ends, when the new created process returns.
I use this kind of Client for Mail and Newstransfer in the morning.
There is also a GUI-FrontEnd, written in TCL/TK. A User can see in
this, if the connection is up, and which Programm have registered,
using his UID. He can cancel all or some of his Networkrequest by a
mouse-click, or start some predefined Jobs by a Mouseclick (from the
configfile, I told about in the last paragraph). Also the user can
see how much time he has used the Network (As I started the work, I
planed to do a per-user-accounting of Networkusage, to be able to
split telephon-costs to the users - I droped that plan later, but some
funktion to do some accounting is still there).
maybe, some thing is usefull for you.
Bjoern
--
+-----------------------------------------------------------------------+
| Björn Kahl ++ Max-Planck-Str.26 ++ 24211 Preetz ++ (ISDN) 04342 76882 |
+-----------------------------------------------------------------------+
Weitergabe und/oder gewerbliche Nutzung meiner Adresse/TeleNr untersagt.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic