Archive by category MySQL

Mysql Add User Privileges

Mysql Add User Privileges

This is a quick MySQL snippet that allows me to add user privileges to a MySQL database. The script will create a user first, then it will grant various privileges to that user. CREATE USER 'sqluser'@'%' IDENTIFIED BY 'sqlpassword'; GRANT USAGE ON *.* TO 'sqluser'@'%' IDENTIFIED BY 'sqlpassword' WITH MAX_QUERIES_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_CONNECTIONS_PER_HOUR 0 […]

Read More

mysqldump mysql 5.6 problem solved

mysqldump mysql 5.6 problem solved

If you have recently upgraded your MySQL version to 5.6, your mysqldump command will probably throw the following error: mysqldump: Couldn't execute 'SET OPTION SQL_QUOTE_SHOW_CREATE=1': You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'OPTION SQL_QUOTE_SHOW_CREATE=1' at line 1 […]

Read More

Mysql-bin files too large – solved

Mysql-bin files too large – solved

Newrelic?is an application monitoring tool that truly is developer’s best friend. It’s such a true statement. ?I’ve used Newrelic to pinpoint and successfully troubleshoot numerous applications. ?I’ve recently switched all database tables from MyISAM to InnoDB for a couple of reasons that are outside the scope of this post. What came to my intention is […]

Read More

MySQL startup script on Mac OS X Snow Leopard

I’ve had problems starting up MySQL database server on startup on Snow Leopard. ?MySQL preference pane seems to be flaky and it often fails to start MySQL server. I created this startup script myself and it seems to work nicely. sudo nano /System/Library/LaunchDaemons/org.mysql.mysqld.plist <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> […]

Read More

Snow Leopard Gotchas

I recently upgraded to Snow Leopard from 10.5 and everything went relatively smoothly. I was particularly pleased to see extra 13GB of hard drive space. However, I noticed a couple of things that I wasn’t so pleased about: Apache unable to start PHP disabled MySQL unable to start I’ve already walked a couple of people […]

Read More