- Operating system level Create directory
[Email protected] ~]# mkdir-p/home/oracle/db_back/
- Modify the owning user of the directory, the owning group
[Email protected] ~]# chown-r oracle:oinstall/home/oracle/db_back/
- Grant the appropriate permissions to the directory
(the user should have read + Write + Execute permissions on the directory)
[Email protected] ~]# chmod 700/home/oracle/db_back/
- Creating a directory at the Oracle database level
sql> Create directory Ora_back as '/home/oracle/db_back/';
Directory created.
- Grant execution permissions to the appropriate user
Sql> Grant all on the directory Ora_back to System;
Grant succeeded.
- Granting users full-Library export permissions
Sql> Grant EXPORT full DATABASE to system;
Grant succeeded.
- To view a script that performs a full library export
[email protected] scripts]$ cat expdp.sh
#!/bin/bash Export Oracle_base=/u01/app/oracle Export Oracle_home= $ORACLE _base/product/10.2.0/db_1 Export ORACLE_SID=ORCL EXPDP system/manager directory=ora_back dumpfile= $ORACLE _sid+ ' Date +%y+%m+%d+%h+%m+%s '. DMP full=y logfile= $ORACLE _ sid+ ' Date +%y+%m+%d+%h+%m+%s '. Log |
- The following error actions and error analysis are included
Error Action 1
[Email protected] ~]# chmod 600/home/oracle/db_back/
[Email protected] scripts]$ sh expdp.sh
Export:release 10.2.0.1.0-64bit Production on Tuesday, December, 2014 16:05:46
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to:oracle Database 10g Enterprise Edition Release 10.2.0.1.0-64bit Production
With the partitioning, OLAP and Data Mining options
Ora-39002:invalid operation
Ora-39070:unable to open the log file.
Ora-29283:invalid file operation
Ora-06512:at "SYS. Utl_file ", line 475
Ora-29283:invalid file Operatio
Error Analysis:
Oracle user has read + Write access to this directory
EXPDP Backup database-with error messages