MySQL

Throttle a MySQLDump export so it doesn't lock up your production server

Trying to get your MySQLDump to relax a little bit?

If you are running InnoDB, consider running your mysqldump command with the following options:

--single-transaction --quick

This will slow the execution enough that your production site should still stay somewhat performant and not just hijack the server until it completes.

There are associated concerns, of course, but this should get many users through a MySQL dump on a live site.

So, for those of you looking for a complete MySQLDump command example using these switches, try:

Tags: 

How to add MySQL to the path in the command line with MAMP on Mac

Snap another chunk on your path!

You have MAMP on Mac and you are trying to type "mysql" but it is not finding it.

1. Change to your user home directory with "cd ~"

2. Edit ".bash_profile" using the editor of your choice. (You won't see it if you list the directory contents - try "ls -a" if you want to see files normally hidden by the ls command)

3. Add the following line, which is the directory where the MySQL executable resides:

export PATH=$PATH:/Applications/MAMP/Library/bin

...that will attach the executable directory to your existing path and allow you to type "mysql" from anywhere.

Tags: 

How to easily move databases from staging to production environments

HeidiSQL allows you to copy entire schemas DIRECTLY ACROSS database servers!

Often times people are faced with the cumbersome task of moving an entire database from one environment to another, usually by creating a dump file of the database, moving it across from one database server to another, and re-running the script on the destination. This is irritating in that it requires one to create a file that is immediately disposed of, and to transfer that file one or two times over the wire. It is also prone to error in that it entails many distinct steps that each have their own glitches or mistakes to make. The good news is that the easy, one-step solution exists in a product you just haven't tried yet.

Tags: 

Subscribe to RSS - MySQL