onbar的日誌搶救備份

tonykorn97發表於2007-03-14

如果我們的資料庫那天日誌沒有備份完,而此時資料庫突然宕掉後不能啟動,那麼我們的這幾個日誌就沒有備份。如果此時恢復的話是有幾個日誌不能恢復的,為了不讓我們的資料丟失,我們就需要把沒有備份的日誌備份到磁帶上。

用onbar -b -l -s起用搶救模式,在資料庫停止的狀態下可以備份日誌。

這個也是出了問題在領導那裡學習的,以前沒有用過。呵呵。



[informix@test ~]$ onbar
/home/informix/bin/onbar_d
onbar usage

BACKUP & VERIFICATION
=====================
For IBM Informix Dynamic Server:
-b [-L ] [-w | -f | ] [-O]
-b -F
-b -l [-c | -C | -s] [-O]
-v [-w] [-p] [-t

-b backup
-c backup current logical log
-C continuous logical log backup
-f pathname of file containing list of storage spaces
-F fake backup
-l backup full logical logs (no spaces)
-L backup level: 0, 1, or 2, defaults to 0
-O override internal error checks - enforce policy strictly
-p backup spaces only (no logs)
-w whole system backup
-s salvage logs
-v verify consistency of most recent backups
list of storage spaces to backup
onbar usage

RESTORE
========
For IBM Informix Dynamic Server:
-r [-e] [-O] [-f | ]
-r [-e] [-t

-e external restore
-f pathname of file containing list of storage spaces
-l logical log only restore (no spaces)
-n last logical log to restore
-O override internal error checks - enforce policy strictly
-p physical only restore (no logs)
-r restore
-t point in time to stop restore
-w whole system to restore
-RESTART restart an interrupted restore
list of storage spaces to restore
-rename rename chunks during cold restore
With -rename option:
-rename -f pathname of file containing list of mapped
chunk pathnames and offsets
-p old pathname of chunk
-o old offset of chunk
-n new pathname of chunk
-o new offset of chunk
onbar usage

MESSAGING
=========
For IBM Informix Dynamic Server:

-m [] [-r []]

-m Displays last of onbar's activity log file (default: 20 lines)
-r Repeat display every seconds (default: 5 seconds)

onbar usage

LOGICAL-LOG(S) DISPLAY
======================
For IBM Informix Dynamic Server:
{-P} {-n | ending log unique identifier>} [-l] [-q] [-b] [-u ]
[-t ] [-x

-P Print backed up logical-log(s) information
-n Display the specified log identifier(s)
-l Display maximum information about each log record
-q Do not display program header
-b Display information about logged BLOB pages
-u Display the specified user(s)
-t Display the specified TBLspace(s)
-x Display the specified transaction(s)
[informix@test ~]$

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/312079/viewspace-245622/,如需轉載,請註明出處,否則將追究法律責任。

相關文章