-
mysqlhotcopy
I know all the questions I've been posting lately seem to be more mysql based than PHP based but this is the best forum I have found for these kinda questions and you all have a great deal of knowledge in this area.
alright, theres a command called mysqlhotcopy that I tried using but it keeps giving me errors in my shell script. Has anybody used this command and can you show me some syntax for it. What I have is...
mysqlhotcopy dbName /this/is/where/it/should/go;
and its giving me an error
//
Bareword found where operator expected at ./backitup.pl line 15, near "/home/sit
es"
(Missing operator before tes?)
syntax error at ./backitup.pl line 15, near "/this/is"
Execution of ./backitup.pl aborted due to compilation errors.
//
-
you are using perl to connect to mysql?
-
ummm yeah, thats what it said on mysql's site about it...
http://www.mysql.com/doc/m/y/mysqlhotcopy.html
-
what does your perl code look like? is it locally?
also if you just want to make a backup of the database then use myPhpAdmin. very awesome program. it will backup your data and structure to a file called dbname.sql.
-
I have phpMyAdmin and I use it religiously. It's a very good program but I need this to be a nightly thing that doesn't need user interaction, it just goes through and does it. Does phpMyAdmin have an automated process for doing that?
//perl code
#!/usr/bin/perl
mysqlhotcopy visualwow /home/sites/home/users/admin/backupz;
exit(0);
__END__
-
but see from what I have read is that mysqlhotcopy has to be run from the shell, something like this
http://www.mysql.com/doc/B/a/Backup.html
-
hmm... you're right but the actual page that talks about mysqlhotcopy in detail...
http://www.mysql.com/doc/m/y/mysqlhotcopy.html
the first line says is a perl script. I thought that meant that you just write a .pl file and run it. Maybe I'm misunderstanding this though... if its a perl script why would it run under shell only?