ORA-01093: ALTER DATABASE CLOSE only permitted with no sessions connected解决方法
ORA-01093: ALTER DATABASE CLOSE only permitted with no sessions connected解决方法
在进行物理主备库角色转换的时候遇到ORA-01093错误
SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY; ALTER DATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY * ERROR at line 1: ORA-01093: ALTER DATABASE CLOSE only permitted with no sessions connected
此错误的因为主库中有活动的会话造成的,解决的办法为:
1.杀掉活动会话,重新执行该命令
2.在该命令后面加上with session shutdown即
ALTER DATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY WITH SESSION SHUTDOWN;