|
藍森林 http://www.lslnet.com 2006年7月08日 11:08
如何實現用戶數據庫的分塊自動備份?
正常情況下dump database 語句可以備份,但要備份超過2G的數據庫時就需要分塊來備,那麼怎麼來實現分塊自動備份哪?
那位高手來指點一二!! |
如何實現用戶數據庫的分塊自動備份?
大於2G為什麼就要分塊呢?? |
如何實現用戶數據庫的分塊自動備份?
| 如何實現用戶數據庫的分塊自動備份?
兄台採用的是什麼操作系統?(linux ,aix 等),如果要採用分塊備份數據的話可以採用stripe on參數。命令格式如下:
1>; dump database ssss to ' /opt/sss1.dump' stripe on '/opt/ss2.dump'
2>;go |
如何實現用戶數據庫的分塊自動備份?
dump database ... to 'file0'
stripe on 'file1'
stripe on 'file2'
...
go
load的時候也要這樣才行! |
如何實現用戶數據庫的分塊自動備份?
Striping Dump Devices
Sybase (prior to version 12) has a 2 GB dump file size limitation for most platforms. Getting around this is easy - simply stripe the dumps across multiple files or devices. The examples below use file names instead of device names.
dump database hr_db to
'/usr2/dumps/remote/db_hr05121318.dmp'
stripe on '/usr2/dumps/remote/db_hr_S1_05121318.dmp'
stripe on '/usr2/dumps/remote/db_hr_S2_05121318.dmp'
go
load database hr_db from '/usr2/dumps/remote/db_hr05121318.dmp'
stripe on '/usr2/dumps/remote/db_hr_S1_05121318.dmp'
stripe on '/usr2/dumps/remote/db_hr_S2_05121318.dmp'
go
online database hr_db
go |
| |