Page 1 of 2 12 LastLast
Results 1 to 15 of 21
  1. #1
    Join Date
    Apr 2011
    Posts
    19

    Unanswered: Oracle Connection issue localhost

    Hi guys,

    i have a question, recently i installed oracle 11g on my pc, why i can not connect to localhost but i can connect using the ip.

    if i edit the file

    C:\app\Administrator\product\11.1.0\db_1\NETWORK\A DMIN\listener.ora

    using 127.0.0.1 it's not working, i'll attach some screenshots so you can get the idea better.

    help!
    Attached Thumbnails Attached Thumbnails 2011-05-19_123412.jpg   2011-05-19_123429.jpg   2011-05-19_123502.jpg   2011-05-19_123543.jpg  

  2. #2
    Join Date
    Nov 2006
    Posts
    82
    What about firewall? Can you telnet to that ip?
    Code:
    telnet computer_ip 1521

  3. #3
    Join Date
    Apr 2011
    Posts
    19
    with the given ip it's working (192.168.111.143), with localhost it's not, why?

    C:\Documents and Settings\Administrator>telnet localhost 1521
    Connecting To localhost...Could not open connection to the host, on port 1521: C
    onnect failed


    C:\Documents and Settings\Administrator>telnet 127.0.0.1 1521
    Connecting To localhost...Could not open connection to the host, on port 1521: C
    onnect failed

    I have no antivirus or firewall activated
    Last edited by donose.mihai; 05-19-11 at 10:26.

  4. #4
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    It works for me! see below

    bcm@bcm-laptop:~$ telnet 127.0.0.1 1521
    Trying 127.0.0.1...
    Connected to 127.0.0.1.
    Escape character is '^]'.

    Do you understand why it works for me & fails for you?

    Loopback - Wikipedia, the free encyclopedia
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  5. #5
    Join Date
    Apr 2011
    Posts
    19
    i can not understand why it's not working with localhost or 127.0.0.1 and with the actual ip it's working can you be more precise?

    Thanks

  6. #6
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    listener only does what it is told to do.
    Did you configure listener to listen on both IP#s?
    post results from following OS command

    lsnrctl status
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  7. #7
    Join Date
    Apr 2011
    Posts
    19
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC15 21)))
    STATUS of the LISTENER
    ------------------------
    Alias LISTENER
    Version TNSLSNR for 32-bit Windows: Version 11.1.0.7.0 - Produ
    ction
    Start Date 19-MAY-2011 17:12:48
    Uptime 0 days 0 hr. 3 min. 6 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP OFF
    Listener Parameter File C:\app\Administrator\product\11.1.0\db_1\network\a dmin
    \listener.ora
    Listener Log File c:\app\administrator\diag\tnslsnr\cash-f32cdff50a\list
    ener\alert\log.xml
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\ pipe\EXTPROC1521ipc)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168. 111.143)(PORT=1521)))
    Services Summary...
    Service "orcl" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    Service "orclXDB" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    Service "orcl_XPT" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    The command completed successfully


    Shouldn't work as default on localhost(127.0.0.1)????

  8. #8
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >Shouldn't work as default on localhost(127.0.0.1)????
    NO!
    It is only configured as below
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168. 111.143)(PORT=1521)))

    Why do you want it to utilize 127.0.0.1?
    Loopback only works when on DB Server itself.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  9. #9
    Join Date
    Apr 2011
    Posts
    19
    If i add this to the listner

    # listener.ora Network Configuration File: C:\app\Administrator\product\11.1.0\db_1\network\a dmin\listener.ora
    # Generated by Oracle configuration tools.

    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.111.143)(PORT = 1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    )
    )



    and restart the service....look


    C:\Documents and Settings\Administrator>lsnrctl start

    LSNRCTL for 32-bit Windows: Version 11.1.0.7.0 - Production on 19-MAY-2011 17:17
    :59

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

    Starting tnslsnr: please wait...

    TNSLSNR for 32-bit Windows: Version 11.1.0.7.0 - Production
    System parameter file is C:\app\Administrator\product\11.1.0\db_1\network\a dmin\
    listener.ora
    Log messages written to c:\app\administrator\diag\tnslsnr\cash-f32cdff50a\listen
    er\alert\log.xml
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\ pipe\EXTPROC1521
    ipc)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168. 111.143)(PORT=15
    21)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0. 1)(PORT=1521)))
    Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhos t)(PORT=15
    21)))
    TNS-12542: TNS:address already in use
    TNS-12560: TNSrotocol adapter error
    TNS-00512: Address already in use
    32-bit Windows Error: 48: Unknown error

    Listener failed to start. See the error message(s) above...

    and still it's not working to connect on 127.0.0.1

  10. #10
    Join Date
    Apr 2011
    Posts
    19
    Quote Originally Posted by anacedent View Post
    >Shouldn't work as default on localhost(127.0.0.1)????
    NO!
    It is only configured as below
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168. 111.143)(PORT=1521)))

    Why do you want it to utilize 127.0.0.1?
    Loopback only works when on DB Server itself.
    I'm new to oracle don't hate me for being a noob

    But on other databases i can connect locally with localhost or 127.0.0.1 and i was thinking it's from the configuration

  11. #11
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >Listener failed to start. See the error message(s) above...

    WHY do you insist on messing with 127.0.0.1?
    It gains you NOTHING.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  12. #12
    Join Date
    Apr 2011
    Posts
    19
    Look at the picture below, if i modify listner.ora

    # listener.ora Network Configuration File: C:\app\Administrator\product\11.1.0\db_1\network\a dmin\listener.ora
    # Generated by Oracle configuration tools.

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


    and i'll put 127.0.0.1 it's connecting basically but it's not recognizing the SID, if i modify the file again and put the ip, i can connect without any issue, can you explain why?
    Attached Thumbnails Attached Thumbnails 2011-05-19_172532.jpg   2011-05-19_123502.jpg   2011-05-19_123543.jpg  

  13. #13
    Join Date
    Apr 2011
    Posts
    19
    Quote Originally Posted by anacedent View Post
    >Listener failed to start. See the error message(s) above...

    WHY do you insist on messing with 127.0.0.1?
    It gains you NOTHING.
    i want to understand how it works

  14. #14
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >i want to understand how it works
    It is Basic Networking 101 & really has nothing to do with Oracle.

    127.0.0.1 can only ever talk to itself.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  15. #15
    Join Date
    Apr 2011
    Posts
    19
    thanks for the feedback, i really appreciate it, i know what is localhost and what is 127.0.0.1 couldn't understand how oracle deals with it and other databases have no issue what so ever.

    Thanks again

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •