CLOUD ASSERT USAGE AND BILLING Setup Guide... 2 CLOUD ASSERT USAGE AND BILLING SETUP GUIDE o Ensure...

20
WWW.CLOUDASSERT.COM 1 CLOUD ASSERT USAGE AND BILLING SETUP GUIDE Usage and Billing for Windows Azure Pack setup and configuration guide Version: 1.0.0.3 Published: 4/27/2015 INTRODUCTION Usage and Billing for Windows Azure Pack has four components. All of these can be installed from the same single installer by selecting or un-selecting the features to install: I. API Service – IIS Web Application II. Aggregation Service – Windows Service III. Admin Extension – Windows Azure Pack Admin Portal Extensions IV. Tenant Extension – Windows Azure Pack Tenant Portal Extensions These components can be installed on the same machine or multiple machines. GENERAL PRE-REQUISITES: Following are some of the installation pre-requisites and checklist. Cloud Assert Usage and Billing Database: a. Create a SQL Database and note down the name. For example: CloudAssertBilling b. Ensure that the Database server has at least 8 GB RAM and 4 Virtual CPUs. As usage and billing involves lots of data aggregations it is important to have a performant database server. c. Create a database user with read-write, owner and admin privileges just to this database Pre-Requisites: Components of Usage and Billing API Service can co-exist with other WAP Portal components, for example you can install Usage and Billing API Service on the same machine as WAP Admin-Site Portal. Optionally you can choose to install components on separate boxes, especially when you have WAP components installed in distributed fashion. For Usage and Billing API Service (IIS Web Application) on a separate box o Choose a machine with at least 4 GB RAM, preferably 8 GB

Transcript of CLOUD ASSERT USAGE AND BILLING Setup Guide... 2 CLOUD ASSERT USAGE AND BILLING SETUP GUIDE o Ensure...

WWW.CLOUDASSERT.COM 1

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Usage and Billing for

Windows Azure Pack

setup and

configuration guide Version: 1.0.0.3 Published: 4/27/2015

INTRODUCTION Usage and Billing for Windows Azure Pack has four components. All of these can be installed from the

same single installer by selecting or un-selecting the features to install:

I. API Service – IIS Web Application

II. Aggregation Service – Windows Service

III. Admin Extension – Windows Azure Pack Admin Portal Extensions

IV. Tenant Extension – Windows Azure Pack Tenant Portal Extensions

These components can be installed on the same machine or multiple machines.

GENERAL PRE-REQUISITES: Following are some of the installation pre-requisites and checklist.

Cloud Assert Usage and Billing Database: a. Create a SQL Database and note down the name. For example: CloudAssertBilling

b. Ensure that the Database server has at least 8 GB RAM and 4 Virtual CPUs. As usage and

billing involves lots of data aggregations it is important to have a performant database

server.

c. Create a database user with read-write, owner and admin privileges just to this database

Pre-Requisites: Components of Usage and Billing API Service can co-exist with other WAP Portal components, for

example you can install Usage and Billing API Service on the same machine as WAP Admin-Site

Portal.

Optionally you can choose to install components on separate boxes, especially when you have WAP

components installed in distributed fashion.

For Usage and Billing API Service (IIS Web Application) on a separate box

o Choose a machine with at least 4 GB RAM, preferably 8 GB

WWW.CLOUDASSERT.COM 2

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

o Ensure that firewall is configured to allow access to inbound port 30045

o Ensure that this machine can talk to the SQL database server on which the Usage and Billing

database will be configured (refer general pre-requisites above)

o Ensure that IIS, Asp.Net MVC features and other features similar to the requirements for

Windows Azure Pack portal installations are met.

For Usage and Billing Agent Windows Service on a separate box

o Choose a machine with at least 4 GB RAM, preferably 8 GB

o Ensure that firewall is configured to allow access to port outbound port 30045

o Ensure that this machine can talk to all WAP endpoints (usually ports 30071 to 30100).

Specifically Admin API endpoint (usually port 30004), Admin Auth endpoint (30072), Usage

API endpoint (usually port 30022).

o Ensure that this machine can talk to the SQL database server on which the Usage and Billing

database will be configured (refer general pre-requisites above)

o Ensure that this machine can talk to WHMCS (if WHMCS integration is planned)

INSTALLATION:

Single machine Setup: If you have Windows Azure Pack single machine setup, where all the components like Admin Portal, Tenant

Portal etc., are on the same box, you can use the same CloudAssertBilling installer to install of it is

components on the same box as well.

Download the installer ‘CloudAssert.WAP.Billing.Setup.msi’ from: Download trial

Click on the installer and click next to accept EULA

Ensure that all the features are selected in the Feature selection screen of the setup dialog and click

next to finish the installation.

WWW.CLOUDASSERT.COM 3

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Note: If you are upgrading from a previously supported Usage and Billing installation, we recommend to take

