Put the script in/home/user/mysql_backup.sh
Crontab
# Crontab-l
# M h dom mon dow command
28 16 ***/home/user/mysql_backup.sh
The script is as follows:
#! /Bin/sh
# Mysql_backup.sh: backup mysql databases and keep newest 5 days backup.
#
# Last
When using MySQL, you must pay attention to security issues. The following are 23 notes for MySQL:
1. If the connection between the client and the server needs to span and pass through an untrusted network, you need to use an SSH tunnel to encrypt
I. Summary:
Now, as Web networks continue to provide enterprises with an economical way to sell their goods and services, we will still see more Web-based applications. An internal feature of Web, and the most common technical problem that
MyISAM: This is the default type. It is based on the traditional ISAM type, and ISAM is the abbreviation of Indexed Sequential Access Method (Sequential Access Method with indexes, it is a standard method for storing records and files. compared with
1. First, mysql imports the SQL file: source data. SQL
2. Changed the max_allowed_packet of mysql my. ini.
Mysql> use databasenameDatabase changedMysql> source c: mysql. SQL
If the. SQL file is too large, mysql will directly disconnect
Solution:
Normally used SQL Server Enterprise Manager suddenly encountered a problem this morning, the error is as follows:
"MMC cannot open the file C: PRogram FilesMicrosoft SQL Server80ToolsBinnSQL Server Enterprise Manager. MSC
This may be because the
A) backup: The ndb_mgm management client is used for backup.Run ndb_mgm on the Management node to enter the management command line, such!Enter start backup to back up all nodes. If the id of the corresponding data node is followed, only the
Mysql executes External SQL If there is an external SQL file named "mydb. SQL"; to create a table, assume that the database is "mydb ";1. mysql is not logged on:Java codeMysql-uroot-p1234 // Absolute path, which can be enclosed in single quotesMysql-
Demand Environment:
Function: resume search
Requirement: You can select either full-time, part-time, temporary, or intern, but only one type of resume is required. You must list all your resumes that meet any of the requirements.
Obstacle: if any
When inserting data into a table, you often encounter this situation: 1. First, determine whether the data exists; 2. If the data does not exist, insert the data; 3. If the data exists, update the data.
In SQL Server, you can perform the following
The tablespace is not backed up and deleted. Logs need to be restored, but logs cannot have breakpoints.Check whether logs are in archive Mode Under sys userSQL> archive log listIf you are in non-archive mode, you need to change the sys user to
Enter show variables like "character %" in the mysql console. The running result is shown in:
Setting the 12356 rows of value to GBK or UTF-8 can solve this problem.1. First, check rows 1, 2, and 5.Execute "set names gbk" or "set name utf8" in
Case:Id name Course name score1 Zhang San math 692 Li Si math 893 Zhang San, mathematics 69Delete redundant student information that is identical except for automatic numbers
Bytes ---------------------------------------------------------------------
Solution: 1. uninstall MySQL. 2. type regedit in "run" to enter the registry. 3. Delete the HEKY_LOCAL_MACHINE \ SOFTWARE \ MYSQL directory. 4. Delete the HKEY_LOCAL_MACHINE \ SYSTEM \ ControlSet001 \ Services \ Eventlog \ Application \ MySQL
MySQL Backup ToolBacking up a MySQL database is a basic task of database management. Although you can directly back up a database using mysqldump, you still need to do a lot of work to achieve automatic backup. MySQL Backup Tool provides us with
I. There are three ways to view the mysql table structure:1. desc tablename;2. show create table tablename;3. use information_schema; select * from columns where table_name = 'tablename ';The second method is the best if you want to view how to
The master-Slave synchronization of mysql fails. the following error is reported in the log: 120309 18:39:23 [Note] Slave SQL thread initialized, starting replication in log 'mysql-bin.000004 'at position 2207467, relay log '. /mysqld-relay-bin.00001
View the data table information. If you execute an SQL statement directly to the table, it may be slow when the table is large or other clients are operating on the table. For example, to view the number of records in the table, use: [SQL] SELECT
Java code1. Create a management user for the mysqld Database: to set the root user as the administrator, run the following command;[Root @ linuxsir01 root] # mysqladmin-u root password 123456Generally, the directory where mysqladmin is located has
1. Create a single INDEX for the TABLE. alter table table_name add index indexName (colname );Create multiple-column index alter table table_name add index indexName1_indexName2 (colname1, colname2 );This method of joint creation of multiple columns
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.