喜悦国际村 » 数据库技术 » 请教一个数据库备份的问题

页: [1]
wleige2007-8-9 05:56 AM
请教一个数据库备份的问题

mysql数据库,如果一个数据库在有50个表,想备份其中的49个,另一个数据量比较大,而且没有必要备份。
有什么好的办法解这样的问题

[[i] 本帖最后由 wleige 于 2007-8-9 01:59 PM 编辑 [/i]]

wamper2007-8-9 07:49 AM
mysqldump -uroot -p dbname --tables table1 table2 ......table49 > dbbak.sql

wleige2007-8-9 09:06 AM
这个方法想过了,不过有点笨,有没有其它的,刚才我查了一下,好象可以用 ----ignore-table

把不备份的那个表忽略掉
--ignore-table=name Do not dump the specified table. To specify more than one
                      table to ignore, use the directive multiple times, once
                      for each table. Each table must be specified with both
                      database and table names, e.g.
                      --ignore-table=database.table


查看完整版本: 请教一个数据库备份的问题


Powered by Discuz! Archiver 6.1.0  © 2001-2006 Comsenz Inc.
Processed in 0.005788 second(s), 2 queries