Home » RDBMS Server » Backup & Recovery » Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input
Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135185] Tue, 30 August 2005 06:10 Go to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
Hello, I'm just starting as a DBA. I'm trying to resolve an export problem.


Here is the script I'm using to export the database

Quote:

# !/bin/bash
. /etc/profile.d/oracle.sh
export ORACLE_HOME=/opt/oracle/OraHome1
export ORACLE_SID=unilab
THETNS=unilab.domain.net
MYDATE=`date +%H%M`
THEFOLD=unilab
THESID=UNILAB

echo `date` >>/backup/oratmp/$THEFOLD/log1
/opt/oracle/OraHome1/bin/exp user/password@$THETNS full=yes consistent=yes file=(/backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP,/backup/oratmp/$THEFOLD/$THESID$MYD ATE.F3.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP) filesize=1g log=/backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG


The export is running smooth, but at the end I get following error.

Quote:


...
. . exporting table STATS$SNAPSHOT 1526 rows exported
. . exporting table STATS$SQLTEXT 295126 rows exported
. . exporting table STATS$SQL_STATISTICS 1526 rows exported
. . exporting table STATS$SQL_SUMMARY
EXP-00030: Unexpected End-Of-File encountered while reading input
. . exporting table STATS$STATSPACK_PARAMETERerror closing export file (null)
EXP-00002: error in writing to export file
EXP-00002: error in writing to export file
EXP-00000: Export terminated unsuccessfully




I've looked up the error and this is what I've found
Quote:

EXP-00030: unexpected End-Of-File encountered while reading input

Cause: Encountered an End-Of-File while reading the user input.

Action: If input to export is being redirected, check the file for errors.


I don't really know what the problem is ... any advice??

Greetz
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135197 is a reply to message #135185] Tue, 30 August 2005 07:21 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
>>EXP-00002: error in writing to export file
May be your disk is full.
Did you check?
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135203 is a reply to message #135185] Tue, 30 August 2005 08:07 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
I've checked the diskspace on the backup server, where the export is saved, but there is still enough room.
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135211 is a reply to message #135203] Tue, 30 August 2005 08:32 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Is this error reproducible and consistent always?
Becuase you are using CONSISTENT=y.
If some user is doing any DML during this period, you may get some errors.
and check this too.
May be this a typo / formatting when you posted in this forum
echo `date` >>/backup/oratmp/$THEFOLD/log1
/opt/oracle/OraHome1/bin/exp user/password@$THETNS full=yes consistent=yes file=(/backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP,/backup/oratmp/$THEFOLD/$THESID$MYD ATE.F3.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP) filesize=1g log=/backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG


There is a space here!.

,/backup/oratmp/$THEFOLD/$THESID$MYD ATE.F3.DMP,
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135218 is a reply to message #135185] Tue, 30 August 2005 08:47 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
First of all,Thx for the fast replies.

Now the backups are taken at night around 2AM so there is nobody using the system.

And the space was a format error, in de shell file there is no space. I'm getting this error for a few days now...
I really need to find a solution
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135221 is a reply to message #135218] Tue, 30 August 2005 09:00 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
I cannot reproduce the issue.
Post your crontab,oracle version
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135227 is a reply to message #135185] Tue, 30 August 2005 09:15 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
Database version where the database is running on : 8i (8.1.7.2.0)

Crontab :
40      21      *       *       *       /backup/orascripts/unilab/unilab.sh 1>>/backup/oratmp/unilab/log1 2>/backup/oratmp/unilab/log2



The script the crontab is calling is
# !/bin/bash
. /etc/profile.d/oracle.sh
export ORACLE_HOME=/opt/oracle/OraHome1
export ORACLE_SID=unilab
THETNS=unilab.domain.net
MYDATE=`date +%H%M`
THEFOLD=unilab
THESID=UNILAB

