4

I'm trying to create a database using DBCA on Oracle 11g installation on Ubuntu Linux 12.04 64 bit.

I followed the instructions here, but I get

ORA-12547: TNS Lost Contact when running DBCA.

Below are the details. Can someone assist with the solution?

  1. Instead of using /opt/oracle as the "oracle" user home, I used /home/oracle

  2. I did not install the libstdc++5 in 32 bit version

  3. I did everything else the same as the posting

  4. Installation resulted in "missing packages". I tried to do an apt-get install for these packages from ubuntu, but ubuntu says that they don't exist. Then I saw in the instructions:

    Once you will reach the "pre-reqs" screen, check "Ignore all" to continue the installation.

  5. When running ./dbca from $ORACLE_HOME/bin, it fails with ORA-12547.

  6. I checked $ORACLE_HOME/network/admin and listener.ora , sqlnet.ora , and tnsnames.ora all look OK.

  7. However, I think that tnsnames.ora is not being read properly, because ./tnsping fails and the error message states that "EZ Connect" was used. But in my sqlnet.ora , I have

    names.directory_lookup = (TNSNAMES,EZCONNECT)
    

    It should use EZ Connect only after tnsnames is tried.

  8. Also, I sometimes get ORA-12541: No listener. I tried running ./netca. Everything is OK until I perform a test on the listener, and it fails.

  9. I can't run ./lsnrctl. Absolutely nothing happens for this, as well as lsnrctl start, stop, status.

  10. I can't go through sqlplus. If I run ./sqlplus , it asks me for username/password directly.

  11. If I do ./sqlplus / as sysdba, then this results in "ORA-12547: TNS lost contact".

  12. All environment variables are set correctly in .bashrc.

  13. I tried re-running root.sh , but the problem is not fixed.

  14. /etc/oratab is OK

  15. /etc/hosts is OK, but I can't always ping the "localhost" or "127.0.0.1", or "ubuntu" or "127.0.1.1"

    The same TNS or Listener errors display.

4

2 回答 2

3
  1. 当我登录oracle(sqlplus system/pass as sysdba)时,我得到了这个:

    错误:  

    ORA-12547: TNS:尝试连接到 Oracle 时失去联系。

  2. 首先,我认为服务器已关闭,但我检查它,它是好的。很多人说'chmod 6751 oracle',我做到了,但我得到了另一个错误:

    错误:

    ORA-01031: 权限不足

    输入用户名:

  3. 最后,我将系统用户从 root 切换到 oracle。我登录成功。

于 2015-09-08T03:53:49.243 回答
0

Ensure the DB is up and running and you can connect locally AS SYSDBA to the database
using Oracle binaries owner (usually oracle:oinstall Unix / Linux user). If it does not
work, probably you encounter a different problem.

1. Check privileges of an Oracle file on Unix / Linux host where database is running:
  cd $ORACLE_HOME/bin
  ls -ltr oracle

2. Change permissions as below:
  chmod 6751 oracle
  ls -ltr oracle

 This code may help you lot.

于 2015-01-20T11:55:13.203 回答