Copy database backup from centos server to local

Source: Internet
Author: User
Tags centos server

Copy the database backup from the centos server to the local centosubuntu script to back up the database. To solve this problem, use the objective CT Script: The syntax is as follows. Be sure to set the timeout to a little longer. Otherwise, the system stops when the test is half done: #! /Usr/bin/login CT-fset password ******** set date [exec date "+ % Y % m % d"] # download local hostspawn scp-r root @ {IP address }: /home/{ps-name}/backup/db/production $ date. SQL/root/db/set timeout 3 response CT {"yes/no" {send "yes \ r"; exp_continue} response CT "root @ {IP address}'s password: "set timeout 30 send" $ password \ r "set timeout 3000 send" exit \ r "missing CT eof

Related Article

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: 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.