0

Is there a way to restore very old oracle backup .dump without log file nor schema name? I have only old .dump file.

I've tried:

imp username/password@dbname file=filename.dmp full=y

with this result:

Import: Release 11.2.0.2.0 - Production on Fri Jul 16 12:05:23 2021

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.


IMP-00058: ORACLE error 12154 encountered
ORA-12154: TNS:could not resolve the connect identifier specified
IMP-00000: Import terminated unsuccessfully
3
  • 1
    Error message has nothing to do with the file you're importing. ORA-12154 TNS:could not resolve the connect identifier specified means that dbname can not be resolved to an address to point to a database. Commented Jul 16, 2021 at 12:37
  • Ok, I'm oracle newbie, so is there a way to verify oracle db or schema name and restore from very old dump without a log file?
    – gaspar
    Commented Jul 19, 2021 at 7:06
  • You don’t need to know about the source system, you just need to have the ability to connect to the target system with a sufficiently privileged user. Are you able to connect to your target DB? Commented Jul 19, 2021 at 7:39

1 Answer 1

2

As @AndrewSayer said, it has nothing to do with your dmp file. In order to connect to a database, the client (in your case, 'imp' utility) has to be able to locate the database. This means knowing the server the database is on, the port the database listener is uing, and the service name by which the listener knows the database. This information is usually (though not exclusively) found in the file 'tnsnames.ora',

A typical entry looks something like this:

PDB01 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = vbol83-02)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = pdb01.localdomain)
    )
  )

Of course, the actual values will be unique to your installation.

The portion of your command line "@dbname" references a specific entry in that file. The error ORA-12154 simply means it could not find the entry you referenced. Either it could not locate a file named 'tnsnames.ora', or it found the file but could not find the referenced entry.

The file is normally located at $ORACLE_HOME/network/admin.

Did you bother googling 'ORA-12154'? If you had, you would have gotten many, many hits, possibly even my favorite: https://edstevensdba.wordpress.com/2018/09/19/troubleshooting-ora-12154/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.