Solved

Connection to Oracle 11 on Solaris 10

Posted on 2010-09-20
63
658 Views
Last Modified: 2013-12-27
I install Oracle 11.2 on the Solaris server and I can connect locally via the port 1527, but remotely I can't see this port. Please advise.
0
Comment
Question by:gbcbr
  • 27
  • 22
  • 10
  • +2
63 Comments
 
LVL 8

Expert Comment

by:nognew
ID: 33718188
Hi there!
 you need to configure your Oracle Listener to listen on external IP addresses. I believe by default it is only listening on locahost, or even not started at all.
To test it issue commands like:

lsnrctl status
lsnrctl stop
lsnrctl start



Cheers,
t.
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718269
do you have proper tns configuration on client machine. are you able to succesfully run tnsping <tns alias> command.

Also, if you have a firewall running, you need to open the port 1527 so that others can connect through it.
0
 

Author Comment

by:gbcbr
ID: 33718443
Yes, locally it's connected via 1527. But firewall running on CiscoASA, so server and client have no firewall between them. The question is how to open port 1527 for client?
0
 
LVL 8

Expert Comment

by:nognew
ID: 33718487
If you asking about opening a port on a Firewall thats completely another question which should be placed in Network section. As for oracle you need to make sure your listener is running and lsnrctl.ora has the Alias set up to listen on IP:port you want to connect to.
Cheers,
t.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718497
What are you using to connect with?  SQL*Plus or some other app?
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718503
the tns entry will have port=1527 on your client, you do not need to open port 1527 on client, that has to be on server.
0
 

Author Comment

by:gbcbr
ID: 33718544
to slightwv: SQL Developer, but it asks default port 1521
to nognew :
# lsnrctl status
# lsnrctl not found
0
 
LVL 8

Expert Comment

by:nognew
ID: 33718583
gbcbr,
 have you run the command on Server side? This is a server command, if you run it on Server and got that reply, that means your paths and perhaps environemnt variables are not set. Actually you nee dto be an Oracle user to run such commands.
Cheers,
t.
0
 

Author Comment

by:gbcbr
ID: 33718599
I run it from root
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718605
>>to slightwv: SQL Developer, but it asks default port 1521

I've not used sql developer a lot but if you are referring to the port when you click 'new connection' just type over the 1521 and use the correct port.
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718647
can you post the contents of byour tnsnames.ora file here? also, try using sqlplys user/pwd@tnsalias to connect and tell us what is the error?
0
 

Author Comment

by:gbcbr
ID: 33718656
to nognew: the same result under oracle user
to slightwv: if I change and connect, I didn't post. Problem that I can't see from my iMac 1527 port on server
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718677
Also, in sql developer, try to use connection type as TNS and choose alias from the drop down.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718682
>>I can't see from my iMac 1527 port on server

I don't understand what you mean what you say you can't see the port.  Please explain this a little more.

>>can you post the contents of byour tnsnames.ora file here?

SQL Developer doesn't require a tnsnames.ora file.
0
 

Author Comment

by:gbcbr
ID: 33718750
MacOS has Network Utility which can scan any IP about opened ports. In my case I have this result:
Port Scanning host: 10.1.1.7

       Open TCP Port:       21                 ftp
       Open TCP Port:       22                 ssh
       Open TCP Port:       23                 telnet
       Open TCP Port:       25                 smtp
       Open TCP Port:       79                 finger
       Open TCP Port:       111                sunrpc
       Open TCP Port:       513                login
       Open TCP Port:       514                shell
       Open TCP Port:       587                submission
       Open TCP Port:       2049               nfsd
       Open TCP Port:       4045               npp

so 1527 doesn't visible
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718752
sql developer gives option to connect using different ways, one of that is TNS, where you can use your tns entry.
I think that is a better way for beginners, as there are less chances of mistake.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718769
You won't see that port opened.  Unless explicitly told to not behave this way:  The way Oracle works is the listener accepts the connect request, opens a random high-level port then hands off the connection to that port and goes back to listening.

0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718794
Also, the port 1527 need to be opened on server, not on client, I think @gbcbr is confusing client and server configurations as your server is on solaris, this port need on solaris machine.
0
 

Author Comment