echo `date` >>/backup/oratmp/$THEFOLD/log1
/opt/oracle/OraHome1/bin/exp user/password@$THETNS full=yes consistent=yes file=(/backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F3.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP) filesize=1g log=/backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG

[Updated on: Tue, 30 August 2005 09:17]

Report message to a moderator

Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135233 is a reply to message #135227] Tue, 30 August 2005 09:45 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
1. try to execute the job in command line ( Not via crontab).
If it goes good, the problem is with crontab environment.

2. My wild guess is that, your source database being exported is growing in space now. So,
either increase the FILESIZE value
or add another file (/backup/oratmp/$THEFOLD/$THESID$MYDATE.F6.DMP)



Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135234 is a reply to message #135233] Tue, 30 August 2005 10:05 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
Mahesh Rajendran wrote on Tue, 30 August 2005 16:45

1. try to execute the job in command line ( Not via crontab).
If it goes good, the problem is with crontab environment.

2. My wild guess is that, your source database being exported is growing in space now. So,
either increase the FILESIZE value
or add another file (/backup/oratmp/$THEFOLD/$THESID$MYDATE.F6.DMP)




1.I will test the export in the command line tommorrow and will let you know how it went.

2.The filesize...isn't is so when nr5.dmp is full he creates autmaticly a 6th one...but with a default name ? Or does he just stop when nr 5 is full?


Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135235 is a reply to message #135234] Tue, 30 August 2005 10:14 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
try it?
I ran the script in command line here file F5.dmp is full and waiting for a new filename.
THe behaviour may differ in cronjob
. about to export DBADMIN's tables via Conventional Path ...
. . exporting table                           DEPT          4 rows exported
. . exporting table                            EMP         14 rows exported
. . exporting table                     PLAN_TABLE         19 rows exported
. . exporting table                STG4_FIN_GL_SUM
continuing export into file fold.teng1111.F2.DMP

continuing export into file fold.teng1111.F3.DMP

continuing export into file fold.teng1111.F4.DMP

continuing export into file fold.teng1111.F5.DMP

Export file: expdat.dmp >
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135239 is a reply to message #135235] Tue, 30 August 2005 10:51 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Infact, i can reproduce the case, if the job is executed as cronjob.
oracle@mutation#tail -10  /tmp/log2.log
continuing export into file fold.teng1149.F4.DMP

continuing export into file fold.teng1149.F5.DMP

Export file: expdat.dmp >
EXP-00030: Unexpected End-Of-File encountered while reading input
. . exporting table              STG4_FIN_GL_SUM11error closing export file
EXP-00002: error in writing to export file
EXP-00002: error in writing to export file
EXP-00000: Export terminated unsuccessfully

[Updated on: Tue, 30 August 2005 10:53]

Report message to a moderator

Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135414 is a reply to message #135185] Wed, 31 August 2005 08:48 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
So the solution is that I add a sixth dmp file to the command?

Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135423 is a reply to message #135414] Wed, 31 August 2005 09:16 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Yes.
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #135551 is a reply to message #135185] Thu, 01 September 2005 03:33 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
Yesterdag I changed the export script. And like you have suggested I added a sixth dmp file.

Last night the server took an export of the database.

This morning I check the export ...

Quote:

Export terminated successfully without warnings.


... and it was successfull. So thx for the help everyone Cool

Greetzz
Karel
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #144120 is a reply to message #135185] Tue, 25 October 2005 02:42 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
Info:
Export version : Release 8.1.7.0.1
OS : Linux 8 SuSe
DB : Oracle 8.1.7.2.0


Time has past...

And now I have this error again...

EXP-00030: Unexpected End-Of-File encountered while reading input
. . exporting table STATS$STATSPACK_PARAMETERerror closing export file (null)
EXP-00002: error in writing to export file
EXP-00002: error in writing to export file
EXP-00000: Export terminated unsuccessfully



The export may use 6 dmp files of each 1G. He is only useing 5 of them and when zipped there are only +/- 70 MB large.

