Linux commands used in peacetime

Source: Internet
Author: User

Backup database: Mysqldump–uroot (root username)-p123 (123 password) phpbb_db_backup (select backed up database) >/usr/backups/mysql/db_ Backup2008-1-6.sql (backup path and generated file name);

Tip:-u-p is a format;

Restore Database: mysql–uroot-p123 db_backup (database name) </usr/backups/mysql/db_backup2008-1-6.sql (backup file)

Restore the database in the MySQL command: First enter the database source/tmp/db_name.sql (SQL file path) to be imported;

Create folder: mkdir Lemon (folder name);

Remote Copy folder and file: scp-r [email protected] (' Remote server IP '):/(remote file root) test.sql (remote folder or file)./pub/(the path of the current server);

Linux commands used in peacetime

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.