• 欢迎访问搞代码网站,推荐使用最新版火狐浏览器和Chrome浏览器访问本网站!
  • 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏搞代码吧

在RedHat Linux环境下手工启动/关闭Oracle 服务

mysql 搞代码 4年前 (2022-01-09) 25次浏览 已收录 0个评论

在RedHat Linux环境下手工启动/关闭Oracle 服务

在RedHat Linux环境下设置手工启动Oracle 10g数据库

1、修改文件/oracle/product/10.2.0/db_1/bin/dbstart

# vi /oracle/product/10.2.0/db_1/bin/dbstart

将以下内容修改为:

ORACLE_HOME_LISTNER=/oracle/product/10.2.0/db_1/(将oracle监听的路径修改正确)

2、修改文件etc/oratab (如果没有此文件,请执行/oracle/product/10.2.0/db_1目录下的root.sh文件,完成10g安装会提示你运行此脚本)

# vi etc/oratab –此用户必须是root

将以下内容修改:

SiebelDB:/oracle/product/10.2.0/db_1:Y –(将N修改成Y,注意必须大写)

开始启动oracle数据库:

[oracle@crmdb ~]$ lsnrctl start

LSNRCTL for Linux: Version 10.2.0.1.0 – Production on 17-APR-2012 16:21:36

Copyright (c) 1991, 2005, Oracle. All rights reserved.

Starting /oracle/product/10.2.0/db_1/bin/tnslsnr: please wait…

TNSLSNR for Linux: Version 10.2.0.1.0 – Production

System parameter file is /oracle/product/10.2.0/db_1/network/admin/listener.ora

Log messages written to /oracle/product/10.2.0/db_1/network/log/listener.log

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1)))

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=crmdb)(PORT=1521)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))

STATUS of the LISTENER

————————

Alias LISTENER

Version TNSLSNR for Linux: Version 10.2.0.1.0 – Production

Start Date 17-APR-2012 16:21:37

Uptime 0 days 0 hr. 0 min. 0 sec

Trace Level off

Security ON: Local OS Authentication

SNMP OFF

Listener Parameter File /oracle/product/10.2.0/db_1/network/admin/listener.ora

Listener Log File /oracle/product/10.2.0/db_1/network/log/listener.log

Listening Endpoints Summary…

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=crmdb)(PORT=1521)))

Services Summary…

Service “PLSExtProc” has 1 instance(s).

Instance “PLSExtProc”, status UNKNOWN, has 1 handler(s) for this service…

The command completed successfully

[oracle@crmdb ~]$ dbstart

Processing Database instance “SiebelDB”: log file /oracle/product/10.2.0/db_1/st artup.log

[oracle@crmdb ~]$ emctl start dbconsole

TZ set to PRC

Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0

Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.

:1158/em/console/aboutApplication

Starting Oracle Enterprise Manager 10g Database Control ……………………….. started.

——————————————————————

Logs are generated in directory /oracle/product/10.2.0/db_1/crmdb_SiebelDB/sysman/log

[oracle@crmdb ~]$

关闭oracle10g服务

停止EM服务 :emctl stop dbconsole

停止oracle服务:dbshut

停止监听服务:lsnrctl stop

[oracle@crmdb ~]$ lsnrctl stop

LSNRCTL for Linux: Version 10.2.0.1.0 – Production on 08-MAY-2012 22:13:18

Copyright (c) 1991, 2005, Oracle. All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))

The command completed successfully

[oracle@crmdb ~]$

emctl status dbconsole –查看EM状态

安装了2个实例的话,自动启动第一实例的EM后,输入如下命令启动第二实例的EM

[oracle@crmdb ~]$ export ORACLE_SID=UATDB –UATDB 是第二实例的SID

[oracle@crmdb ~]$ emctl start dbconsole

TZ本文来源gaodai#ma#com搞@@代~&码网 set to PRC

Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0

Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.

:5500/em/console/aboutApplication

Starting Oracle Enterprise Manager 10g Database Control ………………………… started.

——————————————————————

Logs are generated in directory /oracle/product/10.2.0/db_1/crmdb_UATDB/sysman/log

[oracle@crmdb ~]$


搞代码网(gaodaima.com)提供的所有资源部分来自互联网,如果有侵犯您的版权或其他权益,请说明详细缘由并提供版权或权益证明然后发送到邮箱[email protected],我们会在看到邮件的第一时间内为您处理,或直接联系QQ:872152909。本网站采用BY-NC-SA协议进行授权
转载请注明原文链接:在RedHat Linux环境下手工启动/关闭Oracle 服务

喜欢 (0)
[搞代码]
分享 (0)
发表我的评论
取消评论

表情 贴图 加粗 删除线 居中 斜体 签到

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址