a backup of the Usage and Billing database and obtain the resource provider username and password

settings from Usage and Billing API Service web.config before proceeding.

For upgrade installations: Uninstall existing Usage and Billing installers from Add or Remove Programs on the

respective machines and install the latest update by following steps mentioned in the installation steps

below.

Distributed Multi-Machine Setup: Sample setup used in this document:

Figure 1 – Sample Distributed Deployment

INSTALL USAGE AND BILLING API SERVICE:

Logon to the machine with required configuration.

In Figure 1 refers to machine - wap01.contoso.com

WWW.CLOUDASSERT.COM 4

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Download the installer ‘CloudAssert.WAP.Billing.Setup.msi’ from: Download trial

Click on the installer and click next to accept EULA

In the features selection screen select ONLY ‘MgmtSvc-CloudAssertBilling API Service’ by un-selecting

all other features with choosing ‘Entire feature will be unavailable’ option:

WWW.CLOUDASSERT.COM 5

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

INSTALL USAGE AND BILLING AGENT SERVICE:

Logon to the machine with required configuration.

In Figure 1 refers to machine - wapbilling01.contoso.com

Click on the downloaded installer and select ONLY ‘CloudAssertBillingAgent Service’ by selecting

‘Entire feature will not be available’ for all other features as mentioned for the previous installation.

INSTALL USAGE AND BILLING ADMIN EXTENSION:

Logon to the machine on which WAP ‘Admin-Site’ is installed.

In Figure 1 refers to machine - wapa01.constoso.com

Click on the downloaded installer and select ONLY ‘Mgmt-AdminSite Extension’ by selecting ‘Entire

feature will not be available’ for all other features as mentioned for the previous installation.

WWW.CLOUDASSERT.COM 6

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Follow the instructions on the installer UI and click ‘Next’ till the installer finishes and then click

‘Finish’ to exit.

INSTALL USAGE AND BILLING TENANT EXTENSION:

Logon to the machine on which WAP ‘Tenant-Site’ is installed.

In Figure 1 refers to machine - wapt01.contoso.com

Click on the downloaded installer and select ONLY ‘MgmtSvc-TenantSite Extension feature’.

WWW.CLOUDASSERT.COM 7

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Follow the instructions on the installer UI and click ‘Next’ till the installer finishes and then click

‘Finish’ to exit.

SETUP CONFIGURATION:

Step 1: Update Usage and Billing API Service Password

1. Navigate to Usage and Billing Install folder. For example: ‘C:\inetpub\MgmtSvc-CloudAssertBilling’

2. Open web.config and replace the default password in the appSettings:

WWW.CLOUDASSERT.COM 8

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

<add key="Password" value=" [[ReplaceWithYourPassword]]" />

3. Save and close web.config file.

Step 2 - Register Usage and Billing Resource Provider with Windows Azure Pack:

Note: If you are upgrading from a previously supported installation, the resource provider registration could be skipped as it might already be registered. If you changed the username or password on the previous step, then do not skip this step and must proceed with updates as mentioned below.

1. Logon to WAP Admin portal, click on Usage and Billing on the Left

2. Select Settings Tab

3. Enter the URL for Usage and Billing API Service.

a. For example: http://CloudAssertBillingAPIServiceMachine:30045/

b. As per Figure 1, URL will look like http://wap01.contoso.com:30045/

4. Enter the password you have configured in web.config.

5. Optionally change the Username, but remember this has to match the user name provided in

appSettings of Usage and Billing web.config.

6. Click ‘Register’

7. If the registration succeeds you can more to next steps. If there are errors, check the username and

password again with web.config of Usage and Billing API service and try again.

WWW.CLOUDASSERT.COM 9

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Step 3 – Configure database for Usage and Billing

After registering the resource provider successfully, you need to configure the database for Usage and Billing.

1. Enter the database information

2. Click Save.

3. Once the configuration succeeds you will see success messages. If you see any errors double check

the database settings and try again.

Note for Upgrades from Licensed V1 RTM: If you are upgrading from a previous installation and if you continue to see DB config update errors: Please recycle the Usage and Billing API Service application pool or do IISReset. If that didn’t help, check the Usage and Billing logs in Event Viewer for more details and email [email protected]. Note for Upgrades from Beta Releases or previous Trial Installations: If you continue to see DB configuration errors, this usually means your version of DB is not supported for the current upgrade due to major DB changes. Please create a new DB in SQL Management studio and provide the new DB name in the Settings to configure Usage and Billing fresh and experience all the new awesome features.

WWW.CLOUDASSERT.COM 10

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Step 4: Configure Agent Settings - Usage EndPoint

What is Usage Service Endpoint?

What is Usage Endpoint?

How to configure username and password for Usage Endpoint?

