11.2 Using exadcli for the First Time

This is a multi-step example that demonstrates how to configure your Oracle Exadata Database Machine to use exadcli.

This example shows how to configure access to cell nodes. The same procedure with minor changes can be used for configuring access to database nodes.

  1. Use CellCLI to create the celladministrator user on each node and grant privileges to those users.

    Connect to each remote node and use CellCLI to create the user and assign privileges. In this example, the user is granted all privileges, but you can grant a limited set of privileges that contains only the privileges needed to run the exadcli commands.

    CellCLI> CREATE ROLE administrator 
    
    CellCLI> GRANT PRIVILEGE ALL ACTIONS ON ALL OBJECTS ALL ATTRIBUTES - 
    > WITH ALL OPTIONS TO ROLE administrator 
    
    CellCLI> CREATE USER celladministrator password=* 
    
    CellCLI> GRANT ROLE administrator TO USER celladministrator
  2. On the node where you plan to run exadcli, use ExaCLI to accept the security certificate for each node.

    Note:

    If you are using Oracle Exadata System Software release 19.3 or later, then enter y or n followed by pressing Enter when prompted.
    exacli -l celladministrator -c cell01 --cookie-jar
    
    No cookies found for celladministrator@cell01.
    Password: ********
    EXA-30016: This connection is not secure. You have asked ExaCLI to connect to 
    cell cell01 securely. The identity of cell01 cannot be verified.
    Got certificate from server:
    C=US,ST=California,L=Redwood City,O=Oracle Corporation,OU=Oracle Exadata,
    CN=localhost
    Do you want to accept and store this certificate? (Press y/n)
     y
    exacli celladministrator@cell01> exit
    

    Repeat this step for both cell02 and cell03.

  3. Use exadcli to connect to cells cell01, cell02, and cell03 as the celladministrator user with the --authenticate option.
    $ exadcli -c cell01,cell02,cell03 -l celladministrator --authenticate
    Password:
    cell01: Password: ********
    cell01: exacli celladministrator@cell01:7879>
    cell02: Password: ********
    cell02: exacli celladministrator@cell02:7879>
    cell03: Password: ********
    cell03: exacli celladministrator@cell03:7879>

    exadcli stores the credentials in ~/.exacli/cookiejar so that further exadcli commands to the same cells will not prompt for a password.

  4. Optional: Create a mycells file as the celladministrator user that contains a list of the nodes on which you want to run the commands.
    $ cat mycells
    cell01
    cell02
    cell03
    
  5. Use exadcli to run a command using the mycells file.
    $ exadcli -g mycells -l celladministrator list cell
    
    cell01: cell01   online
    cell02: cell02   online
    cell03: cell03   online

    If you did not create the mycells file, you can instead specify the remote nodes on the command line using the -c option.

    $ exadcli -c cell01,cell02,cell03 -l celladministrator list cell
     detail