Quantcast
Channel: VMware Communities : All Content - vRealize Automation Tools
Viewing all 9859 articles
Browse latest View live

Request resourceID and RequestID not work at vRA 6.0.2

$
0
0

Hello everyone, how are you today?

 

I am trying to collect some jobs ID to perform a shutdown and power on for several VMs using the REST API at vRA 6.0.2, but the curl command to collect those not working. It gave the result "No JSON object could be decoded".

I am running the follow steps to connect at vRA appliance and try to collect those informations:

 

1) export VRA=server.name.fqdn

2) export ACCEPT="application/json"

3) curl --insecure -H "Accept: application/json" -H 'Content-Type: application/json' --data '{"username":"xxxx","password":"yyyy","tenant":"ttt"}' https://$VRA/identity/api/tokens

4) export AUTH="Bearer MTUyMjY3NDQwNjY2ODo4Y2EyYTU3NjA3OWJjOGU3MTM2OTp0ZW5hbnQ6cmpvdXNlcm5hbWU6ZGNhdXRlbGxhQGxldmVsM2RjLm5ldDplNmEwNThjMzZjYWQ1NTMyMWFlYzVjNDdiZDFmMWQ0YmQ1NDk0NThiMGVkODFiNWVlN2RlYzk4OWE2MmI1NDg0MDNjZjg4MGQyMGQyYjQ4MzI4MzdlY2Y0ZmZiNzViMjIwOWE1MDZjZmU3OTljOGE5ZDMwYTNhMTJhODA1MzRiYw=="

5) curl --insecure -H "Accept: $ACCEPT" -H "Authorization: $AUTH" https://$VRA/catalog-service/api/consumer/entitledCatalogItems | python -m json.tool

6) curl --insecure -H "Accept: $ACCEPT" -H "Authorization: $AUTH" https://$VRA/catalog-service/api/consumer/resources | python -m json.tool

This gave the information about one VM at end, like bellow:

 

            },

            "dateCreated": "2018-01-20T01:28:33.866Z",

            "description": "Provisioned by VMware vCAC",

            "forms": {

                "catalogResourceInfoHidden": true,

                "details": {

                    "extensionId": "csp.places.iaas.item.details",

                    "extensionPointId": null,

                    "type": "extension"

                }

            },

            "hasCosts": true,

            "hasLease": true,

            "iconId": "c24b42b4-538d-4991-9341-a9eab8989ec2",

            "id": "8f5386ea-2fa0-4073-bef9-04204f2df38e",

            "lastUpdated": "2018-01-20T12:20:53.558Z",

            "lease": {

                "start": "2018-01-20T01:07:22.000Z"

            },

            "leaseForDisplay": null,

            "name": "VM-RJO-028",

            "operations": null,

            "organization": {

                "subtenantLabel": "ttttttttttttttttt",

                "subtenantRef": "b6f188fd-aaec-490c-8457-4b7f400ff88e",

                "tenantLabel": "tttttttttttttttt",

                "tenantRef": "tttt"

            },

            "owners": [

                {

                    "ref": "ddddddddddddd",

                    "tenantName": "tttt",

                    "type": "USER",

                    "value": "xxxxxxxxxx"

                }

            ],

            "providerBinding": {

                "bindingId": "dbf7a44e-b5db-4112-9566-8d5351ebafff",

                "providerRef": {

                    "id": "6c0d6ec9-7ef0-42ea-8993-fab7f5cddee7",

                    "label": "iaas-service"

                }

            },

            "requestId": "b870c84f-d840-48c6-b471-4a580288d658",

            "resourceData": {

                "entries": []

            },

            "resourceTypeRef": {

                "id": "Infrastructure.Virtual",

                "label": "Virtual Machine"

            },

            "status": "ACTIVE",

            "totalCost": null

        }

    ],

    "links": [],

    "metadata": {

        "number": 1,

        "offset": 0,

        "size": 20,

       "totalElements": 12,

        "totalPages": 1

    }

}

 

If i try to use the requestID of this VM, by the follow command, i received the follow error:

 

