- CheckMates
- :
- Products
- :
- CloudMates Products
- :
- Cloud Network Security
- :
- Discussion
- :
- Re: Azure service cme test error "a bytes-like obj...
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Are you a member of CheckMates?
×- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Azure service cme test error "a bytes-like object is required, not 'str'"
Hello Checkmates community,
I'm trying to configure VMSS autoprov on Azure but when I run "service cme test" I got this error:
Testing cbccgdr...
ERROR: Controller cbccgdr failed
ERROR details: a bytes-like object is required, not 'str'
Hope someone from the community can help.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Normally you get this error if you run "service cme test" without setting up azure AD application and application access to subscription.
Following the admin guide: Don´t run service cme test before you finished Step 5.
In addition, the CME Log should give a good understanding what´s going on in the background.
Review logs are created by the CME on the Management Server:
/var/log/CPcme/cme.log*
look for an authorization failed message like the following:
cloud_connectors.https.RequestException: HTTP/1.1 403 Forbidden
b'{"error":{"code":"AuthorizationFailed","message":"The client \'xxxxxxxxxxx' with object id \'xxxxxxxxxx' does not have authorization to perform action \'Microsoft.Network/virtualNetworks/read\' over scope \'/subscriptions/xxxxxxxx\' or the scope is invalid. If access was recently granted, please refresh your credentials."}}'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Andre,
That's is correct, I found out that this is a authorization/IAM issue. I added the service principal application as contributor on VNET and VMSS.
Now it works fine. Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Apologies if below does not help, but worth a try..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
R&D are looking into that and will update once the issue is resolved
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Normally you get this error if you run "service cme test" without setting up azure AD application and application access to subscription.
Following the admin guide: Don´t run service cme test before you finished Step 5.
In addition, the CME Log should give a good understanding what´s going on in the background.
Review logs are created by the CME on the Management Server:
/var/log/CPcme/cme.log*
look for an authorization failed message like the following:
cloud_connectors.https.RequestException: HTTP/1.1 403 Forbidden
b'{"error":{"code":"AuthorizationFailed","message":"The client \'xxxxxxxxxxx' with object id \'xxxxxxxxxx' does not have authorization to perform action \'Microsoft.Network/virtualNetworks/read\' over scope \'/subscriptions/xxxxxxxx\' or the scope is invalid. If access was recently granted, please refresh your credentials."}}'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Andre,
That's is correct, I found out that this is a authorization/IAM issue. I added the service principal application as contributor on VNET and VMSS.
Now it works fine. Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This error can occurs if you use wrong VMSS object in the Access control (IAM).