Saturday, August 22, 2009

Oracle Database : Complete Export and Import


Suppose, we need to export all the Oracle schema in one step, similar
to "--all-databases" option in MySQL. In such cases, here is how its done:
exp USERID=system/password@sid file=complete_bak.dmp log=/tmp/full.log FULL=Y;
This should export all the databases in one step and will store that to a single file.

Now to import that back, here is what needs to be done.
imp system/password@sid file=complete_bak.dmp log=/tmp/full.log full=y ignore=y
Note:

* Will work only if ORACLE_HOME is same on both servers
* Create tablespace on the new server before importing the database. Else this wont work.

OpenOffice Error : The user interface language cannot be determined-Linux


Stuck at this error after re-installing or upgrading OpenOffice?

OpenOffice Error : The user interface language cannot be determined-Linux

The error occurs because the folder where the necessary files are
not present are not having enough permissions. The solution
is pretty simple. Get into the user's home directory
# cd /home/username
Find the hidden folder which stores OpenOffice files. Its
usually ".openofficeversion" or ".oooversion".
# cd ~/.oooversion
Now execute the below command:
# sudo chown --reference=. -R .openoffice.org2
Now give necessary permissions to that folder:
# sudo chmod -R 755 .openoffice.org2
Try opening up OpenOffice. It should work just fine now.

Bulk downoading files from a webserver folder accessible via FTP


Suppose, if we need to download all files from a web folder, accessible via FTP, we can use LFTP command to do that. For example, in one website, under the "clamav" folder, I need to download all RPM files from there. So instead of downloading that one by one, I can do so by the command below:
lftp -c 'open -e "mget -d *.el5.rf.i386.rpm" http://packages.sw.be/clamav/'
This needs to be executed from a terminal. Also packages, LFTP and MGET needs to be present.
 

A Linux Admin's WeBlog! Blak Magik is Designed by productive dreams for smashing magazine Bloggerized by Ipiet The Blog Full of Games © 2008