curl --insecure -H "Accept: $ACCEPT" -H "Authorization: $AUTH" https://$VRA/catalog-service/api/consumer/requests/b870c84f-d840-48c6-b471-4a580288d658/resourceViews | python -m json.tool

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current

                                 Dload  Upload   Total   Spent    Left  Speed

100    93  100    93    0     0     49      0  0:00:01  0:00:01 --:--:--    49

No JSON object could be decoded

 

And i can not collect all informations. By other way, i opened the DEV options at Chrome web browser and collect the job string when i perform the Power Off (for example), and collect the follow information:

curl --insecure -H "Accept: $ACCEPT" -H "Authorization: $AUTH" https://vra.level3dc.net/catalog-service/api/consumer/requests/7ac73abf-9b63-44bf-a76b-c35eeb7890b0

{"@type":"ResourceActionRequest","id":"7ac73abf-9b63-44bf-a76b-c35eeb7890b0","iconId":"machinePowerOff.png","version":5,"requestNumber":32247,"state":"SUCCESSFUL","description":null,"reasons":null,"requestedFor":"cloud-rjo@level3dc.net","requestedBy":"cloud-rjo@level3dc.net","organization":{"tenantRef":"rjo","tenantLabel":"Datacenter-RJO","subtenantRef":"b6f188fd-aaec-490c-8457-4b7f400ff88e","subtenantLabel":"CLOUD_OPERATIONS_RJO"},"requestorEntitlementId":"6816129e-d107-40ed-bf1b-f913ab00d321","preApprovalId":null,"postApprovalId":null,"dateCreated":"2018-04-02T13:40:13.145Z","lastUpdated":"2018-04-02T13:40:21.291Z","dateSubmitted":"2018-04-02T13:40:13.145Z","dateApproved":null,"dateCompleted":"2018-04-02T13:40:21.289Z","quote":{"leaseRate":{"type":"moneyTimeRate","cost":{"type":"money","currencyCode":"USD","amount":0.0},"basis":{"type":"timeSpan","unit":"DAYS","amount":1}}},"requestCompletion":{"requestCompletionState":"SUCCESSFUL","completionDetails":"The request was successfully completed"},"requestData":{"entries":[]},"retriesRemaining":3,"requestedItemName":"Power Off - VM-RJO-027","requestedItemDescription":"{com.vmware.csp.component.iaas.proxy.provider@resource.action.name.desc.machine.PowerOff}","stateName":"Successful","phase":"SUCCESSFUL","waitingStatus":"NOT_WAITING","approvalStatus":"POST_APPROVED","executionStatus":"STOPPED","resourceRef":{"id":"855eca83-7019-4a8d-8828-57b90b1aa193","label":"VM-RJO-027"},"resourceActionRef":{"id":"f27f7a47-6f10-4f4a-9808-6d6639344972","label":"Power Off"}}

 

Could someone help me to perform a REST API script to just perform a power off and/or power on? I tried like intruduce, but in this version of vRA i believe that form of connection changed in comparation of new on (vRA 7.x).

 

Thanks in advanced

 

            },
            "dateCreated": "2018-01-20T01:28:33.866Z",
            "description": "Provisioned by VMware vCAC",
            "forms": {
                "catalogResourceInfoHidden": true,
                "details": {
                    "extensionId": "csp.places.iaas.item.details",
                    "extensionPointId": null,
                    "type": "extension"
                }
            },
            "hasCosts": true,
            "hasLease": true,
            "iconId": "c24b42b4-538d-4991-9341-a9eab8989ec2",
            "id": "8f5386ea-2fa0-4073-bef9-04204f2df38e",
            "lastUpdated": "2018-01-20T12:20:53.558Z",
            "lease": {
                "start": "2018-01-20T01:07:22.000Z"
            },
            "leaseForDisplay": null,
            "name": "VM-RJO-028",
            "operations": null,
            "organization": {
                "subtenantLabel": "CLOUD_OPERATIONS_RJO",
                "subtenantRef": "b6f188fd-aaec-490c-8457-4b7f400ff88e",
                "tenantLabel": "Datacenter-RJO",
                "tenantRef": "rjo"
            },
            "owners": [
                {
                    "ref": "cloud-rjo@level3dc.net",
                    "tenantName": "rjo",
                    "type": "USER",
                    "value": "CLOUD_OPERATIONS_RJO cloud-rjo"
                }
            ],
            "providerBinding": {
                "bindingId": "dbf7a44e-b5db-4112-9566-8d5351ebafff",
                "providerRef": {
                    "id": "6c0d6ec9-7ef0-42ea-8993-fab7f5cddee7",
                    "label": "iaas-service"
                }
            },
            "requestId": "b870c84f-d840-48c6-b471-4a580288d658",
            "resourceData": {
                "entries": []
            },
            "resourceTypeRef": {
                "id": "Infrastructure.Virtual",
                "label": "Virtual Machine"
            },
            "status": "ACTIVE",
            "totalCost": null
        }
    ],
    "links": [],
    "metadata": {
        "number": 1,
        "offset": 0,
        "size": 20,
        "totalElements": 12,
        "totalPages": 1
    }
}

