Skip to main content

Hi,

I run az-login again. ALL fine.

 

Azure login works.

I run the Command from the Command Line = Works

/usr/lib/centreon/plugins/centreon_azure_network_networkinterface_api.pl --plugin=cloud::azure::network::networkinterface::plugin --mode=traffic ……

OK: Resource 'cpaze-sftp01635' total BytesReceivedRate: 786.03KB, BytesSentRate: 1.63MB,

 

In The Web Interface:

UNKNOWN: Command error: ERROR: User  'xyz' does not exist in MSAL token cache. Run `az login`.

 

Thanks

Andreas

 

Hello @ahartung,

 

Does the command work with the centreon-engine user ? If it doesn’t, what are the rights of the /var/lib/centreon-engine/.azure/accessTokens.json file? 

 

Regards,


Hi,

 

with centreon-engine user:

UNKNOWN: Command error: ERROR: User  'xyz' does not exist in MSAL token cache. Run `az login`.

 

/var/lib/centreon-engine/.azure/accessTokens.json  = Rights ( 0664 )

 

Oops sorry, I meant who is the owner of the file ? It should be the centreon-engine user and the rights should look like that 

-rw-------. 1 centreon-engine centreon-engine

 

Regards


I found the issue.

azure-cli Version > 2.30 !!

after downgrad the azure-cli - Works

 

https://docs.microsoft.com/en-us/cli/azure/msal-based-azure-cli

 

😁


Latest versions of Azure CLI use MSAL and no longer generate accessTokens.json.

Any existing workflow depending on accessTokens.json no longer works.


Yes we recommend using azure-cli-2.29 IF you really want to use Azure CLI. Otherwise, we recommend using the API. 

 

More information on the dedicated page https://docs.centreon.com/pp/integrations/plugin-packs/getting-started/how-to-guides/azure-credential-configuration/#azure-cli-setup.


Reply