Shell scripts for automatic monitoring of master-slave MySQL synchronization

The code is as follows: #!/bin/bash #check Mysql_slave Status #crontab Time 00:10 Mysqlport= ' Netstat-na|grep "LISTEN" |grep "3306" |awk-f[: ""]+ ' {print $4} ' mysqlip= ' ifconfig eth0|grep "inet addr" | awk-f[: ""]+ ' {print $4} '

How to optimize MySQL tens fast paging

See example:data table collect (ID, title, info, VType) on these 4 fields, where title is fixed length, info with text, ID is gradual, VType is Tinyint,vtype is index. This is a simple model of a basic news system. Now fill in the data, fill in 100,0

MySQL server master-slave configuration

Recently studied MySQL database master-slave configuration, here to record the learning process to prevent forgetting. Don't say much nonsense.The advantages of the MySQL database master-slave configuration: This allows for read-write separation, or

Installing the Binary mysql-5.7 database

Download and decompress MySQL databasewget http://mirrors.sohu.com/mysql/MySQL-5.7/mysql-5.7.4-m14-linux-glibc2.5-x86_64.tar.gzTAR-XVF mysql-5.7.4-m14-linux-glibc2.5-x86_64.tar.gz-c/usr/local/mysql-5.7.4 2. Create MySQL users and modify the

MySQL Backup and Recovery

Backup of the database can prevent the loss of data caused by unexpected situations such as server downtime, disk corruption, RAID card corruption, and so on.Backup tool for MySQL:MysqldumpIbbackupReplicationLVM Snapshotor third-party tools

installation problems with MySQL

MySQL Installation issuesproblem description : Reload MySQL encountered a problem, to the last step, configure the four items at the time of the card in the third step, the display program is not responding.Environment :Os:win7 x64Installation

MySQL modifies the character set of tables, fields, libraries

To modify the database character set: ALTER DATABASE db_name DEFAULT CHARACTER SET character_name [COLLATE ...]; Change the default character set of the table and all character columns (Char,varchar,text) to the new

MySQL both configuration experiment steps

Lab Environment:Two MARIADB servers, IP: 172.16.2.16 and 172.16.2.17The version of MARIADB is 5.5.36, which is installed using binary mode. The installation is complete./mydata/data Database File storage directory/mydata/binlog/binary log file

Two MySQL universal binary installation in lamp environment

First create a MySQL database storage directory, it is recommended to create an LVM volume to hold the database filesMkdir/mysqldata/dataAdd MySQL UserGroupadd-r MySQLUseradd-g mysql-r-s/sbin/nologin-m-d/mysqldata/data MySQLModify the owner and host

MySQL New installation service failed to start

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/49/A3/wKiom1QXp_3hIn6rAAD0TM9aJ20871.jpg "title=" 5.jpg " alt= "Wkiom1qxp_3hin6raad0tm9aj20871.jpg"/>#备注If the newly installed MySQL boot error, please check the value of the

MySQL Regular Backup script

#!/bin/bash  #This  is a ShellScript. For Auto DB Backup  #Powered  by [email protected]  #2014/2/25#setting  #设置数据库名, database login, password, backup path, log path, data file location, and backup method # By default, the backup method is tar, or

MySQL cursors (cursor) simple application

A MySQL stored procedure can not define a dynamic cursor, but you can use variables. Open, Fetch...into and close. 1. Declare a cursor: --Define useriddeclare userId nvarchar () default 0;--define Cursordeclare mycur CURSOR for select id from user; -

centos6.5 installing MySQL

Check to see if the system has the MySQL-to-use command:Rpm-qa | grep MySQLTo uninstall an installed mysql--> use command:#rpm-E--nodeps mysql-libs-*Delete all files under the/var/lib/mysql folder MySQL Installation:Execute command: Install

MySQL function note

Mainly by the following links to see, after a supplement to fill the http://blog.csdn.net/phiberg/article/details/7672974http://www.cnblogs.com/zeroone/archive/  2010/05/05/1727659.html/* Get current time */select now ();/* 2014-09-04 10:25:15 */*

Basic functions in MySQL

Time Function Select Curdate (); Returns 2014-09-12, not including time division secondsselect Curtime ();Return 14:13:22, not including dateSelect Now (); return 2014-09-12 10:46:17Select Unix_timestamp (now ()); Unix_timestamp (date)returns the

Mysql tutorial-slow connection to local MySQL in Windows 7/8

Mysql tutorial-slow connection to local MySQL in Windows 7/8 Recently, some programs such as phpcms had encountered this problem during local website debugging, and the speed was very slow. The following article occasionally reminded me of the

MySQL function learning Note 1: mathematical functions

MySQL function learning Note 1: mathematical functions 1. ABS (x): returns the absolute value of x. Mysql> select ABS (1), ABS (-1), ABS (0 );+ -------- + --------- + -------- +| ABS (1) | ABS (-1) | ABS (0) |+ -------- + --------- + -------- +| 1 |

Mysql database version control dbv usage

Mysql database version control dbv usage Version Control software includes svn git and so on. These tools control the source code version very well, but what about database version control? The traditional method is to export the entire database, so

Retrieve the deleted data table from mysql

Retrieve the deleted data table from mysql D: \ wamp \ bin \ mysql \ mysql5.6.17 \ bin> mysqlbinlog.exe d:/mysql/data/mysql-bin.000068> d: \ d68.sqlD: \ wamp \ bin \ mysql \ mysql5.6.17 \ bin> mysqlbinlog.exe d:/mysql/data/mysql-bin.000069> d: \ d69

MySQL cold backup solution for important businesses and mysql cold backup solution

MySQL cold backup solution for important businesses and mysql cold backup solution1. Overview In the company's business, when the corresponding business data is not very important, we generally write a script to pull the full database data every

Total Pages: 3233 1 .... 2714 2715 2716 2717 2718 .... 3233 Go to: GO

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.