by:gbcbr
ID: 33718809
This is tnsnames.ora file:
# This file contains the syntax information for
# the entries to be put in any tnsnames.ora file
# The entries in this file are need based.
# There are no defaults for entries in this file
# that Sqlnet/Net3 use that need to be overridden
#
# Typically you could have two tnsnames.ora files
# in the system, one that is set for the entire system
# and is called the system tnsnames.ora file, and a
# second file that is used by each user locally so that
# he can override the definitions dictated by the system
# tnsnames.ora file.

# The entries in tnsnames.ora are an alternative to using
# the names server with the onames adapter.
# They are a collection of aliases for the addresses that
# the listener(s) is(are) listening for a database or
# several databases.

# The following is the general syntax for any entry in
# a tnsnames.ora file. There could be several such entries
# tailored to the user's needs.

<alias>= [ (DESCRIPTION_LIST =  # Optional depending on whether u have
                        # one or more descriptions
                        # If there is just one description, unnecessary ]
        (DESCRIPTION=
          [ (SDU=2048) ]      # Optional, defaults to 2048
                        # Can take values between 512 and 32K
          [ (ADDRESS_LIST=    # Optional depending on whether u have
                        # one or more addresses
                        # If there is just one address, unnecessary ]
            (ADDRESS=
            [ (COMMUNITY=<community_name>) ]
            (PROTOCOL=tcp)
            (HOST=<hostname>)
            (PORT=<portnumber (1521 is a standard port used)>)
            )
            [ (ADDRESS=
              (PROTOCOL=ipc)
              (KEY=<ipckey (PNPKEY is a standard key used)>)      
            )
            ]
            [ (ADDRESS=
              [ (COMMUNITY=<community_name>) ]
              (PROTOCOL=decnet)
              (NODE=<nodename>)
              (OBJECT=<objectname>)
            )
            ]
              ... # More addresses
          [ ) ] # Optional depending on whether ADDRESS_LIST is used or not
          [ (CONNECT_DATA=
            (SID=<oracle_sid>)
            [ (GLOBAL_NAME=<global_database_name>) ]
            )
          ]
          [ (SOURCE_ROUTE=yes) ]  
        )
        (DESCRIPTION=    
          [ (SDU=2048) ]      # Optional, defaults to 2048
                        # Can take values between 512 and 32K
          [ (ADDRESS_LIST= ]      # Optional depending on whether u have more
                        # than one address or not
                        # If there is just one address, unnecessary
            (ADDRESS
            [ (COMMUNITY=<community_name>) ]
            (PROTOCOL=tcp)
            (HOST=<hostname>)
            (PORT=<portnumber (1521 is a standard port used)>)
            )
            [ (ADDRESS=
              (PROTOCOL=ipc)
              (KEY=<ipckey (PNPKEY is a standard key used)>)
               )
            ]
            ...             # More addresses
          [ ) ]             # Optional depending on whether ADDRESS_LIST  
                        # is being used
          [ (CONNECT_DATA=
            (SID=<oracle_sid>)
            [ (GLOBAL_NAME=<global_database_name>) ]
            )
          ]
          [ (SOURCE_ROUTE=yes) ]
        )
        [ (CONNECT_DATA=
            (SID=<oracle_sid>)
            [ (GLOBAL_NAME=<global_database_name>) ]
          )
        ]
        ...   # More descriptions
      [ ) ]      # Optional depending on whether DESCRIPTION_LIST is used or not
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718835
That looks like the 'sample' one in the samples directory.

It's not necessary to configure this to work with sql developer and IMO confuses people new to Oracle.
0
 

Author Comment

by:gbcbr
ID: 33718874
but the main question: how I can open 1521 and 1527 on the Solaris server and connect to Oracle from client?
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33718887
probably its already open, what makes you feel that the said port is NOT OPEN?
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33718889
You don't open the port.   Oracle takes care of all that for you.

If you enter everything for the database server into the sql*Developer connection page, it will connect.

What error message are you getting?
0
 

Author Comment

by:gbcbr
ID: 33718962
The Network Adapter could not establish the connection
the same with 1521 and 1527
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33719002
are you able to ping the server machine?
are the entries you are using are correct -hostname,port and SID/Service Name?
in your case the port is 1527, you should be able to atleast ping the hostname, and verify the service name.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33719009
From an above request: Log into the solaris machine as the oracle user and post the results of: lsnrctl status
0
 

Author Comment

by:gbcbr
ID: 33719054
$ lsnrctl status
ksh: lsnrctl:  not found
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33719083
The oracle user should have the correct profile.  did you execute the oracle user profile?

but OK(replace SIDNAME with the correct oracle database sid):

export ORACLE_SID=SIDNAME
ORAENV_ASK=NO
. oraenv

the try again

0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33719085
you may need to set your environment, set the path to oracle_home\BIN, also set oracle_home env variable. after that run the above command again.
0
 

Author Comment

by:gbcbr
ID: 33719096
Generally I'm crazy now. I have OS and DB from the same developer Oracle and I have so much headache to connect each other!
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33719121
Trust me, it's not that difficult once you understand how Oracle networking works.

You need certain things in certain places.  Once we understand where everything is on the database server, it should go much easier.
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 

Author Comment

by:gbcbr
ID: 33719154
Thank you everybody for the help, I'm going to sleep now. We'll communicate tomorrow.
Have a nice day.
0
 

Author Comment

by:gbcbr
ID: 33725205
Ok, problem was in non proper installation of Oracle, today I reinstall Oracle with correct value of SWAP, maxshm and maxuprc and I can connect from Mac, but after rebooting Solaris it again unvisible.
System generate proper files listener.ora
tnsnames.ora and sqlnet.oraset
But when start connect to db I have message: The Network Adaptor could not establish the connection.
I'll post these files
0
 

Author Comment

by:gbcbr
ID: 33725214
# tnsnames.ora Network Configuration File: /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

ORCL =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.1.7)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = orcl)
    )
  )

