Set Session Credentials
You can set a session credential when you log in to Database Management to perform tasks during that session.
A session credential essentially uses a named credential and can be set to perform tasks in Database Management, if the required preferred credential is not set. On the Managed database details page, a message is displayed if the Advanced diagnostics preferred credential is not set and you can click the links available in the message to set the preferred credential or a session credential. If you click Dismiss in the message box, the message disappears, however, you have the option of setting a session credential in the Credentials section on the Managed database details page.
- A session credential can only be used during that particular session and it will have to be set again if you log out and log back in to Database Management.
- If a session credential is set and a preferred credential is also set using different user credentials, then the session credential takes precedence over preferred credentials and is automatically selected when you perform tasks and you have the option of using the session credential, selecting the preferred credential, or providing new credentials. If a session credential is set, then it's used to run the on-demand ADDM task or to kill sessions in Performance Hub.
- For Autonomous Databases, the session credential must be set to use the
ADMIN
user to use advanced Performance Hub features, namely Top Activity Lite, Activity Session History and Instance-level AWR reports, On-demand ADDM task runs, and SQL tuning.
To create a session credential in the Credentials section:
- Go to the Managed database details page and on the left pane under Resources, click Credentials.
- Click Set session credential to the right of the Credentials section.
- In the Set session credential panel, select one
of the following options in the Credential type drop-down
list:
- Named credentials: Select this option to
associate the session credential with an existing named credential and click
the icon to the left of Active credential:
- Scope: Select the scope of the
named credential:
- Resource: A named credential with the Resource scope can be used to access, monitor and manage a single Managed Database.
- Global: A named credential with the Global scope can be used to access, monitor and manage all the Managed Databases in Database Management.
- Named credential: Select the named credential. If the compartment in which the named credential resides is different from the compartment displayed, click Change compartment and select another compartment.
- Set as preferred credential: Optionally, select this check box and select a preferred credential. If you opt to link the named credential to a preferred credential, you can use the named credential to perform the tasks associated with the preferred credential.
- Scope: Select the scope of the
named credential:
- New credential: Select this option to
create a new named credential:
Note
You must have the permissions required to create a named credential to set it as the session credential. For information, see Perform Prerequisite Tasks and Obtain Required Permissions.- User name: Specify the database user name to connect to the Managed Database.
- User password secret: Select the secret that
contains the database user password from the drop-down list. If the
compartment in which the secret resides is different from the
compartment displayed, click Change
compartment and select another compartment.
If an existing secret with the database user password is not available, then select Create new secret... in the drop-down list to create a secret.
- Role: Select the role from the available options, NORMAL or SYSDBA.
- Named credential name: Enter a unique name for the named credential.
- Password secret access mode:
Select the password secret access mode:
- User: The permission to access the password secret is defined for a user in the policy.
- Resource: The permission to access the password secret is defined for the type of resource (for which the named credential is created) in the policy.
- Set as preferred credential: Optionally, select this check box and select a preferred credential. If you opt to link the named credential to a preferred credential, you can use the named credential to perform the tasks associated with the preferred credential.
- Named credentials: Select this option to
associate the session credential with an existing named credential and click
the icon to the left of Active credential:
- Click Save.
On setting the session credential, you can view it on the upper-right corner of the Managed database details page and edit or clear it, if required.
For information on:
- Preferred credentials, see Set Preferred Credentials.
- Named credentials, see Create and Manage Named Credentials.