Search the VMware Knowledge Base (KB)
View by Article ID

Creating a local user and assigning permissions on an ESXi host (2082641)

  • 12 Ratings
Language Editions

Purpose

This article provides steps to create a local user and assign permissions on an ESXi host. You can create a local user and assign permissions on the ESXi host using the vSphere Client or PowerCLI.

Resolution

Creating a local user account using the vSphere Client

  1. Create a local user on your ESXi host.

    Note: You cannot perform this task on vCenter Server.

    To create a local user on your ESXi host:

    1. Connect directly to the ESXi host using the vSphere Client.
    2. Click the Local Users & Groups tab.
    3. Right-click the window pane and  and click Add.
    4. Enter a login name and a password (user name and UID is generated automatically if you leave the fields blank).

  2. Create a role and assign permissions:

    1. Select Home.
    2. Click Roles and click Add to create a new role with dedicated permissions.
    3. Define a name for the new role and select the necessary permissions.

  3. Assign the new role to the user:

    1. Select Inventory.
    2. Right-click the Permissions tab and click Add Permission.
    3. At the left pane, select Add to add the created user.
    4. At the right pane, select the new created role.

Creating a local user/role using PowerCLI

  1. Run this command to connect to the ESXi host:

    Connect-VIServer -Protocol https -Server FQDN_or_IP_of_VMhost -User root -Password your_password

  2. Run this command to add a new local user:

    New-VMHostAccount -Id account_name -Password your_new_password -Description description_of_the_user
     
  3. Run this command to add a new role with dedicated permissions:

    New-VIRole -Name your_role_name -Privilege “eg: Settings”

  4. Run this command to assign a new role to the new user:

    New-VIPermission -Entity FQDN_or_IP_of_VMhost -Principal account_name -Role your_role_name -Propagate:$true
     

See Also

Request a Product Feature

To request a new product feature or to provide feedback on a VMware product, please visit the Request a Product Feature page.

Feedback

  • 12 Ratings

Did this article help you?
This article resolved my issue.
This article did not resolve my issue.
This article helped but additional information was required to resolve my issue.

What can we do to improve this information? (4000 or fewer characters)




Please enter the Captcha code before clicking Submit.
  • 12 Ratings
Actions
KB: