Oracle 11g XE listener does not start when there is another database running
If for any reason you have a two databases running on the same server and one of them is Oracle 11g Express Edition then you will get surprised that listener of XE is not started automatically during boot if there is another listener already running. Debugging the startup script I found that this happens because of a bug in the code, which assumes that XE listener is running if it finds the word LISTENER within the processes list.
In file /etc/init.d/oracle-xe, at line 556 the code is failing:
+ status='oracle 2889 1 0 May13 ? 00:00:05 /oracle/ora112se/bin/tnslsnr LISTENER -inherit' + '[' 'oracle 2889 1 0 May13 ? 00:00:05 /oracle/ora112se/bin/tnslsnr LISTENER -inherit' == '' ']'
As you can see I have another database running and because of the XE startup script found the keyword LISTENER it’s supposing that the XE LISTENER is already running.
Simply changing line 556 from:
status=`ps -ef | grep tns | grep oracle`
status=`ps -ef | grep tns | grep oracle | grep xe`
is fixing the error and now XE listener is started automatically during boot.
- ASM diskgroup unable to mount because of duplicate disk
- Change of network interfaces in Oracle 10g RAC
- Exhaust of Windows 2008 heap memory with Oracle Database 18.104.22.168
- How to run standalone Oracle APEX Listener 2.0 with Oracle 11g XE and APEX 4.1.1
- Oracle DB 10.2.0.3 LISTENER (VIP) goes down on HP-UX 11.23 without reason