Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
General
cancel
Showing results for 
Search instead for 
Did you mean: 

any ideas as to why i got the following error messages

Nichelle_1
Occasional Contributor

any ideas as to why i got the following error messages

IMP-00002

I am miffed as to why I'm getting the following errors:

IMP-00002: failed to open /mnt12/exports/idg8_18oct2003.dmp
for read
IMP-00021: operating system error - error code (dec 16, hex 0x10)
Import file: expdat.dmp >

Below is a sample of the export and import files:

"exp_idg2.par" 7 lines, 86 characters
owner=idg2
indexes=y
grants=y
rows=y
compress=y
file=/mnt12/exports/idg2_18oct03.dmp

"imp_idg2.par" 10 lines, 125 characters
buffer=100000
commit=y
fromuser=idg2
touser=idg2
rows=y
grants=y
ignore=y
indexes=n
file=/mnt12/exports/idg2_18oct2003.dmp


The only thing that I can see that may have caused the problem is that i did the export whilst running other imports at the same time.

The exports were all under 1GB.

Basically i was recreating a tablespace so the exports were for the objects owned by the various users who use that tablespace. I dropped the tablespace, recreated it with the same sizes and was about to import when I got the above errors. Any advice?

Thanks,
Nichelle
14 REPLIES
Indira Aramandla
Honored Contributor

Re: any ideas as to why i got the following error messages

Hi Nichelle,

The error you are experiencing is nothing to do with the tablespace re-creation. The import utility (imp) is unable to open the export dump file. Check the file permissions and if the user can read the file.

Explanation:
IMP-00021: operating system error - error code (dec 16, hex 0x10), you must check your OS manual for the respective error code â dec 16â . Usually IMP-00002 and IMP-00021 errors occur when you are exporting to a tape and importing from the tape and your export dump file is very large.

The operating system error(dec 2, hex 0x2)indicates that the import utility could not find the file you specified. Make sure you are using the correct name for the .dmp file and that you are in the same directory as the .dmp or at least specify the complete unix path and name for the file.

The errors you are getting are consistent with the import executable not being able to read such a large file. 2Gig is the limit on import and export files. Try creating a named pipe and cat the contents of the export file to the named pipe, then use named pipe as the input for the import command.

The export dump file may have been transferred, but was not done in binary mode. Or EXPORT DUMP FILE IS TOO LARGE FOR IMPORT UTILITY.


Solution Explanation

To use the dump file, you will need to compress it first, then use the script. With the introduction of large file support on various platforms, export dump files greater than 2 GIG can be created. However, import still cannot read a dump file that is greater than 2 GIG, so you need to compress it first to a size under 2 GIG, then do the import via a pipe and the uncompress command.

I hope this helps
Never give up, Keep Trying
Graham Cameron_1
Honored Contributor

Re: any ideas as to why i got the following error messages

I agree with some of the previous post, your problem is that IMP cannot find the dump file. Is it there and can you read it?
ie try "ls -l /mnt12/exports/idg2_18oct2003.dmp"
However, contrary to what was said, there is no 2Gb (or other) limit on the size of files which imp/exp can handle. Provided that the o/s has largefiles enabled, imp/exp will handle whatever you throw at them. During a recent upgrade, our largest table exported to a 118Gb file, and imported ok. Took a while though....
-- Graham
Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done.
T G Manikandan
Honored Contributor

Re: any ideas as to why i got the following error messages

Nichelle,

I feel that you are right!

that should be the problem

error no.16 for OS i s

EBUSY

The export file is busy with some other import.


Thanks
Nichelle_1
Occasional Contributor

Re: any ideas as to why i got the following error messages

Hi,

1. I checked the permissions on the exports and they were fine.
2. The exports were done to disk and the imports were done from disk.
3. All the exports files were under 1GB.

The last reply from T. G Manikandan said I was right about something. Were you refering to import and export being done together and this could have been the cause of the error? Your clarification will be greatly appreciated.

Thanks
Nichelle
Graham Cameron_1
Honored Contributor

Re: any ideas as to why i got the following error messages

T G Manikandan has not replied - I think he is in a different time zone so I hope he will forgive my reply.

That is exactly what he meant. Error 16 = EBUSY, which implies that some other process is using that file.

Try the fuser command to see what processes are using the file. ie

"fuser -u /mnt12/exports/idg8_18oct2003.dmp"

"man fuser" for a detailed explanation.

