rnigam
Contributor
Contributor

Chargeback doesn't report network numbers

Hello Everyone,

The chargeback reports that I generate doesn't give any network numbers even though I have defined Network Recieved and Transmitted and also External Network Transfer and External Network Recieve base rates in the Cost Model that I am using.

The CB detects the firewalls running on the internal and external routed networks and reports firewall numbers but not network traffic numbers for those networks.

Please let me know if any one else have encountered such a problem before.

FYI, I am running the report at a vdc level.

Thanks,

Rohan

Message was edited by: rnigam

Reply
0 Kudos
amrainders
Enthusiast
Enthusiast

Hi Rohan,

To see data for "External Network Transfer" and "External Network Receive" counters (the data for these counters is fetched from vShield Manager using vShield Manager data collector running in vCenter Chargeback), please make sure that password for vShield Manager data collector is set. In vCenter Chargeback UI, you can go to Settings-->Cloud Data Collectors-->vShield Manager tab to set the password.

To see data for "Network Recieved" and "Network Transmitted" counters (the data for these counters is fetched from VC), please make sure that statistics level is set to 3 (by default it is 1) in VC for all the four Interval durations. In VC you can go to "Administration-->Statistics-->Statistics Interval" to change the statistics level.

I hope this helps.

-Amrainder

Reply
0 Kudos
rnigam
Contributor
Contributor

Hi Amrainder,

Thank you so much for responding. The password for the vShield data collector was set inside CB UI all the while. As suggested by you, we also tried setting all the statistics level to 3 for all durations inside the vCenter server instance.

Unfortunately we still do not see the network numbers in the reports that we are generating using Chargeback.  Can you think of anything else that might be responsible for this?

- Rohan

Reply
0 Kudos
amrainders
Enthusiast
Enthusiast

Few more things to check

  1. Billing policy for the network counters should be usage based.
  2. The billing policy and base rates should be applied for the period for which you are trying to generate the reports (example:- It is incorrect to apply base rates and billing policies from now and try to generate report for yesterday)
  3. Some data transfer should happened in the VMs for the report generation period.

Thanks,

Amrainder

Reply
0 Kudos
rnigam
Contributor
Contributor

Amrainder,

Thanks so much for your help. I believe choice of billing policy was coming in the way of getting numbers out of Network Received and Network Transmitted counters. When we use actual usage policy I can now see the internal network traffic numbers. However, we are still not getting the external bandwidth numbers which is very important for us.

I tried creating our own custom billing policy (chargeback 1.5 lets you do that) and chose to use Actual usage option for the External Network transfer and External Network Receive counters and still couldn’t get those numbers.

Also, I am pretty sure that there is data transfer happening in and out of the VM’s (vApps in general) and I am also confident that I did everything correct with respect to applying billing policy and base rates for the right period.

Please let me know if you come across something on this.

Thanks,

Rohan

Reply
0 Kudos
jgiardina1
Contributor
Contributor

Amrainder, we are seeing tons of these in the Chargeback logs:


