title: Importing .dmp file from Oracle 11g to 10g returns error 'Unable to open log file'
body: <p>With the help of Stack Overflow, I've been able to export a dump file of my database from my local machine. The command I used is as follows:</p>
  <pre><code>host expdp tkcsowner/tkcsowner@xe version=10.2 schemas=tkcsowner dumpfile=tnrg.dmp logfile=tnrg.log
  </code></pre>
  <p>Now, my local machine has the OS Windows 7, 32-bit. Hardly a server. It's got Oracle 11g. I want to transfer it to another machine, the test server, running Linux. It has Oracle 10g.</p>
  <p>I am in no way a Linux / Unix expert, but I do have some instructions left for me by the previous person who handled such.</p>
  <p>First, I change privileges to root user via 'su -' - No problems there.</p>
  <p>Log in as 'sqlplus /nolog', and then 'connect sys/sys@xe as dba' - No problems there, either.</p>
  <p>I created a logical dump directory (not sure if this step is needed, but I did it anyway):</p>
  <pre><code>create or replace directory dumpdir as 'usr/lib/oracle/xe/app/oracle/admin/XE/dpdump';
  </code></pre>
  <p>Done, no problems.</p>
  <p>So I take it TNRG.dmp and tnrg.log should be inside that directory. Unfortunately, it could not be copied, for some reason. Access denied. I figured I should log out, log in as root, and copy the stuff from there. It worked, but just to be safe, I logged out of the root, logged back in as my normal user, and did everything above again. D'oh.</p>
  <p>Finally, with all the stuff in place, now comes the time to import the .dmp and .log. Huzzah!</p>
  <pre><code>impdp tkcsowner/tkcsowner@xe schemas=tkcsowner dumpfile=TNRG.dmp logfile=tnrg.log
  </code></pre>
  <p>Lo and behold, it asks for a username and password. Is it because tkcsowners does not exist on the 10g database? Anyway, I put in 'system' for both. It continued, but warning bells already set off in my head.</p>
  <p>Suddenly:</p>
  <ul>
  <li>Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production</li>
  <li>ORA-39002: invalid operation</li>
  <li>ORA-39070: unable to open the log file.</li>
  <li>ORA-29283: invalid file operation</li>
  <li>ORA-06512: at &quot;SYS.UTL_FILE&quot;, line 475</li>
  <li>ORA-29283: invalid file operation</li>
  </ul>
  <p>At which point, I'm not sure how to proceed. I went into the directory via the command line, and ls -l'ed the contents, showing that both the .dmp and .log have three rwx's, for root. What I have yet to try was to run the entire operation while logged in as root, but I'm not sure how that would change anything.</p>