July 2013
M T W T F S S
1234567
891011121314
15161718192021
22232425262728
293031  

Categories

July 2013
M T W T F S S
1234567
891011121314
15161718192021
22232425262728
293031  

Mysqladmin Tips

Here we can see some tips with mysqladmin tool To check the status of mysqld # mysqladmin -u root -pmysql ping # service mysqld status # mysqladmin -u root -pmysql status

 

To find mysql version # mysqladmin -u root -pmysql version

 

To view all the MySQL Server status variable and it s current […]

Mysql grant

 

Some mysql grant queries Granting permission for a particular DB only mysql> grant all privileges on databasename.* to ‘username’@’localhost’; mysql> flush privileges;

 

Granting Permission for all the DB mysql> grant all privileges on *.* to ‘username’@’localhost’;

 

Granting Permission from a particular IP # grant all privileges on *.* to ‘username’@’192.168.0.20’;

 

# […]

How to Repair a Mysql Table

Repairing corrupted mysql tables using myisamchk / mysqlcheck / repair 1. myisamchk myisam is the default storage engine for mysql database. There is a chance of myisam tables gets corrupted easily. myisamchk helps to identify and fix corrupted tables in myisam. when table created in mysql it will create different files under mysql some of […]

How to install Mysql with partition enabled

We can check how can we able to setting up mysql server with partition enabled. Lets see what is mysql partition means.

 

A partition is a division of a logical database or its constituting elements into distinct independent parts. Database partitioning is normally done for manageability, performance or availability reasons.

 

A popular and […]

Mysql Performance Tuning

MySQL Performance tuning [my.cnf file parameters + description] [mysqld]# Maximum allowed number of connections to the MySQL Server max_connections = 1500

# The key buffer is a variable that is shared amongst all MySQL clients on the server. A large setting is recomended, particularly helpful with tables that have unique keys. key_buffer = 1024M

#The […]

Monitor Mysql DB in linux

We can monitor mysql queries and database using an utility called MonYog. MONyog is a monitoring and advisory tool for MySQL Community as well as Enterprise versions.MONyog is agent-less, and does not require anything to be installed on the MySQL servers. MONyog helps monitor enterprise database environments.

 

MONyog MySQL Monitor and Advisor MySQL DBAs […]

InnoDB vs MyISAM

MyISAM and InnoDB are the two most-common database engines available. While installing the DB most of them don’t even take the time to select a storage-engine and just accept the database default. The storage-engine is what which store, handle, and retrieve information for a particular table. 1. MyISAM It is the default engine with MySQL. […]

mysqlhotcopy vs mysqldump

mysqlhotcopy vs mysqldump mysqlhotcopy is a Perl script that was originally written and contributed by Tim Bunce. It uses LOCK TABLES, FLUSH TABLES, and cp or scp to make a database backup quickly. It is the fastest way to make a backup of the database or single tables, but it can be run only on […]

Mysql Master Slave Replication

Setting the Replication Master Configuration

On a replication master, you must enable binary logging and establish a unique server ID.

Binary logging must be enabled on the master because the binary log is the basis for sending data changes from the master to its slaves.

If binary logging is not enabled, replication will not be […]

Mysqlslap for mysql load testing

Mysqlslap is a Load Emulation Client. mysqlslap is a diagnostic program designed to emulate client load for a MySQL server and to report the timing of each stage. It works as if multiple clients are accessing the server. mysqlslap is available as of MySQL 5.1.4.

mysqlslap runs in three stages:

1. Create schema, table, and […]