Microsoft Windows [版本 6.1.7600]
版权所有 (c) 2009 Microsoft Corporation。保留所有权利。
C:\Users\zoucq>sqlplus /nolog
--no logging的缩写
SQL*Plus: Release 11.1.0.6.0 - Production on 星期一 8月 15 16:07:19 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
SQL> connect sys/pw as sysdba
已连接。
SQL> show user
USER 为 "SYS"
SQL> exit
从 Oracle Database 11g Release 11.1.0.6.0 - Production 断开
C:\Users\zoucq>net stop oracleservicematerial
--material是SID
OracleServiceMATERIAL 服务正在停止......
OracleServiceMATERIAL 服务已成功停止。
C:\Users\zoucq>net start oracleservicematerial
OracleServiceMATERIAL 服务正在启动 ............
OracleServiceMATERIAL 服务已经启动成功。
C:\Users\zoucq>sqlplus / as sysdba
SQL*Plus: Release 11.1.0.6.0 - Production on 星期一 8月 15 16:09:10 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
连接到:
Oracle Database 11g Release 11.1.0.6.0 - Production
SQL> show user
USER 为 "SYS"
SQL> exit
从 Oracle Database 11g Release 11.1.0.6.0 - Production 断开
C:\Users\zoucq>sqlplus /nolog
SQL*Plus: Release 11.1.0.6.0 - Production on 星期一 8月 15 16:09:23 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
SQL> show user
USER 为 ""
SQL> exit
C:\Users\zoucq>sqlplus "sys/pw as sysdba"
SQL*Plus: Release 11.1.0.6.0 - Production on 星期一 8月 15 16:09:46 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
连接到:
Oracle Database 11g Release 11.1.0.6.0 - Production
SQL> show user
USER 为 "SYS"
SQL> exit
从 Oracle Database 11g Release 11.1.0.6.0 - Production 断开
C:\Users\zoucq>net stop oracleservicematerial
OracleServiceMATERIAL 服务正在停止.....
OracleServiceMATERIAL 服务已成功停止。
在SQLPLUS启动和停止Oracle数据库
1 启动
SQL> connect system/manager as sysdba;
SQL> startup open 数据库SID
另一种启动方法是:先安装该数据库,然后通过alter database命令打开.
SQL> connect system/manager as sysdba;
SQL> startup mount 数据库SID;
SQL> alter database open;
2 停止
SQL> connect system/manager as sysdba
SQL> shutdown immediate;
注:如果关闭数据库进行备份,用shutdown或shutdown immediate.
如果在关机过程中出现问题,用shoutdown abort、startup,然后用shutdown.