ContentServer迁移的步骤

1.备份还原数据库,有时候用UI操作不成功的时候可以用命令行如:restore database QA1 from disk = 'd:\qa1' with replace. 数据块恢复完之后有两个表还得需要修改一下,分别是dm_acs_config(?) dm_server_config(?),具体表名我也不是记得很准,不过你打开数据库管理器很容易找到的。打开两个表后,把几个url和uri的字段修改一下,主要是机器名或者ip.

2.将C:\Documentum\data\qa1拷贝过来

3.如果启动Repository报错,如Docbase QA1 was not successfully opened. Docbase id: (10001)"

这一般是由于两个机器的加密文件(aek.key)不一致引起的,此时有两种解决方法:

如果你只有一个repository,那么就简单的将原来机器的C:\Documentum\dba\secure\aek.key还有C:\Documentum\dba\config\QA1\dbpasswd.txt拷贝到新机器就行了。

如果有多个repository的话,上边操作会使其他repository不能启动,这时候只需要使用当前机器的aek.key重新生成dbpasswd.txt就好了,具体执行的命令 是:
cd C:\Documentum\product\6.5\bin

dm_encrypt_password.exe -docbase QA1 -rdbms -encrypt 执行后会提示让你输入新密码,此时输入据库密码就O了。

今天在contentserver6.5sp2上又成功做了一次,

Shutdown all the docbase on the target server

Rename or move aek.key file (located at $DOCUMENTUM\dba\secure)

扫描二维码关注公众号,回复: 389500 查看本文章

UPDATE dm_docbase_config_s SET i_crypto_key = ' ';
UPDATE dm_docbase_config_s SET i_ticket_crypto_key = ' ' ;
DELETE FROM dmi_object_type WHERE r_object_id = (SELECT r_object_id FROM dmi_vstamp_s WHERE i_application = 'dm_docbase_config_crypto_key_init');
DELETE FROM dmi_vstamp_s WHERE r_object_id = (SELECT r_object_id FROM dmi_vstamp_s WHERE i_application = 'dm_docbase_config_crypto_key_init');
DELETE FROM dmi_object_type WHERE r_object_id = (SELECT r_object_id FROM dmi_vstamp_s WHERE i_application = 'dm_docbase_config_ticket_crypto_key_init')DELETE FROM dmi_vstamp_s WHERE r_object_id = (SELECT r_object_id FROM dmi_vstamp_s WHERE i_application = 'dm_docbase_config_ticket_crypto_key_init') ;
DELETE FROM dmi_vstamp_s WHERE r_object_id = (SELECT r_object_id FROM dmi_vstamp_s WHERE i_application = 'dm_docbase_config_ticket_crypto_key_init') ;
DELETE FROM dm_sysobject_s WHERE r_object_id= (SELECT r_object_id FROM dm_public_key_certificate_s WHERE key_type=1);
DELETE FROM dm_sysobject_s WHERE r_object_id= (SELECT r_object_id FROM dm_cryptographic_key_s WHERE key_type=1);
delete dm_public_key_certificate_s;
delete dm_cryptographic_key_s;

Run $DM_HOME/bin/dm_crypto_create
Run $DM_HOME/bin/dm_encrypt_password -docbase -rdbms -encrypt -docbase
Try to start your docbases.

其他的情况可参考下文:

1. Stop the docbase.

2. Backup the database
3. Rename the AEK file or move it some where else

4. From sql on the database,
SQL> update dm_docbase_config_s set i_crypto_key = ' '.
SQL> update dm_docbase_config_s set i_ticket_crypto_key = ''

5. Retrieve entry from dmi_vstamp_s for 'dm_docbase_config_crypto_key_init'.
SQL> select r_object_id from dmi_vstamp_s where i_application =
'dm_docbase_config_crypto_key_init';

6. Delete entry from dmi_object_type
SQL> delete dmi_object_type where r_object_id = 'returned r_object_id from above';

7. Delete entry from dmi_vstamp_s itself
SQL> delete from dmi_vstamp_s where r_object_id = 'returned r_object_id from step above'

8. Retrieve entry from dmi_vstamp_s for 'dm_docbase_config_ticket_crypto_key_init'.
SQL> select r_object_id from dmi_vstamp_s where i_application = 'dm_docbase_config_ticket_crypto_key_init';

9. Delete entry from dmi_object_type
SQL> delete dmi_object_type where r_object_id = 'returned r_object_id from above';

10. Delete entry from dmi_vstamp_s itself
SQL> delete from dmi_vstamp_s where r_object_id = 'returned r_object_id from step above';

11. Truncate the tables dm_public_key_certificate_s
SQL> delete dm_public_key_certificate_s;

12. Truncate the tables dm_cryptographic_key_s
SQL> delete dm_cryptographic_key_s;

13. Run dm_crypto_create utility under $DM_HOME/bin, in order to create a new aek.key file. Even though you have multiple docbases in a machine, you should run this only one time.

14. Run dm_encrypt_password utility to encrypt the database access password.
Prompt> dm_encrypt_password -docbase <docbase name> -rdbms -encrypt <database password>



15. Check if views_valid is set to 0,
Sql>select views_valid from dm_type_s;

If its 1, then run the following command
Sql>UPDATE dm_type_s SET views_valid = 0;

16. Startup the docbases. The attributes deleted above are repopulated inside database, when Docbase starts.<!-- / message -->

In addition, if after/before/during the process you got this error also :

[DM_CONTENT_E_GDCDS_NO_ACS_CRYPTO_KEY]error: "Cannot get the ACS Cryptographic key for Distributed Content. This is expected during docbase creation and the ACS Cryptographic system will be initialized by each session as needed. This error is unexpected once docbase creation is complete. Status = 524"

Just clean these tables: dm_public_key_certificate_s and dm_cryptographic_key_s

Probally you will receive the following error also "Unable to open file for input" (when you try to start the docbase with Server Manager)

二。另外一种备份还原的方法 使用IApi

http://www.bluefishgroup.com/library/2003/dump-and-load-a-docbase/

猜你喜欢

转载自l007it.iteye.com/blog/1469243
今日推荐