Results 1 to 8 of 8
  1. #1
    Join Date
    Mar 2004
    Posts
    295

    Counting how many users connected to http / ftp?

    Hello,

    I'm trying to basically limit the amount of people that can download from a server, however I don't want the script to 'guess' how many people are online based on averages and wondered if anyone could help with how to get a php script to find out how many people are connected to either ftp or http?

    Thanks.
    Ampinet.co.uk - UK Webhosting - Coming Soon!
    99.99% Uptime Guarentee | Shared Hosting | Reseller Hosting | 24/7 Support

  2. #2
    I use http://www.ivn.cl/apache/ for apache 2 on my windows server to limit http connections and bandwidth, on you're server you can go to http://www.domain.com/server-status you may have to enable this in the apache config file, also what are you using for you're ftp? I use serve-u ftp and i can limit connections and speed.

  3. #3
    Join Date
    Mar 2004
    Posts
    295
    Yeah, but I also want to somehow give the user an idea of the amount of people connected.

    So when you are given the option to download a file you get something like:

    Server 1 (USA): Click Here (85% Full)
    Server 2 (UK): Click Here (57% Full)



    Thanks for your help though.
    Ampinet.co.uk - UK Webhosting - Coming Soon!
    99.99% Uptime Guarentee | Shared Hosting | Reseller Hosting | 24/7 Support

  4. #4
    Hmm im sure there is a script out there for that... ill look and see what i can try to find...

    Edited: Try this, maybe you can find something in php, asp or other scripting..?...
    http://www.hotscripts.com/PHP/Script...ems/index.html
    Last edited by Criminal#58369; 06-11-2005 at 02:26 PM.

  5. #5
    Join Date
    Mar 2004
    Posts
    295
    Nope, couldn't find anything there.
    Ampinet.co.uk - UK Webhosting - Coming Soon!
    99.99% Uptime Guarentee | Shared Hosting | Reseller Hosting | 24/7 Support

  6. #6
    Join Date
    Jan 2005
    Location
    Scotland, UK
    Posts
    2,549
    You could do it with 2 ips.

    1 ip actualy displays the webpage, and 1 for the downloading.

    Then just guess by,
    netstat -an | grep downloadip | wc -l

    Or by the download port then you only need 1 ip, and so on.

    -Scott
    Server Management - AdminGeekZ.com
    Infrastructure Management, Web Application Performance, mySQL DBA. System Automation.
    WordPress/Magento Performance, Apache to Nginx Conversion, Varnish Implimentation, DDoS Protection, Custom Nginx Modules
    Check our wordpress varnish plugin. Contact us for quote: [email protected]

  7. #7
    Join Date
    Mar 2004
    Posts
    295
    Originally posted by HostGeekZ
    You could do it with 2 ips.

    1 ip actualy displays the webpage, and 1 for the downloading.

    Then just guess by,
    netstat -an | grep downloadip | wc -l

    Or by the download port then you only need 1 ip, and so on.

    -Scott
    Could a php script execute that command? If so that's PERFECT.
    Ampinet.co.uk - UK Webhosting - Coming Soon!
    99.99% Uptime Guarentee | Shared Hosting | Reseller Hosting | 24/7 Support

  8. #8
    Join Date
    Jan 2005
    Location
    Scotland, UK
    Posts
    2,549
    Ofcourse,

    exec('netstat -an');

    it just depends how the server is setup.
    Server Management - AdminGeekZ.com
    Infrastructure Management, Web Application Performance, mySQL DBA. System Automation.
    WordPress/Magento Performance, Apache to Nginx Conversion, Varnish Implimentation, DDoS Protection, Custom Nginx Modules
    Check our wordpress varnish plugin. Contact us for quote: [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •