修改了oracle_sid参数,启动数据库,发现报了下面这个错:
C:\Users\HuangXing>sqlplus sys/orcl@191.255.255.253:1523/soc
SQL*Plus: Release 11.2.0.1.0 Production on 星期三 6月 5 21:55:43 2013
Copyright (c) 1982, 2010, Oracle. All rights reserved.
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux-x86_64 Error: 2: No such file or directory
进程 ID: 0
会话 ID: 0 序列号: 0
求助信息:
oracle[~]$oerr ora 01034
01034, 00000, "ORACLE not available"
// *Cause: Oracle was not started up. Possible causes include the following:
// - The SGA requires more space than was allocated for it.
// - The operating-system variable pointing to the instance is
// improperly defined.
// *Action: Refer to accompanying messages for possible causes and correct
// the problem mentioned in the other messages.
// If Oracle has been initialized, then on some operating systems,
// verify that Oracle was linked correctly. See the platform
// specific Oracle documentation.
oracle[~]$oerr ora 27101
27101, 00000, "shared memory realm does not exist"
// *Cause: Unable to locate shared memory realm
// *Action: Verify that the realm is accessible
大致意思应该是由于没有启动实例,所以没有分配共享内存,造成客户端连接失败
检查监听:
Service "HX" has 1 instance(s).
Instance "soc", status READY, has 1 handler(s) for this service...
Service "H_X" has 1 instance(s).
Instance "soc", status READY, has 1 handler(s) for this service...
Service "huangxing2" has 1 instance(s).
Instance "hx2", status UNKNOWN, has 1 handler(s) for this service...
Service "orcl_hx" has 1 instance(s).
Instance "soc", status READY, has 1 handler(s) for this service...
Service "soc" has 1 instance(s).
Instance "hx", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
我的实例名是soc,上面结果的确没有名字为soc的service。
原来,oracle可以用service_names,db_name,dispatchers,db_unique_name当作services去动态注册监听,但是无法把oracle_sid和instance_name当作services去注册监听。
所以,修改了oracle_sid,远程连接数据库时候要注意看看是否有相应的服务名注册了监听。
阅读(2113) | 评论(0) | 转发(0) |