Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 3 Jan 2002 07:15:42 -0700
From:      "Totally Jayyness" <Jayyness@mindspring.com>
To:        <jre@globalnet.co.uk>
Cc:        <freebsd-questions@freebsd.org>
Subject:   Re: Kicking a single user off httpd
Message-ID:  <000a01c19461$2144a550$0300a8c0@jayyness.com>
References:  <000f01c19394$42196d10$0300a8c0@jayyness.com> <20020102171727.E49613@ns2.wananchi.com> <000401c1939a$de3338b0$0300a8c0@jayyness.com> <3C331E47.609CC5A3@globalnet.co.uk>

next in thread | previous in thread | raw e-mail | index | archive | help
Thanks for the tip, what a great looking program, just finished doing a
/stand/sysinstall of it.  I also
went to the web page to read about it
http://www.snert.com/Software/mod_throttle/
I still have some questions but am going to check the man page first and try
to get it working.

Hmmm, couldn't find a man page for this, probably not looking in the right
place.  I tried man throttle
and man mod_throttle.  Not sure what other iteration to try, back to the web
page.

Ok, it looks like I want to use the Concurrent Policy, only allowing 3
concurrent connections per IP.
Not sure what some of the instructions mean, though.  What the heck is this
stuff listed in the
directions below?

"2.  Depending on your operating system, you must edit the #undef and
#define found at the top of
mod_throttle.c source file to specify the semaphore & shared memory API to
use.
For the semaphore support you must #define only one of the following and
#undef the rest. If you do not
#define one of these, then mod_throttle will operate without semaphore
support, which will have undefined
results:

USE_POSIX_SERIALIZATION
USE_FCNTL_SERIALIZATION
USE_FLOCK_SERIALIZATION
USE_SYSTEM_V_SERIALIZATION


For the shared memory support you must #define only one of the following and
#undef the rest. If you do
not #define one of these, then mod_throttle will operate without shared
memory, which will have undefined
results:

USE_POSIX_SHARED_MEMORY
USE_SYSTEM_V_SHARED_MEMORY"

What the heck is that?  And what the heck is this?

"3.To build as DSO module, just type:

cd (path to)/mod_throttle-3.1
make install


To build as a static module:

cd /usr/local/apache_1.3.14 (or where ever you keep the Apache source)
./configure \   (see below in the Notes for additional information)
    --disable-shared=throttle \
    --add-module=(path to)/mod_throttle-3.1/mod_throttle.c \
    ... (your other configuration options) ...
make install"

Does anyone have a sample mod_throttle config file they can show me?

I made the minimum config entry to my httpd.conf file but the policy is set
to none.
I would like to limit the amount of concurrent connections to one of my
particalar virtual web pages to
3.  The doc shows

Context: server, <VirtualHost>, <Directory>, <Location>

so, do I add

jaybsd.jayyness.com, mp3s.jayyness.com, /mp3, What does location stand
for????
OHHHHH it is server OR virtual host OR directory OR location... ok I hope
that is right.
But where do I put the server?  Like this?

<IfModule mod_throttle.c>
 ThrottlePolicy Concurrent 3 60
 <mp3s.jayyness.com>

 <Location /throttle-status>
 SetHandler throttle-status
 </Location>

 <Location /throttle-me>
 SetHandler throttle-me
 </Location>

 <Location /~*/throttle-me>
 SetHandler throttle-me
 </Location>
</IfModule>

Well, the above isn't right... I think I have everythign I need except for
where to put the virtual
server in the http.conf part.... unless steps 2. and 3. above are really
important.

please reply directly as I am not subscribed to the list
----- Original Message -----
From: "John Ekins" <jre@globalnet.co.uk>
To: "Totally Jayyness" <Jayyness@mindspring.com>
Sent: Wednesday, January 02, 2002 7:50 AM
Subject: Re: Kicking a single user off httpd


> Totally Jayyness wrote:
> >
> > Thanks for the quick reply, Wash.
> >
> > I don't want to completely block that user from my web space forever...
I
> > am just looking for a way to kick his connection off long enough for
> > whatever program he was using (probably just a web browser) to time-out
when
> > it was trying to auto-reconnect (which apparently is does with a vigor).
>
> Why not bandwidth throttle his IP? You could do this either using Apache
> with mod_throttle (available in ports), or ipfw/dummynet.
>
> Cheers,
> John.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?000a01c19461$2144a550$0300a8c0>