-- Graham
Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done.
Nichelle_1
Occasional Contributor

Re: any ideas as to why i got the following error messages

No problem Graham. Any reply is welcome!

Tell me something though.

1. Does this mean the export file was *corrupted* because it was done at the same time as the import?

2.The import I was trying to do was totally unrelated to the import that was done when these exports were created . When I tried doing my import nothing else was being done so I'm not sure how another process could be using that file. I asume you mean the export dump file.

3. T.G Manikandan said that the export is busy with some other import.....I think I'm missing something....maybe I need to understand export/import some more...what does this mean? Is it that the same thing(for want of a better word) that does the export does the import as well....so an import and export cannot be done at the same time? Appreciate your advise again.

Nichelle
Graham Cameron_1
Honored Contributor

Re: any ideas as to why i got the following error messages

1.
Can't say whether it's corrupted or whether it's in use. Have you tried the "fuser" command. Also to see if it is readable at all try "cat /mnt12/exports/idg8_18oct2003.dmp
> /dev/null" - if this gives an error then the problem is with the file. If no error then the problem is with IMP.

2.
Is it possible that some other process (eg backup) was using the file?

3.
I think he was suggesting you may have been trying to import the file whilst an export process was still writing to it. However I have tried this, and it while generates an error, (IMP-00009: abnormal end of export file), it is not the one you are seeing.

Hope this helps.
If so, maybe you'd like to assign some points...

-- Graham
Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done.
Yogeeraj_1
Honored Contributor

Re: any ideas as to why i got the following error messages

hi,
-
Please allow me to suggest you to cross-check all your scripts for Export/Import. Most probably the EXP output file is same in more than 1 script running at the same time.
-
It happened to me once.
-
hope this helps too
-
regards
Yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Nichelle_1
Occasional Contributor

Re: any ideas as to why i got the following error messages


1. I ran the
"fuser -u /mnt12/exports/idg8_18oct03.dmp" command and found that the file is not in use and i also ran the "cat /mnt12/exports/idg8_18oct2003.dmp > /dev/null" command and didn't get an error message thus i can only deduce(as you suggested) that the problem is with the IMP. This baffles me even more now because how can there be a problem with IMP when we can import from other dump files but cannot import from these specific dump files that were created (being exported) at the same time we were doing other totally unrelated imports. Did you mean that there was a problem with the EXP instead?

2. Is there's some unwritten rule which states that exports and imports even though they may be totally unrelated should not be performed simultaneously ?

Nichelle
Graham Cameron_1
Honored Contributor

Re: any ideas as to why i got the following error messages

Re point 2. There is no such unwritten rule.

What Yogeeraj was suggesting is that you may have inadvertently corrupted the file by running 2 simultaneous exports to the same dmp file.

If you are confident that this was not the case then I have run out of suggestions.

Do you have a support contract with Oracle?
If so, I suggest you raise an iTar.

-- Graham
Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done.
Brian Crabtree
Honored Contributor

Re: any ideas as to why i got the following error messages

Nichelle,

Have you tried running this from the command line directly. There could be a problem with the parfile (tab at the end of the file, something like that).

try:

imp userid=user/pass file=/mnt12/exports/idg2_18oct2003.dmp fromuser=idg2 touser=idg2 ignore=y indexes=n commit=y

and see if that runs the import, or if you get the same error.

Thanks,

Brian
Ian Lochray
Respected Contributor

Re: any ideas as to why i got the following error messages

Nichelle,
is it a typo in your post or are the input and export par files really using different input/output files. The post says that the export uses file=/mnt12/exports/idg2_18oct03.dmp
and the input uses
file=/mnt12/exports/idg2_18oct2003.dmp
Mark Grant
Honored Contributor

Re: any ideas as to why i got the following error messages

If it's any help, error 16 is "Mount device busy" This could be the result of all sorts of things. For example, if /mnt12 is automounted and somebody is already in that directory when the system tries to mount it you will get this error.

I don't know anything about the database here but if you can kill off everything using that mount point (re-boot if you can, it's easier) You might be all right. Also, check you are not in that directory yourself when you do the work.
Never preceed any demonstration with anything more predictive than "watch this"
Nichelle_1
Occasional Contributor

Re: any ideas as to why i got the following error messages

Thank-you to everyone who posted replies. I eventually did a recovery and then re-did the exports, dropped the tablespace and re-created it and then imported and had no problems. Although, this time around i did run my exports one at a time.

Nichelle