Home » RDBMS Server » Server Administration » not able to connect as shared server
not able to connect as shared server [message #296578] Mon, 28 January 2008 05:38 Go to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
OS windows server 2003 EE
DB oracle 10.2.0
RAM 8G

Hi friends, i have configured shared server in my database, though the clients are connecting as Dedicated connections.

I have configured shared server by setting the parameters shared_servers=10
dispatchers='(PROTOCOL=TCP) (DISPATCHERS=3)'

Can you please give me suggestions where iam wrong.


Regards
Nand Kumar
Re: not able to connect as shared server [message #296581 is a reply to message #296578] Mon, 28 January 2008 05:43 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Check if in their tnsnames.ora file they don't specify the server must be dedicated.

Regards
Michel
Re: not able to connect as shared server [message #296582 is a reply to message #296578] Mon, 28 January 2008 05:45 Go to previous messageGo to next message
mkbhati
Messages: 93
Registered: February 2007
Location: Mumbai
Member
Nand Kumar
Please specify explicitly server=shared or dedicated in your connect identifier in tnsnames.ora. dedicated is default if you do not specify any.

Regards

Manjit Kumar [mkbhati]
Re: not able to connect as shared server [message #296605 is a reply to message #296582] Mon, 28 January 2008 06:42 Go to previous messageGo to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
Thank you friends for your prompt response.

Yes, the default is dedicated server connection if we dont specify 'server' parameter in Tnsnames.ora ....I dont know how i missed that trivial thing. Now Iam able to connect.


Thankyou Mr Cadot and Mr Bhati


NandKumar
Re: not able to connect as shared server [message #296609 is a reply to message #296582] Mon, 28 January 2008 06:47 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I beg to differ.
There is no default.
If you say nothing and your instance is configured for shared server then you use shared server, if it is not configured then you use dedicated server.

Regards
Michel
Re: not able to connect as shared server [message #296620 is a reply to message #296609] Mon, 28 January 2008 07:37 Go to previous messageGo to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
Michel, I have a doubt, if iam running on dedicated server mode, after some time I have set the parameters for shared server, then the new client connections...(assume they dont have server=shared parameter in the tnsnames.ora) will they be dedicated connections or shared connections?

On my test database, iam able to connect as shared server connection, but on production, iam facing the error

ORA-12523: TNS:listener could not find instance appropriate for the client connection


The status of listener on the server shows status 'UNKNOWN'. Whereas on the test database shows 'READY'. I have read that status ready is when the PMON registers the database information with the server.

So, is this the cause that Iam not able to connect to database using shared server connection( status=UNKNOWN)
Re: not able to connect as shared server [message #296638 is a reply to message #296620] Mon, 28 January 2008 08:34 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
ORA-12523: TNS:listener could not find instance appropriate for the client connection
 *Cause:  The listener could not find any available (database) instances,
 that are appropriate for the client connection.
 *Action: Run "lsnrctl services" to ensure that the instance(s) are
 registered with the listener, and have status READY.

Status UNKNOWN is when instance is not registered.
You can use "alter system register" to register the instance.

Quote:
after some time I have set the parameters for shared server, then the new client connections... will they be dedicated connections or shared connections?

If they don't specify the server type, they use shared one (at least if database is registered, all my databases are registered so I can't make a test for the opposite).

Regards
Michel
Re: not able to connect as shared server [message #296648 is a reply to message #296638] Mon, 28 January 2008 08:54 Go to previous messageGo to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
Michel, even after running the command, still iam not able to get the listener status as 'READY'. I have restarted the listener as well.

NandKumar
Re: not able to connect as shared server [message #296654 is a reply to message #296648] Mon, 28 January 2008 09:35 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Are you sure the instance try to register to the correct listener?

Regards
Michel
Re: not able to connect as shared server [message #296667 is a reply to message #296654] Mon, 28 January 2008 10:32 Go to previous messageGo to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
Michel, how to know about that?

I will not be able to respond to your reply, since i will be away from my system. I will update you as soon as Iam back

Thank you

Nand Kumar

Re: not able to connect as shared server [message #296746 is a reply to message #296578] Mon, 28 January 2008 23:17 Go to previous messageGo to next message
mkbhati
Messages: 93
Registered: February 2007
Location: Mumbai
Member

Quote:
I beg to differ.
There is no default.
If you say nothing and your instance is configured for shared server then you use shared server, if it is not configured then you use dedicated server.


Michel, my sincere apologies for contradicting your opinion. Either you configure shared servers or not there is always a default $USER service in every oracle database which provides dedicated connections for all user connection requests which do not specify a service name & server type in connection requests. Some operations require dedicated connections, Try startup/shutdown on a shared connection.

A good pointer is here http://www.psoug.org/reference/dbms_service.html

Regards

Manjit Kumar [mkbhati]
Re: not able to connect as shared server [message #296869 is a reply to message #296746] Tue, 29 January 2008 06:40 Go to previous messageGo to next message
NandKumar
Messages: 92
Registered: June 2007
Location: v$hyderabad
Member
Sorry for the delay, the probelem is solved...

Thanks Michel and Bhati

As Michel pointed out, if we have configured shared server, clients automatically connect as shared server connections.

NandKumar

Re: not able to connect as shared server [message #296881 is a reply to message #296746] Tue, 29 January 2008 07:01 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
Some operations require dedicated connections, Try startup/shutdown on a shared connection.

I agree with that and my post does not say the opposite.
It just says that... but wait NandKumar already confirmed it.

See:
C:\Oracle\ora102\NETWORK\ADMIN>type tnsnames.ora
...
MIKA0 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = tcp)(HOST = FR9050482D)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SID = MIKA)
    )
  )
...
C:\Oracle\ora102\NETWORK\ADMIN>sqlplus /@mika0

SQL*Plus: Release 10.2.0.3.0 - Production on Tue Jan 29 14:00:55 2008

Copyright (c) 1982, 2006, Oracle.  All Rights Reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Production
With the Partitioning, Oracle Label Security, OLAP and Data Mining options

SQL> select server from v$session where sid=sys_context('userenv','sid');
SERVER
---------
SHARED

1 row selected.


Regards
Michel
Re: not able to connect as shared server [message #297006 is a reply to message #296578] Tue, 29 January 2008 22:15 Go to previous messageGo to next message
mkbhati
Messages: 93
Registered: February 2007
Location: Mumbai
Member

Michel my sincere thanks for giving your valuable attention. OP's problem is solved but if you permit can we hang on this thread for a while.
Just for sake of test can you try it on local without using Oracle net i.e. without @mika0. Just try sqlplus user_name/user_password on local & see which server you get shared or dedicated ?.

Regards

Manjit Kumar [mkbhati]


Re: not able to connect as shared server [message #297060 is a reply to message #297006] Wed, 30 January 2008 00:45 Go to previous messageGo to next message
Michel Cadot
Messages: 64151
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
You cannot connect with shared server in a local connection.
Only listener knows there are dispatchers and what are their listening port to redirect the connection request.

Regards
Michel
Re: not able to connect as shared server [message #297097 is a reply to message #297060] Wed, 30 January 2008 02:40 Go to previous message
mkbhati
Messages: 93
Registered: February 2007
Location: Mumbai
Member


Thanks Michel

Regards

Manjit Kumar [mkbhati]
Previous Topic: Deinstall 10g
Next Topic: Flashback query(!?)
Goto Forum:
  


Current Time: Fri Dec 09 15:20:09 CST 2016

Total time taken to generate the page: 0.29330 seconds