Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ TNS-03505 name could not be resolved     - Automated Password Generator: Linux under a special password generator (Linux)

- MyCAT log analysis (Database)

- Five strokes to find out the IP address you want to know (Linux)

- XenServer Virtual Machine Installation --- first ISO image file storage expansion (Linux)

- In Spring AOP example explanation (Programming)

- To build a private Docker registry (Server)

- Ubuntu install Scala 2.10.x version (Linux)

- innodb storage engine backup tool --Xtrabackup (Database)

- Installation of Theano + CUDA under Ubuntu (Linux)

- MySQL configuration file my.cnf increase the log file parameter error (Database)

- Ubuntu is expected to allow you to install the latest Nvidia Linux drivers easier (Linux)

- To install PXE + Kickstart under CentOS 6.x operating system (Linux)

- Use the TC flow control test under Linux (Linux)

- 2016, the new Node project Precautions (Programming)

- Linux host system monitoring implement the cgi (Server)

- CoreOS use register mirror to build private warehouse (Linux)

- Linux package management operations Basic entry (Linux)

- Cancel Root Command History under Linux (Linux)

- Teach you how to synchronize Microsoft OneDrive in Linux (Linux)

- RHEL5 stalled due to power service error system can not start (Linux)

 
         
  TNS-03505 name could not be resolved
     
  Add Date : 2018-11-21      
         
         
         
  TNS-03505 name could not be resolved

Symptoms:

[Oracle @ db01 admin] $ tnsping pri
 
TNS Ping Utility for Linux: Version 11.2.0.4.0 - Production on 15-JUN-2015 21:57:52
Copyright (c) 1997, 2013, Oracle. All rights reserved.

Used parameter files:

TNS-03505: Failed to resolve name

[Oracle @ db01 admin] $ sqlplus system / oracle @ pri

SQL * Plus: Release 11.2.0.4.0 Production on Mon Jun 15 21:58:48 2015
Copyright (c) 1982, 2013, Oracle. All rights reserved.

ERROR:

ORA-12154: TNS: could not resolve the connect identifier specified

Enter user-name: ^ C

problem analysis:
    The problem occurs because there are generally two: 1, the name does not exist 2, tns configuration file does not exist.

Problem:

1, first check all the configuration information tnsnames.ora, everything is normal without any problems.

[Oracle @ db01 admin] $ cat tnsname.ora
 
pri =

  (DESCRIPTION =

    (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.50) (PORT = 1521))

    (CONNECT_DATA =

      (SERVER = DEDICATED)

      (SERVICE_NAME = woo)

    )

  )

2. Check the tnsnames.ora files and documents to your users and groups

[Oracle @ db01 admin] $ ll tnsnames.ora
 
-rwxr - r-- 1 oracle oinstall 350 Jun 16 22:04 tnsname.ora

# Is no problem from this point of view, the document is part of oinstall user groups, and also Oracle all permissions

3, so this time we chose to skip the tnsnames.ora manually login to verify whether the normal database

[Oracle @ db01 admin] $ sqlplus system/oracle@192.168.1.50/woo
 
SQL * Plus: Release 11.2.0.4.0 Production on Tue Jun 16 22:34:40 2015
Copyright (c) 1982, 2013, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production

With the Partitioning, Oracle Label Security, OLAP, Data Mining,

Oracle Database Vault and Real Application Testing options
       
SQL> select name from v $ database;

NAME

---------

WOO

SQL> select instance_name, status from v $ instance;

INSTANCE_NAME STATUS

---------------- ------------

woo OPEN

SQL>

# From here we can see that the database is certainly not a problem, the next step we take to deal with this problem by a good listener replace this file monitor file.

4, by uploading a configuration file before listening available compare

[Oracle @ db01 admin] $ ls
 
listener.ora samples shrept.lst sqlnet.ora tnsname.ora tnsnames.ora

[Oracle @ db01 admin] $ chmod u + x tnsnames.ora

[Oracle @ db01 admin] $ ll

total 24

-rwxr-xr-x 1 oracle oinstall 711 Jun 16 22:08 listener.ora

drwxr-xr-x 2 oracle oinstall 4096 Jun 11 21:56 samples

-rw-r - r-- 1 oracle oinstall 381 Dec 17 2012 shrept.lst

-rw-r - r-- 1 oracle oinstall 221 Jun 16 21:59 sqlnet.ora

-rwxr - r-- 1 oracle oinstall 350 Jun 16 22:31 tnsname.ora

-rwxr - r-- 1 oracle oinstall 350 Jun 16 22:04 tnsnames.ora ---- this is uploaded back


# By contrast, some of the hand before I discovered that the file name is wrong, even if the content of the right which does not help.

5, replace the monitor by modifying the file, the issue is resolved:

[Oracle @ db01 admin] $ cat tnsname.ora> tnsnames.ora
 
[Oracle @ db01 admin] $ rm -rf tnsname.ora

[Oracle @ db01 admin] $ sqlplus system / oracle @ pri

SQL * Plus: Release 11.2.0.4.0 Production on Tue Jun 16 23:02:15 2015

Copyright (c) 1982, 2013, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production

With the Partitioning, Oracle Label Security, OLAP, Data Mining,

Oracle Database Vault and Real Application Testing options

SQL> select name from v $ database;

NAME

---------

WOO

SQL> select instance_name, status from v $ instance;

INSTANCE_NAME STATUS

---------------- ------------

woo OPEN

SQL>

SQL> host ls -rtl

total 20

-rw-r - r-- 1 oracle oinstall 381 Dec 17 2012 shrept.lst

drwxr-xr-x 2 oracle oinstall 4096 Jun 11 21:56 samples

-rw-r - r-- 1 oracle oinstall 221 Jun 16 21:59 sqlnet.ora

-rwxr-xr-x 1 oracle oinstall 711 Jun 16 22:08 listener.ora

-rwxr - r-- 1 oracle oinstall 350 Jun 16 23:02 tnsnames.ora

SQL>
     
         
         
         
  More:      
 
- CentOS 6.5 Linux System Customization and Packaging Quick Implementation Script (Linux)
- How to install Git on CentOS 7 (Linux)
- MySQL5.7.10 installation documentation (Database)
- Distributed transaction management Spring declarative transactions (Programming)
- Linux Live CD lets your PC is no longer secure (Linux)
- C language programming entry - macro definitions and enum (Programming)
- MogileFS system installation configuration example (Server)
- Linux system security reinforcement (Linux)
- Monitoring services are running properly and will email alert (Server)
- Use read command to read user input (Programming)
- C # assembly calls across constants, variables and functions (Programming)
- Management and application Oracle external table (Database)
- Linux virtual machines to solve end MySQL database can not remote access (Database)
- CentOS 6.6 install JDK7 (Linux)
- Install Debian Linux with R on the Android system (Linux)
- Android Qemu GPS module (Programming)
- Ten linux version of the system (Linux)
- To help you easily protect the Linux System (Linux)
- C language keywords Comments (Programming)
- Necessity in Java packages (Programming)
     
           
     
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.