This is my export script
# !/bin/bash
. /etc/profile.d/oracle.sh
export ORACLE_HOME=/opt/oracle/OraHome1
export ORACLE_SID=<sid>
THETNS=<tns_name>
MYDATE=`date +%H%M`
THEFOLD=<sid>
THESID=<sid>

echo `date` >>/backup/oratmp/$THEFOLD/log1
/opt/oracle/OraHome1/bin/exp <username>/<password>@$THETNS  BUFFER=1000000  full=yes consistent=yes file=(/backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F3.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP,/backup/oratmp/$THEFOLD/$THESID$MYDATE.F6.DMP) filesize=1g log=/backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG

cp /backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG /backup/oratmp/$THEFOLD/$THESID.LOGSAV.LOG

if test -e /backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP ; then
gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.F1.DMP.gz /backup/oraexports/$THEFOLD/
fi;

if test -e /backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP ; then
gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.F2.DMP.gz /backup/oraexports/$THEFOLD/
fi;

if test -e /backup/oratmp/$THEFOLD/$THESID$MYDATE.F3.DMP ; then
gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.F3.DMP
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.F3.DMP.gz /backup/oraexports/$THEFOLD/
fi;

if test -e /backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP ; then
gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.F4.DMP.gz /backup/oraexports/$THEFOLD/
fi;

if test -e /backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP ; then
gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.F5.DMP.gz /backup/oraexports/$THEFOLD/
fi;

gzip -f /backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG
mv /backup/oratmp/$THEFOLD/$THESID$MYDATE.LOG.gz /backup/oraexports/$THEFOLD/

zgrep "with warning" /backup/oraexports/$THEFOLD/$THESID$MYDATE.LOG.gz > /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.bad
if test -s /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.bad ; then
        echo "Y a Malaise"
       cat  /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.bad |mail -s "Please Check For $THESID Export at $MYDATE " <mail address>
fi;

zgrep "without warning" /backup/oraexports/$THEFOLD/$THESID$MYDATE.LOG.gz > /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.ok
if test  -s /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.ok ; then
        echo "Ca roule ma poule"
#        cat  /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.ok |mail -s "$THESID Export Complete well at $MYDATE " <mail address>
fi;

cat /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.bad >/backup/oraexports/$THEFOLD/Status/expstatusfull
cat /backup/oraexports/$THEFOLD/Status/expstatus$MYDATE.ok >>/backup/oraexports/$THEFOLD/Status/expstatusfull

if test -s /backup/oraexports/$THEFOLD/Status/expstatusfull; then
        echo "Cas résolu en A ou B"
else
        cat /backup/oraexports/$THEFOLD/Status/expstatusfull |mail -s "Please Check For $THESID Export at $MYDATE " <mail address>
fi;

Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #144123 is a reply to message #144120] Tue, 25 October 2005 03:16 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
add a seventh file?
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #144125 is a reply to message #135185] Tue, 25 October 2005 03:27 Go to previous messageGo to next message
bwetkstr
Messages: 114
Registered: August 2005
Senior Member
I've now changed the filesize from 1G to 2G. I will see what will happen...

I will let you know..

Greetz
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #423429 is a reply to message #135227] Thu, 24 September 2009 02:31 Go to previous messageGo to next message
Asubbaiyan
Messages: 1
Registered: September 2009
Location: chennai
Junior Member
Hi,

while taking backup i am gettings the below error message.

EXP-00002: error in writing to export file

EXP-00002: error in writing to export file
EXP-00000: Export terminated unsuccessfully
Re: Export Database => EXP-00030: Unexpected End-Of-File encountered while reading input [message #423430 is a reply to message #423429] Thu, 24 September 2009 02:41 Go to previous message
Michel Cadot
Messages: 68625
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
So fix the error.

Regards
Michel
Previous Topic: backup only arch log
Next Topic: Recover but don't know if database is Archive or Noarchive
Goto Forum:
  


Current Time: Thu Mar 28 13:05:11 CDT 2024