Pass Payload to Software Component Property

$
0
0
Our Unix team has requested that we pass them the payload file so they can parse certain custom properties. I have created a custom property, added it to a property group that is applied to the blueprint, added a property to the software component, and binded it to the custom property on the blueprint. however, it passes a null or empty string. i have the custom property being populated at MachineRequested POST via event subscription. The data is there, but it just isn't passing it.  Any ideas?

[vRA 7.3] - Archive period when request DELETE machine

$
0
0

Hi guyz,

 

juste one question.

 

When a user request a destruction of Virtual Machine it's possible to :

 

- Power off Virtual Machine

- Keep this Virtual Machine on vCenter

- Delete virtual machine from vCenter et vRA after 7 days

 

 

Thx for your help.

vROPS 6.6 - Understanding Stress Badge

$
0
0

Hi there

 

I am trying to understand the stress badge within vROPS. I have made some modifications to our monitoring policy in the hopes of getting a clearer picture of stress but seem to be going backwards.

vROPs reports stress as "Good: No Issues" but the graph indicating the "Business Week Workload" is totally red.

 

I have gone through the various CPU metrics (demand, allocation etc) and, as an exampole, during peak periods where demand is 121GHz vs 165GHz available - the cluster reports as still stressed.

 

I have modified the stress zone to be warn/be yellow at 75%, orange at 80% and red at 90% - so with the values above I would expect the colour of the graph to be approaching yellow. I also have a maintenance window in place in order to not take stats into account during our batch/backup windows on Saturday night/Sunday morning

 

Any help or guidance with this would be greatly appreciated

Thanks

 

Stress Page.JPG

Metric Graphs.JPG

vRealize-Automation-ImportCatalogItems Issues

$
0
0

Whenever we modify blueprints in vRA that already exist in the ServiceNow catalog’s and save them, then we re-run the catalogimport job in ServiceNow we don’t see any of the updates we’ve made to the blueprints from vRA in the ServiceNow catalog. Is their a reason the changes aren’t being pulled over, or is their a method to getting those changes to populate?

 

Example: A ServiceNow catalog item already exists for AWS-BSP-2K12 and has all the fields it pulled during its original import. We make a change to the AWS-BSP-2K12 blueprint in vRA and save it. We then re-run the importcatalog items scheduled task in ServiceNow and none of the changes are relected in the catalog.

 

We've discovered a workaround, but its fairly painful in the time that it takes to complete. By removing the CatalogImportLastRunTime key value, it and re-running the vRealize-Automation-ImportCatalogItems it pulls everything back into SN. We've been told that it should import changes to vRA without having to remove this value.

 

Any assistance you can provide would be greatly appreciated.

[vRA 7.3] - Approval Policy

VRA 7.3 and VRO 7.3 How to pass VM payload when "Recofigure" action triggered.

$
0
0

Hi,

We have VRA & VRO 7.3 in our dev environment. All the VMs provisioned will be registered in SNOW CMDB automatically. One of the requirements is to update the CMDB whenever a reconfigure action is triggered. This CMDB can be queried only with CI name or IPaddress. I have tried to use the payload for the "reconfigure" action but it has very minimal information. There is no IP address or hostname in the payload. Would you guide me to get the VRO flows set to capture the VM properties after a successful r"reconfigure" action and process the required data?

vRA 7.3 - vSphere Endpoint Creation

$
0
0

