hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Hosting Security and Technology : New approach to bandwidth monitoring?
Reply

Hosting Security and Technology Configuring and optimizing web hosting servers and operating systems, developing administration scripts, building servers, protecting against hackers, and general security (SSL certificates, etc.)
Forum Jump

New approach to bandwidth monitoring?

Reply Post New Thread In Hosting Security and Technology Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 04-01-2002, 09:50 AM
Jake29 Jake29 is offline
Junior Guru Wannabe
 
Join Date: Mar 2002
Posts: 88
*

New approach to bandwidth monitoring?


Okay- this is admittedly a half-baked proto-idea, and i'm not sure if it is even feasible, but I would like to hear other people's thoughts:

What I have learned about bandwidth monitoring is that the only elegant and comprehensive solution is to do bandwidth monitoring via ip addresses using a tool like bandmin, ntop, etc. So in a "reseller environment", each reseller gets and real, global IP address, so that the server owner can bill them for all the traffic of their site and all thier virtual hosts. The reseller, however, is unable to have the same ability to bill thier customers accurately, and at best can tally a set of log files for a more-or-less close approximation.

What I am wondering is whether there would be a way to set up a "virtual lan", so that each virtual host would have an lan ip, ie 10.0.0.1, 10.0.0.2, etc. You can do something like this for apache using mod_proxy and mod_rewrite, but of course, that would only be http traffic, and that's covered by log files. Is there some weird DNS chaining that could be done, so

Global DNS: example.com ==> public ip 204.x.x.x
Local DNS @ 204.x.x.x: example.com ==> local ip 10.x.x.x?

Now the bandwidth monitor can record all traffic for each 10.x.x.x, and each virtual host's traffic can be billed and reported accurately!

If anyone has any idea of what I am talking about, and has any suggestions on how it might be implemented, I would greatly appreciate your thoughts.

half-baked, proto-Jake29

Reply With Quote


Sponsored Links
  #2  
Old 04-01-2002, 03:16 PM
jstout jstout is offline
Junior Guru Wannabe
 
Join Date: Jan 2002
Location: SoCal
Posts: 71
I think it could be done but you would run into problems with NAT when you started pushing decent amounts of bandwidth.

Reply With Quote
  #3  
Old 04-01-2002, 03:52 PM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
Don't do that! It looks nice at first but when you have loads of servers their. Your router won't handle it!

What I suggest is to monitor incomming and outcomming traffic for every user. And then count the total of all user (for a vhost) together for the correct bandwaidth :-)

Or just use webalizer and process the amount of datatraffic by running a simple PHP script :-) And just add for example 10% (for email / ftp traffic).

suc6.

Reply With Quote
Sponsored Links
  #4  
Old 04-01-2002, 11:02 PM
priyadi priyadi is offline
Registered User
 
Join Date: Apr 2001
Location: Depok, Indonesia
Posts: 986
Quote:
[i]
Or just use webalizer and process the amount of datatraffic by running a simple PHP script :-) And just add for example 10% (for email / ftp traffic).
[/B]
Won't work. I've seen users who use email very extensively, and hardly use any web traffic at all.

Reply With Quote
  #5  
Old 04-01-2002, 11:17 PM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
Then how would you suggest keeping track of email activity for bandwisth monitoring? Because I really don't know a way to handle that.

Reply With Quote
  #6  
Old 04-01-2002, 11:43 PM
webx webx is offline
Web Hosting Master
 
Join Date: Mar 2002
Location: Canada
Posts: 781
Any qmail logs?

The sendmail logs do describe the size of email. So processing them you can find the traffic for each domain.

Reply With Quote
  #7  
Old 04-02-2002, 04:20 AM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
I use EXIM, and haven't find anything (yet) to process them to calculate bandwidth. I'll investigate that tonight. But woudn't it be easier to just calculate www+ftp and than add a percentage? Because mail isn't used that often. And further more I don't let my customers send mail by mij server (not from a mail client).

Reply With Quote
  #8  
Old 04-02-2002, 09:40 AM
priyadi priyadi is offline
Registered User
 
Join Date: Apr 2001
Location: Depok, Indonesia
Posts: 986
A few thing to note for those who want to calculate bandwidth on HTTP traffic.

- web server access_log doesn't log HTTP request, most HTTP request are small and therefore negligible, however things like file uploads can be very significant

- it doesn't take HTTP headers into calculation, for both requests and response.

- nph CGI scripts don't generate correct bytes count in access_log

The world is not perfect

Reply With Quote
  #9  