# listener.ora Network Configuration File: /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
# Generated by Oracle configuration tools.

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
      (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.1.7)(PORT = 1521))
    )
  )

ADR_BASE_LISTENER = /u01/app/oracle
0
 
LVL 7

Expert Comment

by:sumit2906
ID: 33725468
do you start you listner and oracle service after reboot? try this:
sqlplus / as sysdba
startup
exit
lsnrctl status
lsnrctl start
0
 

Author Comment

by:gbcbr
ID: 33725513
it doesn't start, maybe we need some path
# lsnrctrl status
lsnrctrl: not found
# su - oracle
Sun Microsystems Inc.   SunOS 5.10      Generic January 2005
$ lsnrctrl status
ksh: lsnrctrl:  not found
$
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33725655
Try the env setup I mentioned in http:#a33719083.
0
 

Author Comment

by:gbcbr
ID: 33726204
I put all path to .profile, but still can't find lsnrctl
So i found it manually and run, but it shows too much errors:

# /u01/app/oracle/product/11.2.0/dbhome_1/bin/lsnrctl

LSNRCTL for Solaris: Version 11.2.0.1.0 - Production on 21-SEP-2010 18:23:59

Copyright (c) 1991, 2009, Oracle.  All rights reserved.

Message 850 not found; No message file for product=network, facility=NL
LSNRCTL> start
Message 1070 not found; No message file for product=network, facility=TNSTNS-12545: Message 12545 not found; No message file for product=network, facility=TNS
 TNS-12560: Message 12560 not found; No message file for product=network, facility=TNS
  TNS-00515: Message 515 not found; No message file for product=network, facility=TNS
   Solaris Error: 2: No such file or directory
LSNRCTL>
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726229
>>I put all path to .profile, but still can't find lsnrctl

Then the PATH you added is wrong.

You need to have ORACLE_HOME set as well.  

