# Get traffic usage from VMs and NameVirtualHosts



## pauljames (Oct 2, 2011)

Hi,

We're looking to expand hosting. The issue is trying to find a way to get traffic data (mb/sec, total traffic) from users/domains. The sites hosted now don't use much bandwidth Most sites are configured to use same IP address for their web site(s). Mrtg might be part of an overall solution but then one needs the graphs sent to some sort of output, perhaps like a pdf doc and sent to the client on a regular basis. 

There is commercially available software like Plesk or perhaps cPanel but both of those are really CentOS installs. I have tried a demo configured into one of our VPS's but Virtuozzo caused our whole FreeBSD server to become unresponsive (and it was up for 486 days and we had no choice but to reboot!) Unfortunately plesk will not monitor Virtualbox containers.  Speaking of VPSs, one also has the issue of monitoring multiple IP addresses for each VM. 

We don't yet have a router like a Cisco<tm> but we have once before cacti from the FreeBSD ports. I couldn't see a way to get cacti to show data for domain names (i.e. http://www.dom0.com, http://www.dom1.net etc). 

Having said that, we need to put something in place that will monitor network traffic per user and per VM and per IP for dedicated servers and perhaps allow some configuration to have some decent defaults in place. Somehow I don't think this would be a simple one or two port installs and might even be a lot of custom coding but the cost just might be worth it.  

Thanks for reading this and for your response.


----------



## ecazamir (Oct 6, 2011)

If each domain (or VPS machine) has its own IP address, you could use firewall counters and cacti, local or remote. To check firewall counters remote, a script and SNMP should do the job.


----------



## Abriel (Oct 8, 2011)

Check

net-mgmt/pmacct

I have it with mySQL, but only to manage Internet connection per ip and user.


----------

