A resource owner can share resources with any principal regardless of whether the resource owner and principal are added to a resource directory.

Scenarios

You can share resources with an account in the following scenarios:

  • An Alibaba Cloud account that is not the management account or a member of a resource directory can share resources with another Alibaba Cloud account that is not the management account or a member of a resource directory.
  • The management account or a member of a resource directory can share resources with an Alibaba Cloud account that is not the management account or a member of the resource directory.
  • The management account or a member of a resource directory can share resources with all members in the resource directory, all members in a specific folder in the resource directory, or a specific member in the resource directory.
    Note Resource sharing across resource directories is not supported.

In this example, Alibaba Cloud account A shares one or more vSwitches in a virtual private cloud (VPC) within the account with Alibaba Cloud account B. Alibaba Cloud accounts A and B are not members or management accounts of resource directories.

Step 1: Create a resource share

Use Alibaba Cloud account A to create a resource share, add the vSwitches that need to be shared with Alibaba Cloud account B to the resource share, and then add Alibaba Cloud account B as a principal.

  1. Use Alibaba Cloud account A to log on to the Resource Management console.
  2. In the left-side navigation pane, choose Resource Sharing > Resources I Share.
  3. In the top navigation bar, select the region where the resources to be shared reside.
  4. On the Resources I Share page, click Create Resource Share.
  5. On the Create Resource Share page, enter a name in the Resource Share Name field.
  6. In the Select Shared Resource section, select vSwitch from the Resource Type drop-down list, select the vSwitches that need to be shared from the Resources table, and then click Add.
  7. In the Add Principal section, select All Accounts for the Principal Scope parameter.
  8. Select Alibaba Cloud Account from the Principal Type drop-down list, enter the ID of Alibaba Cloud account B in the Principal ID field, and then click Add.
  9. Click OK.

Step 2: Receive the resource sharing invitation

Use Alibaba Cloud account B to receive the resource sharing invitation initiated by Alibaba Cloud account A.
  1. Use Alibaba Cloud account B to log on to the Resource Management console.
  2. In the left-side navigation pane, choose Resource Sharing > Resources Shared To Me.
  3. On the Resources Shared To Me page, find the created resource share and click Accept in the Actions column.
  4. In the Accept RS message, click Accept.
    After the invitation is accepted, Alibaba Cloud account B can be used to access the shared vSwitches, and invitations for using resources that are added to the resource share in subsequent operations are automatically accepted.