Oracle介紹SVRMGRL命令(轉)

post0發表於2007-08-10
Oracle介紹SVRMGRL命令(轉)[@more@]

啟動方法:

[oracle@lin /ora]$ svrmgrl 

Oracle Server Manager Release 3.1.5.0.0 - Production

Oracle8i Enterprise Edition Release 8.1.5.0.1 - Production

With the Partitioning and Java options

PL/SQL Release 8.1.5.0.0 – Production

如何獲得使用幫助

打入help,得到: 下面是簡單的語法描述,詳細資料請看Oracle Server Manager User's Guide.

SVRMGR> help

STARTUP      [DBA] [FORCE] [PFILE=filespec] [EXCLUSIVE | SHARED]

[MOUNT dbname | OPEN dbname] [NOMOUNT] 

SHUTDOWN     [NORMAL | IMMEDIATE | ABORT] 

MONITOR      For graphical modes only, bring up a monitor 

ARCHIVE LOG  [START] [STOP] [LIST] [NEXT] [] [ALL] ['destination'] 

RECOVER      { [DATABASE [MANUAL] ] | [TABLESPACE ts-name [,tsname]] } 

CONNECT      [username [/password] ] [INTERNAL] ['@'instance-spec]

DISCONNECT 

SET          options: INSTANCE, ECHO, TERMOUT, TIMING, NUMWIDTH, CHARWIDTH

SHOW         LONGWIDTH, DATEWIDTH, AUTOPRINT and for SHOW: ALL, SPOOL

EXIT

REM

SQL statements can also be executed.

以系統使用者oracle登入:

SVRMGR> connect internal

Connected.

關閉資料庫,現在嘗試一下?!

SVRMGR> shutdown

Database closed.

Database dismounted.

ORACLE instance shut down.

啟動資料庫吧, 我想給它指定引數,並且開啟:

SVRMGR> startup pfile=/ora/dbs/initora8.ora open ora8

ORACLE instance started.

Total System Global Area                         23670160 bytes

Fixed Size                                          64912 bytes

Variable Size                                     6656000 bytes

Database Buffers                                 16777216 bytes

Redo Buffers                                       172032 bytes

Database mounted.

Database opened.

測試一下啦, 先看看資料庫的系統檔案吧:

SVRMGR> select * from system.sysfiles;

TSNAME                         FNAME                                BLOCKS

------------------------------ -------------------------------------------------

SYSTEM             /u01/app/oracle/oradata/ora8/system01.dbf           89600

OEM_REPOSITORY     /u01/app/oracle/oradata/ora8/oemrep01.dbf           2560

RBS                /u01/app/oracle/oradata/ora8/rbs01.dbf              6144

TEMP               /u01/app/oracle/oradata/ora8/temp01.dbf             5120

USERS              /u01/app/oracle/oradata/ora8/users01.dbf            5120

INDX               /u01/app/oracle/oradata/ora8/indx01.dbf             5120

6 rows selected.

嗯, 感覺不錯, 我會了,謝謝。現在退出休息一下吧。

SVRMGR> exit

Server Manager complete

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/8225414/viewspace-942462/,如需轉載,請註明出處,否則將追究法律責任。

相關文章