timesten mysql_TimesTen命令—ttBackup – 提供7*24专业数据库(Oracle,SQL Server,MySQL等)恢复和Oracle技术服务@Tel:+86 1342...

本文详细介绍了Oracle Timesten数据库的ttBackup工具的使用,包括全备、增量备份以及流备份的执行过程和注意事项。通过示例展示了如何启动增量备份功能,以及如何查看备份状态。同时,提到了在Linux/Unix环境下使用流备份结合dd命令的方法。

ttBackup使用说明

c:\>ttBackup -h

Usage:

ttBackup [-h | -help | -?]

ttBackup [-V | -version]

ttBackup -dir [-type ] [-fname ]

[-force] { | [-connstr] }

options:

-h | -help | -? Prints this message and exits.

-V | -version Prints the release number and exits.

-type The type of backup to be performed. Supported backup

types are given below. Default is "fileFull".

-dir The directory in which to store the backup files.

-fname The file prefix for the backup files in the backup

directory. Default is the base filename portion of the

DataStore parameter of the data store to be backed up.

-force Destroy existing backup files before performing backup

(full file-based backups only).

, The DSN or ODBC connection string of the data store to

be backed up.

Backup types are:

fileFull Full backup to the specified backup directory. The

resulting backup is not enabled for incremental backup.

This is the default backup type.

fileFullEnable Full backup to the specified backup directory. The

resulting backup is enabled for incremental backup.

fileIncremental Incremental backup. Augments pre-existing backup given

by '-dir' and optionally '-fname'.

fileIncrOrFull If incremental backup is possible, then behaves like

"fileIncremental"; else behaves like "fileFullEnable".

NOTE: For above types, '-dir' is required; '-fname' and '-force' are optional.

streamFull Full backup to the standard output. '-dir', '-fname' and

'-force' are ignored.

incrementalStop Does not perform a backup. Disables an incremental-enabled

backup. '-dir' is required; '-fname' is optional; '-force'

is ignored.

ttBackupStatus函数说明

344e9bdbba29d29a4b48076b438a085d.png

全备和增量备份

--全备并启动增量备份功能

c:\>ttbackup -dir E:\oracle\timesten\tt_back\full -type fileFullEnable -fname xifenfei01_ -force my_ttdb

Backup started ...

Backup complete

Command> call ttBackupStatus ();

< 2, 0, 1, 2012-02-22 23:13:18.125000, 2012-02-22 23:13:18.505000, 0, 11821056,0, 5896 >

1 row found.

--增量备份

c:\>ttbackup -dir E:\oracle\timesten\tt_back\full -type fileIncremental -fname xifenfei01_ -force my_ttdb

Backup started ...

Backup complete

Command> call ttBackupStatus ();

< 2, 0, 0, 2012-02-22 23:19:24.453000, 2012-02-22 23:19:24.702000, 0, 11825152,0, 3960 >

1 row found.

--执行结果

E:\oracle\timesten\tt_back\full>dir

驱动器 E 中的卷没有标签。

卷的序列号是 38D0-2A35

E:\oracle\timesten\tt_back\full 的目录

2012/02/22 23:19

2012/02/22 23:19

2012/02/22 23:13 21,119,936 xifenfei01_.0.bac

2012/02/22 23:19 11,943,936 xifenfei01_.0.bac0

2012/02/22 23:19 696 xifenfei01_.sta

3 个文件 33,064,568 字节

2 个目录 9,432,420,352 可用字节

--补充说明

1.需要使用fileFullEnable启动增量备份

2.增量备份需要指定dir和fname和全备时一致

fileIncrOrFull测试

c:\>ttbackup -dir E:\oracle\timesten\tt_back\full -type fileIncrOrFull -force -fname xifenfei01_ my_ttdb

Backup started ...

Backup complete

Command> call ttBackupStatus ();

< 2, 0, 0, 2012-02-22 23:47:57.997000, 2012-02-22 23:47:58.174000, 0, 11880448,0, 5740 >

1 row found.

c:\>ttbackup -dir E:\oracle\timesten\tt_back\full -type fileIncrOrFull -force -fname xifenfei00_ my_ttdb

Backup started ...

Backup complete

Command> call ttBackupStatus ();

< 2, 0, 1, 2012-02-22 23:53:37.364000, 2012-02-22 23:53:37.753000, 0, 11886592,0, 5076 >

1 row found.

--补充说明

在有启用增量备份(启用增量的全备或者增量备份本身)的基础上,会自动进行增量备份;

在无启用增量备份(没有备份或者备份没有启用增量备份)的基础上,如果无则会进行全备

streamFull测试

c:\>ttBackup -type streamFull my_ttdb>E:\oracle\timesten\tt_back\full\xifenfei.tream

Backup started ...

Backup complete

Command> call ttBackupStatus ();

< 2, 1, 1, 2012-02-22 23:38:52.480000, 2012-02-22 23:38:52.606000, 0, 11874304,0, 4384 >

1 row found.

c:\>dir E:\oracle\timesten\tt_back\full\xifenfei.*

驱动器 E 中的卷没有标签。

卷的序列号是 38D0-2A35

E:\oracle\timesten\tt_back\full 的目录

2012/02/22 23:38 33,064,596 xifenfei.tream

1 个文件 33,064,596 字节

0 个目录 9,399,287,808 可用字节

--补充说明

在linux/unix环境中,执行流备份可以结合dd命令

如:ttBackup -type streamFull FastIns | dd bs=64k of=/dev/rmt0

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符  | 博主筛选后可见
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值