2011-03-07 16:25:19,645  WARN [org.springframework.scheduling.timer.TimerFactoryBean#0] util.JDBCExceptionReporter: SQL Error: 1205, SQLState: 40001

2011-03-07 16:25:19,645 ERROR [org.springframework.scheduling.timer.TimerFactoryBean#0] util.JDBCExceptionReporter: Transaction (Process ID 63) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.

2011-03-07 16:38:07,543 ERROR [CbmPerformaceStatsJob] vsm.CbmPerformaceStatsJob: VSM returned null/empty stats for network ::  NETWORK_ID:dvportgroup-204 VC_ID:1473577530 TIME_STAMP:2010-12-12 12:26:39.83 CB_HIERARCHICAL_ENTITY_ID:838

2011-03-07 16:38:07,933 ERROR [CbmPerformaceStatsJob] vsm.CbmPerformaceStatsJob: VSM returned null/empty stats for network ::  NETWORK_ID:dvportgroup-323 VC_ID:1473577530 TIME_STAMP:2011-01-12 08:45:20.543 CB_HIERARCHICAL_ENTITY_ID:1126

...and so on.

It seems like "VSM returned null/empty stats for network" is appearing every time the poller queries the VSM.

Reply
0 Kudos
jgiardina1
Contributor
Contributor

Also, note that these entries are in the VSM Data Collector-Embedded log file.

Reply
0 Kudos
amrainders
Enthusiast
Enthusiast

Hi Rohan,

Good to know that you are able to see data for Network Received and Network Transmitted counters.

For External Network transfer and External Network Receive counters. Few more points.

This is from chargeback 1.5 user guide.

The vShield Manager Data Collector fetches the external traffic information from vShield Manager for the

following types of VMware Cloud Director networks:
  • Private routed org networks
  • Routed vApp networks
  • Fenced vApp networks
In the case that a routed or fenced vApp network is connected to a private routed org network, then the external
traffic information of the corresponding virtual machine is recorded at both, the vApp network level as well
as the org network level

Moreover are you seeing any IP address under the network (see attached image)? If you are not seeing IP address then the network statistics will not come.

If nothing works can you please attach vsm-dc log files (the latest one).

-Amrainder

Reply
0 Kudos
amrainders
Enthusiast
Enthusiast

Hi,

Looks like the issue here is that the network (dvportgroup-204) is already deleted from VCD (or probably the network was never successfully created) and vcenter chargeback has not received the delete event for this network (or received false create event). But the vsm data collector in chargeback is still trying to get network statistics for this network.

Have you installed the consistency checker tool on VCD database? consistency checker tool makes sure that there are no missing chargeback events from VCD database. You can find more details here, http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=102717...

However, these log messages are harmless and should not cause any problem, other than filling your log files :slightly_smiling_face:

-Amrainder

Reply
0 Kudos
rnigam
Contributor
Contributor

Hi Amrainder,

Thanks for all those suggestions. We will try these out soon and get back to this thread. Also, just FYI and to avoid any confusion, jgiardina and me both work at the same place and we both are talking about the same problem.

- Rohan

Reply
0 Kudos
jgiardina1
Contributor
Contributor

Thanks, we will try this today.

Reply
0 Kudos
damnstraight
Contributor
Contributor

Is there a way to retrieve these 'actual usage' numbers through the API?  I have been able to pull down various allocation based data for chargeback hierarchies, but I'm not clear on how to access the usage data that chargeback uses to generate it's reports...

Reply
0 Kudos
HemanthPannem
VMware Employee
VMware Employee

Hi

Are you looking for the detailed usage of VMs for computing resources such as CPU, memory etc? If so, we have database views (CB_VIEW_VC_PERF_STAT_*), from which you can get stats for a VM managed object identifier (MoId).

Currently, there is no API to expose this.

Regards,

Hemanth

Reply
0 Kudos
amrainders
Enthusiast
Enthusiast

CB_VIEW_VC_PERF_STAT_* view will expose only usage data for VC counters and not for "External network transfer/receive" counters (usage data for these counters come from vShield Manager).

There are no APIs (and database views) to extract the usage data for "External network transfer/receive" counters from vCenter chargeback.

You may want to directly use vShield Manager APIs to get usage data for VCD networks.

-Amrainder

Reply
0 Kudos
damnstraight
Contributor
Contributor

> There are no APIs (and database views) to extract the usage data for  "External network transfer/receive" counters from vCenter chargeback.

> You may want to directly use vShield Manager APIs to get usage data for VCD networks.

Thanks.  That's very helpful knowledge, if not what I was hoping for.  I guess I'll have to figure out some alternative to chargeback for gaterhing usage stats.  I'll take a look into the vShield Manager APIs, since we are primarily interested in the external network transfer/receive.  I'd prefer to go through some APIs instead of digging directly into the DB anyway.

Reply
0 Kudos