Difference between revisions of "Custom Installations Backup"

From SmartHCM Wiki
Jump to navigation Jump to search
 
(4 intermediate revisions by the same user not shown)
Line 11: Line 11:
  
 
=== Export the Old Oracle Database ===
 
=== Export the Old Oracle Database ===
 +
 
To create a dump file of the database:
 
To create a dump file of the database:
  
Line 17: Line 18:
 
</pre>
 
</pre>
  
In this case the user 'system' password is 'password' and database schema name is 'smarthcmdb'.
+
In this case the user "system" password is "password", database schema name is "smarthcmdb" and oracle directory to export the database is "oracle_dump".
 +
 
 +
 
 +
=== Import the Oracle Database ===
 +
 
 +
To import the previously exported file:
 +
 
 +
<pre>
 +
impdp system/password directory=oracle_dump dumpfile=smarthcmdb.dmp remap_schema=smarthcmdb:smarthcmdbnew transform=oid:n
 +
</pre>
 +
 
 +
In this case the user "system" password is "password", database new schema name is "smarthcmdbnew" and oracle directory to export the database is "oracle_dump".
 +
 
 +
After import, change the password for newly created user for "smarthcmdbnew" by SQLPlus tool:
 +
 
 +
<pre>
 +
ALTER USER smarthcmdbnew IDENTIFIED BY password;
 +
</pre>

Latest revision as of 14:01, 30 June 2015


Introduction

This document explains the process of moving an SmartHCM installation from one machine to another. An example scenario is the migration of SmartHCM in production under Microsoft Windows to a Linux server for Database.

Files

Take the SmartHCM directory and create a compressed and portable file with it (eg. zip or tar.gz). Once we have the SmartHCM.zip, move it to the target machine. Unzip this file to the desired target directory.

Database

Export the Old Oracle Database

To create a dump file of the database:

expdp system/password directory=oracle_dump schemas=smarthcmdb dumpfile=smarthcmdb.dmp logfile=smarthcmdb.log

In this case the user "system" password is "password", database schema name is "smarthcmdb" and oracle directory to export the database is "oracle_dump".


Import the Oracle Database

To import the previously exported file:

impdp system/password directory=oracle_dump dumpfile=smarthcmdb.dmp remap_schema=smarthcmdb:smarthcmdbnew transform=oid:n

In this case the user "system" password is "password", database new schema name is "smarthcmdbnew" and oracle directory to export the database is "oracle_dump".

After import, change the password for newly created user for "smarthcmdbnew" by SQLPlus tool:

ALTER USER smarthcmdbnew IDENTIFIED BY password;