Old 04-02-2002, 09:50 AM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
May I ask you how you would calculate bandwidth?

(while using the namebased host option in apache)

Reply With Quote
  #10  
Old 04-02-2002, 10:21 AM
kindred kindred is offline
Newbie
 
Join Date: Apr 2002
Posts: 5
Depending on how "virtual" your customers are, its pretty simple to setup a perl module to watch packets in and out of the system.

That would then be fine for web/ftp where the customer has their own IP, and for mail you'd have to make sure they make the MX records point to their IP again and not your main server.

Same goes for any service, as long as you can get them to use their own IP (which could also be enforced with user id's in an ACL, which for example ipfw can do).

I played around with PCAP the other day, and managed to make pretty little graphs of every IP aliases on my interface (in bits/sec, ala MRTG/Cricket) using RRDTool.

Lots of options I think, just many ways to do it - some more accurate than others.

Andy.

Reply With Quote
  #11  
Old 04-02-2002, 10:26 AM
Jake29 Jake29 is offline
Junior Guru Wannabe
 
Join Date: Mar 2002
Posts: 88
Vexing, isn't it

Vexing, Isn't it?!?!? When you start to dig a little, basing bandwidth on log files is extremely deficient. There have been a lot of complaints w/ cpanel's inaccuracies, and one reason that I've been avoiding going that route is that there have been so many complaints. What i've been learning is that these aren't really so much deficiencies in cpanel, as much as they are industry-wide systemic flaws in the way virtual hosting is done.

Jake

Reply With Quote
  #12  
Old 04-02-2002, 10:38 AM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
kindred,

You are talking of per IP. That would mean that EVERY customer on my server would need their own IP. And with the current situation, RIPE isn't providing that much IP's for this kind of stuff.

So how you say it I wouldn't call it virtualhosting. But Ip-based hosting.

Reply With Quote
  #13  
Old 04-02-2002, 11:00 AM
kindred kindred is offline
Newbie
 
Join Date: Apr 2002
Posts: 5
Quote:
Originally posted by Starhost
kindred,

You are talking of per IP. That would mean that EVERY customer on my server would need their own IP. And with the current situation, RIPE isn't providing that much IP's for this kind of stuff.

So how you say it I wouldn't call it virtualhosting. But Ip-based hosting.
If you can show a need for the IP, then you should be able to get them.

Other than that, sounds like log parsing is the only other method.

Sorry for the mixup with words, from the original post I assumed there was the ability to account per IP.

Reply With Quote
  #14  
Old 04-02-2002, 02:13 PM
webx webx is offline
Web Hosting Master
 
Join Date: Mar 2002
Location: Canada
Posts: 781
Ok, let me dig it further.

One thing is sure that with name-based hosting, it is inefficient and very difficult to make accurate BW usage graphs. So many logs and so many non-logs usage.

But with IP-based hosting, how would you include the usage of sendmail/qmail, FTP, file uploads thru HTTP, mails generated by scripts, and if SSH is provided: any FTP/HTTP downloads on the server itself? (wget, lynx, ftp)

My guess is everything may not be included. So this comes down to well-calculated approximation.

And this would be for resellers from one box. For big companies offering dedicated server, it's pretty easy for them to watch just one IP and bill the customer

Reply With Quote
  #15  
Old 04-02-2002, 03:04 PM
Starhost Starhost is offline
Web Hosting Evangelist
 
Join Date: Nov 2000
Posts: 486
On freeBSD (for example) their are standard scripts in ipfw that calculate Bandwidth per IP. And when everybody site is running on their own IP. Then ALL bandwith generated by that host will be calculated.

So all email has to be delivered tot the same IP as the websiite is using. That isn't that hard to calculate. The only thing were is need for is calculate Bandwidth using Namebased hosting.

Reply With Quote
Reply

Related posts from TheWhir.com
Title Type Date Posted
Web Host MTL Servers Launches Shared Cloud Hosting, Cloud Servers Web Hosting News 2012-07-12 14:39:19
Hosting.com Rounds Out Monitoring Suite with Application Performance Monitoring Web Hosting News 2012-02-08 16:04:10
Web Host Rackspace Begins Beta for Cloud Monitoring Service Web Hosting News 2011-12-16 15:43:48
Colocation Firm CoreXchange Offers Online Ordering via Enhanced Website Web Hosting News 2011-11-03 21:16:17
Web Host Carpathia Provides Colocation, Hosting for Spotify US Web Hosting News 2011-09-07 20:22:53


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?