Forum Stats

  • 3,724,436 Users
  • 2,244,759 Discussions
  • 7,851,013 Comments

Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

How to set the listener in 11g r2 in linux

djgeo
djgeo Member Posts: 57
Hi,


can someone guide me on adding a new listener other than the default port in oracle 11g r2 in linux?


I tried editing the tns names.ora and listener.ora files.

My dbca ,oui and netca is not coming up while i try to access them.


Thank you.
Tagged:

Answers

  • Zoltan Kecskemethy
    Zoltan Kecskemethy Member Posts: 1,142
    cd $ORACLE_HOME/network/admin
    fire up your favorit editor like vi :) and create two configuration files:
    first one: sqlnet.ora
    # sqlnet.ora Network Configuration File: /home/oracle/app/oracle/product/11.1.0/db_1/network/admin/sqlnet.ora
    # Generated by Oracle configuration tools.
    
    NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)
    second one: listener.ora Edit your host name here!
    # listener.ora Network Configuration File: /your_oracle_home_full_path_would_be_here/network/admin/listener.ora
    # Generated by Oracle configuration tools.
    
    LISTENER =
      (DESCRIPTION_LIST =
        (DESCRIPTION =
          (ADDRESS = (PROTOCOL = TCP)(HOST = <your_server_full_name_or_IP>)(PORT = 1521))
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
        )
        (DESCRIPTION =
          (ADDRESS = (PROTOCOL = TCP)(HOST = EPBSD082)(PORT = 8080))(Presentation = HTTP)(Session = RAW)
        )
        (DESCRIPTION =
          (ADDRESS = (PROTOCOL = TCP)(HOST = EPBSD082)(PORT = 2100))(Presentation = FTP)(Session = RAW)
        )
      )
    ans start up your listener.
    lsnrctl start
    you have to setup your oracle shell variables for this!
    I do it with this way(using oracle oraenv script)
    I added these lines into my .bash_profile
    echo "Setting enviroment for MYDB as default"
    export ORACLE_SID=MYDB
    export ORAENV_ASK=NO
    . oraenv
    export ORACLE_UNQNAME=$ORACLE_SID
    export ORAENV_ASK=YES
    export NLS_LANG=AMERICAN_AMERICA.UTF8
    this will setup
    ORACLE_BASE, ORACLE_HOME, ORACLE_SID, ORACLE_UNQNAME, ORAENV_ASK, LD_LIBRARY_PATH and PATH (will add ORACLE_HOME/bin into it so you can run lsnrctl from any dir...)
  • Zoltan Kecskemethy
    Zoltan Kecskemethy Member Posts: 1,142
    BTW if you setup a vnc server and log in to it you may able to run all the tools you mentioned...
    Zoltan Kecskemethy
  • djgeo
    djgeo Member Posts: 57
    when i try to acess the dbca,oui and netca...nothing is coming up.Is it an issue with the database installation?
    but the installation of the database was successfull and i could connect to the database.But when i give lsnrctl it shows an error.

    TNS-12545- TNS:NO LISTENER
    TNS-12560- TNS:PROTOCOL ADAPTER ERROR
    TNS-00515- NO LISTENER
  • EdStevens
    EdStevens Member Posts: 27,993 Gold Crown
    user9336763 wrote:
    Hi,


    can someone guide me on adding a new listener other than the default port in oracle 11g r2 in linux?
    Why? One default listener, on one default port, is quite capable of servicing multiple database instances of multiple versions running from multiple homes.
    >
    I tried editing the tns names.ora and listener.ora files.
    The listener doesn't care about tnsnames.ora
    My dbca ,oui and netca is not coming up while i try to access them.

    So exactly what DOES happen? These are gui tools, so on *nix you'll need to export your DISPLAY variable to an x-server.
    Thank you.
  • Zoltan Kecskemethy
    Zoltan Kecskemethy Member Posts: 1,142
    Did you setup your oracle shell variables as I advice to do so?
    Please give us more info what did you try and how.
  • IAK Tanoli
    IAK Tanoli Member Posts: 46
    Kindly paste your /etc/hosts and $ORACLE_HOME/network/admin/listener.ora file
  • djgeo
    djgeo Member Posts: 57
    when i installed oracle 11g in linux,towards the end of the install i got an error msg:


    "Enterprise manager configuration failed due to the following error:

    The Listener is not up or database service is not registered with it.Start the listener and register database service and run em configuration assistant again."
  • Oviwan
    Oviwan Member Posts: 1,062
    start netca as oracle
    cd $ORACLE_HOME/bin
    ./netca --> you need a x-window
    and create a listener then start it with "lsnrctl start"
    check the status with lsnrctl status
This discussion has been closed.