Preparing the Environment
To use obsutil, you need to register a cloud service account, enable OBS, and obtain the access keys (AK and SK) first.
- Register a cloud service account.
Before using OBS, ensure that you have a cloud service account.
- Open a browser.
- Log in to the Huawei Cloud official website.
- In the upper right corner of the page, click Register.
- Enter the registration information and click Register.
- Enable OBS.
Ensure that your account balance is sufficient before using OBS.
- Log in to the management console.
- Click Billing & Costs from the top menu bar. The Billing Center page is displayed.
- Choose Funds Management > Top Up. The Top Up page is displayed.
- Top up the account as prompted.
- Go back to the management console page after the recharging is successful.
- Choose Service List > Object Storage Service to access OBS Console.
- (Optional) Create an IAM user.
For data security, it is recommended that you do not use the account directly to access OBS. Through the Identity and Access Management (IAM) service, you can create a user who has the permission to access OBS resources and manage buckets and objects on obsutil. If you do not need to use any IAM user, skip this step.
- On the top navigation bar of the console, choose Service List > Management & Governance > Identity and Access Management.
- On the displayed IAM console page, create a user group with OBS permissions configured.
For details, see Creating a User Group. After the user group is created, locate the row that displays Global service > OBS in the User Group Permissions, and click Configure Policy in the row to set OBS permissions for the user group.
For details about OBS policies, see Permissions Management.
- Create a user.
For details, see Creating an IAM User. When creating a user, set the User Group to the one created in 3.b with OBS permissions configured and set the access type to Programmatic access.
- If the user group is not configured with OBS permissions, you can configure fine-grain permissions on OBS Console through bucket policies or object policies. For details, see OBS Permission Control.
- If Programming access is not enabled during user creation, enable it by following the instructions provided in Viewing or Modifying IAM User Information.
- Obtain access keys.
OBS uses AKs and SKs in user accounts for signature verification to ensure that only authorized accounts can access specified OBS resources. Detailed explanations about AK and SK are as follows:
- Access key ID (AK): indicates the ID of the access key, which is a unique identifier used together with a secret access key to sign requests cryptographically.
- Secret access key (SK): indicates the private key used together with its associated AK to cryptographically sign requests. The AK and SK are used together to identify a request sender to prevent the request from being modified.
Each user can create a maximum of two valid AK and SK pairs.
Create access keys as follows:
- In the upper right corner of the console page, select My Credentials under the username.
- On the My Credentials page, select Access Keys in the navigation pane on the left.
- On the Access Keys page, click Add Access Key.
Each user can create a maximum of two valid AK and SK pairs.
- In the Add Access Key dialog box that is displayed, enter the password and its verification code.
- If you have not bound an email address or mobile number, enter only the password.
- If you have bound an email address and a mobile number, you can select the verification by email or mobile phone.
- Click OK.
- In the Download Access Key dialog box that is displayed, click OK to save the access keys to your browser's default download path.
Keep the access keys properly to prevent information leakage. If you click Cancel in the dialog box, the access keys will not be downloaded, and you cannot download them later. Re-create access keys if required.
- Open the downloaded credentials.csv file to obtain the access keys (AK and SK).
In the access key file, the value in the Access Key ID column is the AK, and the value in the Secret Access Key column is the SK.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot