Im having trouble making this bash script work. If anyone can help me I would really appreciate it
Im on a Godaddy.com shared hosting Apache server running Linux.
I came up with this script after searching around the web:
(the sensible data has been masked)
The bash file is located at _db_backups/
mysqldump -h host -u myuser -pPassword databasename > _db_backups/dbbackup.sql
mv dbbackup.sql.gz _db_backups/`date +mysql-BACKUP.sql-%y-%m-%d.gz`
so I configured a cron job to execute this script. And the resulting log is emailed to me and says:
/var/chroot/home/content/01/3196601/html/_db_backups/backup.sh: line 1: ��!/bin/bash: No such file or directory
/var/chroot/home/content/01/3196601/html/_db_backups/backup.sh: line 2: _db_backups/dbbackup.sql: No such file or directory
gzip: _db_backups/dbbackup.sql: No such file or directory
mv: cannot stat `dbbackup.sql.gz': No such file or directory
So as you can see... everything is "No such file or directory"... Any ideas?