I just finished my new installation of vRA 7.3 in my lab environment. I am having and issue while adding the vSphere Endpoint (vSphere 5.5) to the platform. This is the error:

 

System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a send. ---> DynamicOps.Common.Client.UntrustedCertificateException: Certificate is not trusted (RemoteCertificateChainErrors)

 

Already followed the next KB VMware Knowledge Base importing the vCenter Server certificate to the Trusted root store of all the IAAS machines, including DEMs and Agent. But the error is still the same.

 

Also the certificate that i am using in vSphere is self signed.

 

By the way i also have connected to the same vSphere Platform a vCAC platform in version 6.2.

 

Any ideas?


vRA 7.3 On-Demand NAT Network not receiving DNS info

$
0
0

First off the versions…

vRA 7.3.0.536 Build 5610496

NSX 6.4.0 Build 7564187

 

Issue:  When the blueprint is deployed, the VM receives all the configured IP info from DHCP, except DNS.

 

Setup:  I created a blueprint with a vSphere Windows 10 VM and added an On-Demand NAT Network.  The VM IP settings are configured to receive the information via DHCP.  The On-Demand NAT Network has a parent network profile, external network profile, NAT type (1 to many), subnet mask and gateway assigned in the General tab.  In the DNS/WINS tab I have primary and secondary DNS server along with a DNS suffix, no WINS.  The DHCP tab has the start and end of the range and the IP Ranges tab is empty.  The parent network profile has the same General, DHCP and DNS info.

 

Troubleshooting:  After I’ve deployed the blueprint and I look into the properties of the Edge VM that was created for NAT (vSphere Web Client, Networking and Security, NSX Edges, name of Edge, Manage) I can see that in the DHCP section the entry with IP range has “Auto configure DNS” turned on and of course the DNS info from the parent network profile (and On-Demand NAT Network) is blank.  If I manually make the change and publish then all works fine.  So it seems that during the deployment vRA does not pass on the DNS settings but instead turns auto configure on.

 

I’ve tested with other VMs (different OS) and the behavior is consistent.  The Edge VM deployed by vRA does not receive the DNS settings but auto configure is on.

If someone can point me in the right direction it would appreciated.

howto run script block as different user?

$
0
0

Hi,

within a software component I need to run a setup.exe as a service account.

For some reason I get a "access denied" error whatever I try.

So I simplified it to avoid other factors and just try to run a "whoami | out-file c:\temp\who.log" as a different users. Still failing.

 

what I do:

$securePassword = ConvertTo-SecureString $Password -AsPlainText -Force
$credential = New-Object System.Management.Automation.PSCredential "$domain\$account", $securePassword

start-job -ScriptBlock {whoami | out-file c:\temp\who.log} -Credential $credential | wait-job

 

I also tried start-process ..... -credential ....

with same result.

 

UAC is disabled via registry.

 

Any help would be highly appreciated.

 

Thanks

Andre

VRA 7.3 software component install hang and Failed

$
0
0

Trying to install MySQL software component in Centos 7 blueprint.

VRA log says "Request failed: Machine vraapp26: InstallSoftware : WGET operation failed. Check agent_download.log. Abort.."

 

agent_download.log screen shot is given below.

 

Thanks,

Entitlements - User can only see owned items

$
0
0

I've setup a customer in vRealize. Several of our engineers need to view the machines this customer has, however the engineers can only see the items(machines) of which they themselves are owner. How do I grant an entire business group access to the items?

Do we have a way to disable a resource action based on a condition?

$
0
0

I have some resource actions, and I want the user to see the action only if some condition is met or only if the VM state is eligible for it.

Is there a way we can disable the resource action or is there a better way to achieve it.

 

Thanks,

Isha

vRA/vRO 7 - Get the custom properties values

$
0
0

I am trying to update the VM hostname and created a few property definition and added them into the property group.

 

Within the property group, I have created:

 

  • Extensibility.Lifecycle.Properties.VMPSMasterWorkflow32.BuildingMachine
  • Extensibility.Lifecycle.Properties.VMPSMasterWorkflow32.Request

 

Both have the values __*,*

 

