In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Brief introduction:
Mysqldump is commonly used for logical backups of MySQL databases.
Backup operation:
1. Back up all libraries: mysqldump-uroot-pyourpass-- all-databases > / tmp/all.dump2. Back up a single library: mysqldump-uroot-pyourpass test > test.dump3. Backup sheet: mysqldump-uroot-pyourpass test test_tb > test_tb.sql4. Backup stored procedure: mysqldump-uroot-pyourpass-n-d-t-R test > test_procedure.sql
Restore operation:
Make sure that the database to be restored exists before recovery
Restore a single library: mysql-uroot-pyourpass test
< test.dump 或者进入数据库 执行 source test.dump; 从整库备份中恢复单张表:cat test.dump | sed -e'/./{H;$!d;}' -e 'x;/CREATE TABLE `test_tb`/!d;q' >/ tmp/test_tb.sql-- filter out the table-building statement cat test.dump | grep-- ignore-case 'insert into `test_ tb`' > / tmp/insert_test_tb.sql-- filter the insert statements that insert data
Then execute the corresponding sql in the database as needed to recover the single table.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.