Oracle listener

Hello,

we have linux host where multiple oracle instances (instance1, instance2,...) installed. for each instance there  is a listener identified : lsnr_instnace1, lsnr_instance2,....
we had a problem where all listeners stopped/started, and some how instance2 is now using default listener name "LISTENER" instead of lsnr_instance2.

how can I make instance2 use again lsnr_instance2 instead of default "LISTENER".

thanks,
CCVOIPAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

johnsoneSenior Oracle DBACommented:
That should be controlled by the LOCAL_LISTENER parameter.  Documentation for the parameter is here -> http://docs.oracle.com/cd/E11882_01/server.112/e40402/initparams120.htm#REFRN10082
Mark GeerlingsDatabase AdministratorCommented:
Please give us some more information including:
1. Why is there even a default listener running?
2. Do these instances and listeners run under the same Linux user name, or different ones?
3. Do you have separate Oracle_home directories for each instance, or do they share a common Oracle_home?
4. How do the database instances and listeners normally get started following a Linux restart?
5. Is this server part of an Oracle RAC system, or are these single-instance databases?
CCVOIPAuthor Commented:
Hello,

1. Why is there even a default listener running? =>  was set up like that by the previous DBA

2. Do these instances and listeners run under the same Linux user name, or different ones? => different linux user names

3. Do you have separate Oracle_home directories for each instance, or do they share a common Oracle_home? => yes, each instance has it's own home directory (they are all under the same oracle_base directory though)

4. How do the database instances and listeners normally get started following a Linux restart? => not sure about that. there was no linux restart since I got hired (is there anyway to check that?)

5. Is this server part of an Oracle RAC system, or are these single-instance databases? => single-instance databases.

Thanks
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

Mark GeerlingsDatabase AdministratorCommented:
1. OK, but that doesn't mean it needs to be running.
2. Good, we do the same (different Linux users, for example: oracle1 for instance1 and listener1, oracle2 for instance2 and listener2, etc.)
3. Separate Oracle_homes makes it possible to patch or upgrade one without affecting the others.  Of course, if you want to keep them all on the same patch or version number, it means more time is required for patching/upgrading.
4. That is something you should figure out ASAP.  If you experience an earthquake, a snow storm, a flood, a fire, an accident that takes down a utility pole, or someone digging a ditch or trench that cuts an underground power cable, and the power supply to your server room gets interrupted (and your backup generator runs out of fuel) you *WILL* need to know how to restart the listeners and instances if/when your Linux server gets restarted!  Prior to Oracle 11, this was usually done in Linux via a service named: "dbora".  And, for some Oracle11 systems, that is still the case.
5. That keeps things simpler (and cheaper!).

If you need help figuring out how to restart your Oracle instances and listeners, please tell us which  Linux distro and version you have.
CCVOIPAuthor Commented:
linux distro and version: Red Hat Enterprise Linux Server release 5.8 (Tikanga)
Mark GeerlingsDatabase AdministratorCommented:
OK, we have Oracle Enterprise Linux which I understand is almost identical to RedHat.

Look in your /etc/rc.d/init/d directory for a file named: "dbora".  If you have a file there with that name, that likely takes care of your DB and listener start ups.  If you don't have that file there, you will have to look elsewhere for something that may start these automatically.

Look in your /etc directory for an oraInst.loc or oratab file.  They may contain clues.
CCVOIPAuthor Commented:
/etc/rc.d/init.d/ doesn't have "dbora"

cat /etc/oraInst.loc
inventory_loc=/home/oracle/oraInventory
inst_group=dba

Open in new window

cat /etc/oratab
instance1:/var/app/oracle/product/10202:N
instance2:/var/app/oracle/product/10204/instance2:N
instance3:/var/app/oracle/product/10204/instance3:N
instance4:/var/app/oracle/product/10204/instance4:N
instance5:/var/app/oracle/product/10204/instance5:N

Open in new window


oratab indicates that none of my instances's  startup/shutdown auto handled.
CCVOIPAuthor Commented:
if I stop the default LISTENER  and start lsnr_instance2 => will it affect the connected session?

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
johnsoneSenior Oracle DBACommented:
Stopping a listener will not affect connected sessions.  It will prevent new sessions from connecting, but already connected sessions should be fine.
CCVOIPAuthor Commented:
thank you all for your help.

stopping the default "LISTENER" and starting : "lsnr_instance2" worked perfectly.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Oracle Database

From novice to tech pro — start learning today.