What we really need to see is the 'status' not the 'start' (unless the listener isn't running).
0
 

Author Comment

by:gbcbr
ID: 33726254
LSNRCTL> status
Message 1053 not found; No message file for product=network, facility=TNSTNS-12541: Message 12541 not found; No message file for product=network, facility=TNS
 TNS-12560: Message 12560 not found; No message file for product=network, facility=TNS
  TNS-00511: Message 511 not found; No message file for product=network, facility=TNS
   Solaris Error: 146: Connection refused
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726276
Did you set up ORACLE_HOME and have the proper PATH before you ran the status?
0
 

Author Comment

by:gbcbr
ID: 33726290
#
# Copyright (c) 2001 by Sun Microsystems, Inc.
# All rights reserved.
#
# ident      "@(#)local.profile      1.10      01/06/23 SMI"
stty istrip
umask 022
DISPLAY=:0.0
export DISPLAY
PATH=/usr/bin:/usr/ucb:/etc:/usr/openwin/bin:.
export PATH
TMP=/tmp
TMPDIR=/tmp
ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
ORACLE_BASE=/u01/app/oracle
ORACLE_SID=orcl
ORACLE_OWNER=oracle
export ORACLE_HOME ORACLE_BASE ORACLE_SID ORACLE_OWNER
ADR_BASE_LISTENER=/u01/app/oracle
export ADR_BASE_LISTENER
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726300
The PATH isn't set up property:

export PATH=$ORACLE_HOME/bin:/usr/bin:/usr/ucb:/etc:/usr/openwin/bin:.
0
 

Author Comment

by:gbcbr
ID: 33726507
I don't understand why they are not the same

#
# Copyright (c) 2001 by Sun Microsystems, Inc.
# All rights reserved.
#
# ident      "@(#)local.profile      1.10      01/06/23 SMI"
stty istrip
umask 022
DISPLAY=:0.0
export DISPLAY
PATH=$ORACLE_HOME/bin:/usr/bin:/usr/ucb:/etc:/usr/openwin/bin:.
export PATH
TMP=/tmp
TMPDIR=/tmp
ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
ORACLE_BASE=/u01/app/oracle
ORACLE_SID=orcl
ORACLE_OWNER=oracle
export ORACLE_HOME ORACLE_BASE ORACLE_SID ORACLE_OWNER
ADR_BASE_LISTENER=/u01/app/oracle
export ADR_BASE_LISTENER

# su - oracle
Sun Microsystems Inc.   SunOS 5.10      Generic January 2005
$ env
_=/bin/env
LANG=C
HZ=
PATH=/bin:/usr/bin:/usr/ucb:/etc:/usr/openwin/bin:.
ORACLE_BASE=/u01/app/oracle
LOGNAME=oracle
MAIL=/var/mail/oracle
ORACLE_SID=orcl
ORACLE_OWNER=oracle
DISPLAY=:0.0
SHELL=/bin/ksh
ADR_BASE_LISTENER=/u01/app/oracle
HOME=/export/home/oracle
TERM=xterm
ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
PWD=/export/home/oracle
TZ=EET
$
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726526
>>I don't understand why they are not the same

Different users have different profiles.  Why do you think they should be the same?

You really can't add $ORACLE_HOME to the PATH before you set it.  Move the PATH statement below the ORACLE_HOME statement.
0
 

Author Comment

by:gbcbr
ID: 33726577
these are .profile and env from one user - oracle
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726596
>>these are .profile and env from one user - oracle

The first looks like it is from 'root', then you did a 'su - oracle' which executes oracle's profile.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726607
OH, are you saying the first is actually oracle's .profile and not root's or /etc/profile?
0
 
LVL 76

Accepted Solution

by:
slightwv (䄆 Netminder) earned 500 total points
ID: 33726627
>>PATH=$ORACLE_HOME/bin:/usr/bin:/usr/ucb:/etc:/usr/openwin/bin:.

$ORACLE_HOME isn't set yet so it's '/bin'
0
 

Author Comment

by:gbcbr
ID: 33726696
PATH=/u01/app/oracle/product/11.2.0/dbhome_1/bin:/usr/bin:/usr/ucb:/etc:/usr/ope.......
Thank you very much!
It starts work!

LSNRCTL> start
Starting /u01/app/oracle/product/11.2.0/dbhome_1/bin/tnslsnr: please wait...

TNSLSNR for Solaris: Version 11.2.0.1.0 - Production
System parameter file is /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Log messages written to /u01/app/oracle/diag/tnslsnr/unknown/listener/alert/log.xml
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Solaris: Version 11.2.0.1.0 - Production
Start Date                21-SEP-2010 19:13:16
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/unknown/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))
The listener supports no services
The command completed successfully
LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Solaris: Version 11.2.0.1.0 - Production
Start Date                21-SEP-2010 19:13:16
Uptime                    0 days 0 hr. 0 min. 9 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/unknown/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))
The listener supports no services
The command completed successfully
LSNRCTL> $
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726756
>>  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))


