question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

az vmss diagnostics set --resource-group <rg> --vmss-name <vmss> --settings router_config.json --protected-settings protected.json gives error The value of parameter type is invalid.

See original GitHub issue

az feedback auto-generates most of the information requested below, as of CLI version 2.2.0-1

Describe the bug az vmss diagnostics set cli gives error"The value of parameter type is invalid."

To Reproduce Steps to reproduce the behavior. Run the command

  • az vmss diagnostics set --resource-group <rg> --vmss-name <vmss> --settings router_config.json --protected-settings protected.json

Expected behavior Enable LinuxDiagnostic on VM scale set

Environment summary Install Method (e.g. pip, interactive script, apt-get, Docker, MSI, edge build) / CLI version (az --version) / OS version / Shell Type (e.g. bash, cmd.exe, Bash on Windows)

Docker container - VERSION=" Ubuntu 18.04.4 LTS (Bionic Beaver)"

Additional context Add any other context about the problem here.

It used to work on a older version of az cli 2.0.66

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:21 (9 by maintainers)

github_iconTop GitHub Comments

4reactions
axelgMScommented, Mar 20, 2020

Looks like Azure CLI version 2.2.0 forgot to pass the extension’s type to the underlying Resource Provider.

eg. with CLI 2.1.0 “extensions”: [ { “name”: “customScript”, “properties”: { “autoUpgradeMinorVersion”: true, “publisher”: “Microsoft.Azure.Extensions”, “type”: “CustomScript”, “typeHandlerVersion”: “2.0”, “settings”: {“commandToExecute”:“echo testing”} }

and with CLI 2.2.0 “extensions”: [ { “name”: “customScript”, “properties”: { “autoUpgradeMinorVersion”: true, “publisher”: “Microsoft.Azure.Extensions”, “typeHandlerVersion”: “2.0”, “settings”: {“commandToExecute”:“echo testing”} }

3reactions
qwordycommented, Mar 22, 2020

I have opened a PR to fix this issue. The root cause is that Python SDK abandoned type. Instead, it uses type1 now. I am very confused why there is such kind of change!!!

    def __init__(self, *, name: str=None, force_update_tag: str=None, publisher: str=None, type1: str=None, type_handler_version: str=None, auto_upgrade_minor_version: bool=None, settings=None, protected_settings=None, provision_after_extensions=None, **kwargs) -> None:
        super(VirtualMachineScaleSetExtension, self).__init__(**kwargs)
        self.name = name
        self.type = None
        self.force_update_tag = force_update_tag
        self.publisher = publisher
        self.type1 = type1
Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found