mysqldump error – view lack rights to use them (1356)

If you get an error messages like “mysqldump: Couldn’t execute ‘SHOW FIELDS FROM `some_database`’: View ‘some_database.viewname’ references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them (1356)” you can work around this by trying the dump as “root” or telling mysqldump to ignore the broken view by adding this … [Read more…]

Passwordless SSH

There are many times where it would be preferable to authenticate to a server without having to enter a password. Basically any time you want to transfer things between servers with scripts you’ll need to be able to authenticate as a valid user. The best way to do this is with SSH keypairs. In this … [Read more…]

Advanced Bash Scripting

This is really more of a tip, if you’re in any way serious about doing and scripting in BASH then you really need the Advanced Bash Scripting guide from the Linux Documentation Project.  This is my “go to” guide whenever I need to check syntax of commands, tests, loops, etc.  The PDF is always living … [Read more…]

MySQL Backup

This is a simple script that can be used to take backups of your MySQL databases, it can be run as a cron job and outputs enough of a log to allow you to keep track of what’s going on. There’s a few sections you’ll need to edit and an extra stage that uses rsync … [Read more…]