Previous Table of Contents Next


Preparing for Remote Administration

Before you can start up and shut down your instances remotely, you must create a password file for each instance and change an init.ora parameter. Create the password file from the command line with the orapwd command:


> orapwd file=<filenm> password=<passwd> entries=<users>

The filename should typically be in the same directory as your init.ora files, under $ORACLE_HOME/dbs. The filename is typically orapw<sid>. Some platforms give you the capability of setting environment variables stating the name and location of the password file. The entries parameter specifies the number of distinct DBAs and Sysopers who will use this file.

After creating your password file, you must set the init.ora parameter remote_login_password_file = EXCLUSIVE. Exclusive password files must be created for each instance being managed remotely. When you connect to the database and grant SYSDBA or SYSOPER to users, they will be added to the password file. You’ll also need to run catdbsyn for any user who will be using Instance Manager.

Finally, before you can start a database remotely, you need a local copy of the server’s init.ora file residing on the workstation or in a stored configuration file.

Log in to Instance Manager as a user who has been granted SYSDBA or SYSOPER. Make sure you select SYSDBA or SYSOPER in the Connect As field.

After you are connected, select Initialization Parameters on the left side of the Instance Manager window. The parameters will appear on the right side of the screen, separated into four pages by category. Select the Save button to save this configuration (see Figure 21.18).


Figure 21.18.  Saving initialization parameters.

The stored configuration is kept in the workstation’s registry. If you move to another workstation and try to start the database, the stored configuration will not exist on the second workstation.

Shutting Down an Instance

Display the database status page by clicking on the name of the database that you’d like to shut down. There are two ways to begin the shutdown process. You could select the Database menu from the Instance Manager menu bar and then choose Shutdown. You could also click the radio button marked Shutdown and then select Apply on the database status page.

On the Shutdown Options window, select the type of shutdown you would like to perform and click OK (see Figure 21.19). You should soon receive confirmation that the instance was shut down.


Figure 21.19.  Selecting an immediate shutdown.

Starting an Instance

You begin an instance startup just as you did the shutdown, either from the Database menu or from the status page. Select the radio button that indicates the type of startup you’d like to perform. The Instance Started button performs a startup nomount. The Database Mounted button performs a startup mount. The Database Open button performs a normal startup.

Click on the Apply button to begin the instance startup. You will be prompted for the name of the stored configuration or the name of a local parameter file (see Figure 21.20). Click OK and you should soon be notified that the instance has been started.


Figure 21.20.  Select Apply to begin a complete startup.

Editing Stored Configurations

You can modify any of your stored configurations. Simply select the stored configuration name on the left side of the Instance Manager window. The parameters for that configuration will appear in the right side of the window.

Click on the parameter you would like to change, make your modification, and select Apply. Select Save to save the change in the stored configuration. To delete a parameter, click on the right mouse button, select Delete, and then save the configuration.

Managing Schema Objects

Schema objects of all types can be created, modified, and dropped through the use of Oracle Schema Manager. Schema Manager includes most of the schema objects used to support the object-relational model, queuing, and other Oracle8 Server concepts. Some of the newer schema objects in Schema Manager are object types, varrays, nested table types, and queue tables. This section will concentrate primarily on the schema objects introduced in Oracle8, but begins with the creation of a simple table.

Creating Tables

The navigator on the main Schema Manager screen shows all the schema objects supported by this tool. You can create a new schema object by highlighting the object type and clicking the green + icon on the toolbar. You can also right-click on a schema object type and then select the Create option.

When you choose to create a new table, you are given the option of using the Table Wizard or creating the table manually. The next example is from a manual table creation.

The General page on the Create Table window enables you to enter the name and tablespace for the table, as well as the name, datatype, length, and other details for each column in the table (see Figure 21.21). If you scroll to the right, you should have a red X in the Nulls? field for each required column. A green check mark in that field indicates that nulls are allowed.


Figure 21.21.  Creating a table.

On the Constraints page, you can add any additional constraints, such as a primary key, to the table.

The Storage page gives you the option of explicitly entering your storage parameters or allowing Schema Manager to calculate the parameters based on characteristics provided by you. The example in Figure 21.22 shows the Auto Calculation feature. Notice the Show SQL button was selected, so you can see the SQL that will be executed to create the table, including the storage clause. When you click on the Create button, the table and its associated constraints will be created.


Figure 21.22.  Automatically calculating storage parameters.


Tip:  
Grant SELECT privileges on sys.v_$parameter and sys.v_$type_size to the schema owner if you intend to use the Auto Calculation feature to calculate your storage parameters and would like to examine the SQL before executing it. Without these privileges, you will see the message Table or view does not exist in the SQL text box when you attempt to display the SQL.


Previous Table of Contents Next
Используются технологии uCoz