In a machine where 'WAP Usage Service' is installed, navigate to inetmgr-->sites-->MgmtSvc-Usage. Click on browse to find the Url.

Steps to configure:

1. Enter Usage Endpoint details

WWW.CLOUDASSERT.COM 11

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

2. Click Save.

Steps to verify Usage end-point settings:

1. Open a browser and hit the URL provided in EndPoint Url under Usage Endpoint Settings a. The URL in the image is just a sample.

2. If the endpoint is valid, it will ask for credentials using a dialog box 3. Enter the credentials you provided in the settings 4. If the credentials work, then a valid Usage.json will be downloaded.

How to reset Usage Endpoint credentials?

Go to Start -> Windows Azure Pack Configuration PowerShell (run as administrator in WAP

machine)

To find the Username set, execute the following command:

Get-MgmtSvcSetting -Namespace UsageService -Name Username

To reset the User Name and Password:

Set-MgmtSvcSetting -Namespace UsageService -Name Username -

Value '<REST API Username>'

Set-MgmtSvcSetting -Namespace UsageService -Name Password -

Value '<REST API Password>' –Encode

WWW.CLOUDASSERT.COM 12

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Step 5: Configure Optional Agent Settings Configure the following optional settings if required

Email Notification

WHMCS (Required only when WHMCS is present and needs to be integrated)

WAP Admin API (Required only for auto creation of subscriptions from payment systems like

WHMCS)

WAP Menbership (Required only for auto creation of users from payment systems like WHMCS)

To update email notification settings (optional):

1. Enter the following settings:

2. Click Save.

WWW.CLOUDASSERT.COM 13

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

To update WHMCS settings (optional):

1. Enter the following settings:

2. Click Save.

WWW.CLOUDASSERT.COM 14

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

To update WAP Admin API (optional):

1. Enter the following settings:

2. Click Save.

To Update WAP Membership Database Setting (optional):

1. Enter the WAP Membership Database Connection String:

For example: "Data Source=db01.contoso.com;User Id=sa; Password=YOUR_PASSWORD;

Initial Catalog=Microsoft.MgmtSvc.PortalConfigStore;" without the quotes.

2. Click Save.

WWW.CLOUDASSERT.COM 15

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Step 6: Configure Notifications You can enable or disable notifications from the admin settings for the tenant users. This setting applies to all

tenant users.

Step 7: Configure Database Connection String in Cloud Assert billing agent Windows service

1. You need to configure the agent service exe configuration file

‘CloudAssert.WAP.Billing.AgentService.exe.config’.

2. Navigate to the Agent service install folder to open the configuration file. For example: ‘C:\Program

Files\CloudAssertBilling\CloudAssert.WAP.Billing.AgentService\CloudAssert.WAP.Billing.AgentService

.exe.config’

3. Update the following database setting to match your environment

WWW.CLOUDASSERT.COM 16

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

MANAGING PRICING PROFILES At the core of the usage and billing is Pricing Profiles, which enables administrators to enable collection of

usage resources and attach monetary value for each resource.

NOTE: CLOUD ASSERT provides Deployment Service as part of enterprise license purchase and will take care of working with your team to understand your requirements and configure the pricing profiles to suit your needs. Following is provided for information purposes and if you want to kick the tires yourself during trial installations.

Usage and Billing solution ships with a ‘default’ pricing profile that contains all the known usage resources at

the time of release. It is recommended to clone that default profile and use the cloned profile for your needs.

Pricing profile can be accessed from the admin portal Usage and Billing Pricing Profile.

To create a New PricingProfile, Click ‘Add’ and provide the information like below:

WWW.CLOUDASSERT.COM 17

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Configuring a Resource:

Click on a Pricing Profile to drill down to see the list of resources.

WWW.CLOUDASSERT.COM 18

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Select a resource and click ‘Edit’ on a Resource to enable for collection and configure the display names and

monthly unit prices:

You can use the sample calculator to calculate the cost.

Click to go to next step to configure the Monthly Credits (Units) and click submit:

WWW.CLOUDASSERT.COM 19

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

Map Windows Azure Pack plans to Pricing Profile:

1. Add ‘CloudAssertBilling’ service to Windows Azure Pack plans. This step will enable ‘Usage and

Billing’ Tenant features to show up for the tenant users under that plan

2. Navigate to Admin Portal ‘Plans’ Select a Plan click on ‘Add Service’ and select

‘CloudAssertBilling’

3. Important step after adding the service is to map EACH plan in Windows Azure Pack to a Pricing

Profile.

WWW.CLOUDASSERT.COM 20

CLOUD ASSERT USAGE AND BILLING SETUP GUIDE

TROUBLESHOOTING:

Contact [email protected] for general support help.

Visit http://www.cloudassert.com/Solutions/Usage to get latest updated information about the product and

http://www.cloudassert.com/Blogs for latest tips and solutions.