The property group is added to the blueprint and I have also created the new Event Subscriptions with the following setup:

 

  • Select "Machine Provisioning" topic
  • Added the following conditions
      • Data > Lifecycle state name EQUALS VMPSMasterWorkflow32.BuildingMachine
      • Data > Lifecycle state phase EQUALS PRE
      • Data > Machine > Machine Type EQUALS Virtual Machine

 

 

In the vRO workflow scripting, I am passing the "Payload" as Properties into the workflow

 

I am able to retrieve the machine ID

var machine = payload.get("machine");

machineId = machine.get("Id"); // Value is returned

 

var machineProperties = machine.get('properties'); // Getting NULL when retrieving the properties

 

The machineProperties is returning NULL and I am not able to proceed further to retrieve the property definition that I have specified.

 

Am I missing anything? Please help! Thanks.

Non-existing networks in reservation

$
0
0

In several of our reservations, under the Network tab, we see Networks that do not exist anymore.

For now we deselect the checkbox, so the vRO workflows that query the reservations don't use them anymore.

 

But is there a way to really remove them?  They don't exist in vCenter or anywhere else, AFAIK.


VCAC : " Agent status is DOWN" error on the compute resources tab , is this normal?

$
0
0

I see this when I look at the "COMPUTE RESOURCES " tab

 

Agent status=Down

 

help and thanks!!!!!!!

Workaround to add missing vRA blueprint field on ServiceNow Catalog item

$
0
0

If user is unable to see some vRA blueprint form fields on ServiceNow catalog item then do the following check in ServiceNow and perform Import job run again to see if field is now visible or not.

 

There are some vRA blueprint fields excluded to be shown on serviceNow catalog form.

You can check the list below, Go the below URL and find out missing field under "Value"

 

https://<.service-now.com/sys_properties.do?sys_id=12f721ebdb45e20050e7f8c0cf96193c&sysparm_record_target=sys_properties&sysparm_record_row=1&sysparm_record_rows=1&sysparm_record_list=nameCONTAINSvrasn.exclusionList%5EORDERBYname

 

 

If previously missing field is present under "Value" then remove it and click on Update button.

Now run import job again to see if catalog item contains the field which was not visible previously.

 

Error while requesting a virtual machine for provisioning from Servicenow to VMware

$
0
0

The vRA plugin for VMWare has been installed in Servicenow and we are able to pull in Catalog items and CIs from VMware into Servicenow.However we are receiving following error after submitting the catalog item ( for provisioning ) within Servicenow

 

1) Servicenow Jakarta.

2) VMWare plugin installed. ( version compatible )

3) Able to pull in catalog items and CMDB Cis from the vra ( VMWare Infrastructure )

4) After submitting a catalog item , I get the error as attached.

 

--------- Error Log from Servicenow ------

REST call error found inside VRASNRequestUtil.getTemplateViaRest: Method failed: (/catalog-service/api/consumer/entitledCatalogItems/14a239ef-7c12-49f9-9003-bb534a7fbb94/requests/template) with code: 401 - Invalid username/password combo

 

Unable to see catalog items in Service Now

$
0
0

We installed the vRA Plugin for ITSM 3.0 on Service Now Istanbul. We followed the instructions but after executing the scripts we can see the categories but not the category items. also there is no "Add here" button (might be missing because no items are there). I hope somebody can help us.

REST call error found inside VRASNVIDM.step5: Method failed: (/SAAS/t/test/API/1.0/oauth2/token) with code: 400

$
0
0

Hi All,

 

While trying to access vRa page from Servicenow we have below 2 errors in the logs:

 

REST call error found inside VRASNVIDM.step5: Method failed: (/SAAS/t/test/API/1.0/oauth2/token) with code: 400

REST call error found inside VRASNEntitlementUtilTest.preSetEntitlement: Method failed: (/catalog-service/api/consumer/services) with code: 401 - Invalid username/password combo

 

We have basic configuration set up correctly, Catalog item is imported into Servicenow without any issue, while request is approved there is no token generated and requested is not passed to vRa.

Manually when we try to access the page from browser errors are encountered.

We have SSO configured in instance, is it required that vRa should be setup with SSO? Request your support on this. Thanks in advance.

Viewing all 9859 articles
Browse latest View live




Latest Images