I'm using a modified version of automysqlsump.sh
I don't want to have a single dump but every single table for itself, so I can write the tables back into the db per table and choose whether I want the table data or just the structure on a per table basis. This is what motivates me and it all works perfect.
I'm now on a Amazon EC server and the script doesn't work as expected. It gives me an access denied when I echo the mysql command in my script and use it on the command line it all works well, so the grants should be ok.
/usr/bin/mysql -s --skip-column-names --user=XXX --password="XXX" --host=XXX --port=3306 -D XXX -e "show tables";
But not in my shell script. Then I get
ERROR 1045 (28000): Access denied for user 'XXX'@'YYY' (using password: YES)
Note: The db server is a remote Amazon DB server