The listener.ora file is telling it to use port 1521.  Where are you getting the original port 1527?
0
 

Author Comment

by:gbcbr
ID: 33726813
I don't now. For me it's little bit confusing, because when I was connect locally it shows 1527, but remotely 1521. Maybe for local and remote connections Oracle use different ports?
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33726833
>>Maybe for local and remote connections Oracle use different ports?

Nope.  add the ip address 10.1.1.7 and 1521 in sqldeveloper connection fields and see if you can connect.
0
 

Author Comment

by:gbcbr
ID: 33727398
No connection, message error ORA-12505, TNS:listener does not currntly know of SID given in connect description.
For me this is strange - in lsnrctl window only listener.ora, but no tnsnames.ora
But all information about SID in tns file

LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=orcl)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Solaris: Version 11.2.0.1.0 - Production
Start Date                21-SEP-2010 20:27:26
Uptime                    0 days 0 hr. 0 min. 9 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/unknown/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=orcl)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))
The listener supports no services
The command completed successfully
LSNRCTL>
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33727452
sorry I missed that the first time:
The database hasn't registered with the listener yet.  Is the database up and running?
0
 

Author Comment

by:gbcbr
ID: 33727534
I've reinstall system completely, so I don't want any local work on DB. I plan to connect to Oracle from iMac with SQL Developer. But at the moment I have problem to connect to DB to SQLD.
It looks very strange, because SID_NAME wrote directly in tnsnames.ora
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33727644
The listener status doesn't show it is listening for a database.   The database should register with the listener on startup.

The status should shoe something like (assuming your database is called ORCL):
Service "ORCL" has 1 instance(s).
0
 

Author Comment

by:gbcbr
ID: 33727730
this I  understand, but why it can't see db?
0
 

Author Comment

by:gbcbr
ID: 33727771
So, if listener doesn't see orcl db, we can't see this db from remote?
0
 

Author Comment

by:gbcbr
ID: 33727794
I'm crazy, it looks like we try to develop new OS&DB not just install two products from one developer
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 33728127
>>this I  understand, but why it can't see db?

Is the database up and running?  
What is the instance name?

Starting in 10g you no longer need to add instances to the listener.ora file.  The instance is suppose to automatically register with the listener.  

You can manually add an entry in the listener.ora file:
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)
      (PROGRAM = extproc)
    )
    (SID_DESC =
      (GLOBAL_DBNAME = ORCL)
      (ORACLE_HOME =/u01/app/oracle/product/11.2.0/dbhome_1)
      (SID_NAME = dev1ora)
    )
  )


>>So, if listener doesn't see orcl db, we can't see this db from remote?

Correct.  It's the listeners job to accept the connect request and connect you to the database.  If the listener isn't listening for that database, it can't connect you.

>>it looks like we try to develop new OS&DB not just install two products from one developer

I don't understnad this comment.
0
 

Author Comment

by:gbcbr
ID: 33732242
Last comment means that too much time and efforts for very simple installation which has to take one hour job.
Finally I solve problem with your big help. I didn't change anything in listener.ora, I just go with DBCA create new DB sample and connect to it in 1 second, but orcl DB still unavailable, something was wrong in structure.
Again thanks a lot for your great help to understand how it works.

LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=orcl)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Solaris: Version 11.2.0.1.0 - Production
Start Date                22-SEP-2010 08:04:03
Uptime                    0 days 2 hr. 28 min. 51 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/unknown/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=orcl)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.1.7)(PORT=1521)))
Services Summary...
Service "sample" has 1 instance(s).
  Instance "sample", status READY, has 1 handler(s) for this service...
Service "sampleXDB" has 1 instance(s).
  Instance "sample", status READY, has 1 handler(s) for this service...
The command completed successfully
0
 
LVL 12

Expert Comment

by:praveencpk
ID: 33776646
check in net configuration orcl DB is added in the services tab.

to open net manager
$ORACLE_HOME/bin netmgr
if it is not added add the service in it.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now