我是在esxi 环境的虚拟机上,我还原机器重装过多次依然无法导入数据进去。以下是操作步骤。[root@localhost ~]# mkdir /home/db2backup[root@localhost ~]# mv QYDB.0.db2inst1.DBPART000.20150121010008.001 /home/db2backup/[root@localhost ~]# chown -R db2inst1:db2i...
显示全部我是在esxi 环境的虚拟机上,我还原机器重装过多次依然无法导入数据进去。以下是操作步骤。
[root@localhost ~]# mkdir /home/db2backup
[root@localhost ~]# mv QYDB.0.db2inst1.DBPART000.20150121010008.001 /home/db2backup/
[root@localhost ~]# chown -R db2inst1:db2iadm1 /home/db2backup/
[root@localhost ~]# chmod 755 /home/db2backup/
[db2inst1@localhost ~]$ db2 restore db qydb from /home/db2backup/
SQL2523W Warning! Restoring to an existing database that is different from
the database on the backup image, but have matching names. The target database
will be overwritten by the backup version. The Roll-forward recovery logs
associated with the target database will be deleted.
Do you want to continue ? (y/n) y
SQL1051N The path "/db2data/qydb/data" does not exist or is not valid.
SQLSTATE=57019
---------------------------------------------------------------------------------------------------------
[db2inst1@localhost ~]$
[db2inst1@localhost ~]$ db2 restore database qydb from /home/db2backup/QYDB.0.db2inst1.DBPART000.20150121010008.001
SQL2036N The path for the file, named pipe, or device
"/home/db2backup/QYDB.0.db2inst1.DBPART000.20150121010008.001" is not valid.
[db2inst1@localhost ~]$
----------------------------------------------------------------------------------------------
[db2inst1@localhost ~]$ db2 restore db qydb from /home/db2backup/QYDB.0.db2inst1.DBPART000.20150121010008.001
SQL2036N The path for the file, named pipe, or device
"/home/db2backup/QYDB.0.db2inst1.DBPART000.20150121010008.001" is not valid.
收起