Forum: Ruby on Rails Ruby and MySQL backup

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
9ae68be4f6aff5c6aa7a0eb7087251e9?d=identicon&s=25 PeteSalty (Guest)
on 2008-10-14 19:56
(Received via mailing list)
I suspect this is not exactly a Ruby/Rails topic but I also suspect
that lots of people here have already solved this issue. We have a
simple app running on a SliceHost slice and we'd like to backup the
database both hourly and daily to an AWS S3 account.
I've looked around but surprisingly can't seem to find anything that
offers a complete solution for doing this. I was hoping to find a ruby
solution but so far nothing. I suspect that it's not a super hard
thing to do but it's not really my specialty so I was hoping someone
here might simply point me in the right direction - perhaps a blog
post or something similar.

 Dale
Bec38d63650c8912b6ba9b557fb953b9?d=identicon&s=25 Roger Pack (rogerdpack)
on 2008-10-15 07:51
PeteSalty wrote:
> I suspect this is not exactly a Ruby/Rails topic but I also suspect
> that lots of people here have already solved this issue. We have a
> simple app running on a SliceHost slice and we'd like to backup the
> database both hourly and daily to an AWS S3 account.
> I've looked around but surprisingly can't seem to find anything that
> offers a complete solution for doing this. I was hoping to find a ruby
> solution but so far nothing. I suspect that it's not a super hard
> thing to do but it's not really my specialty so I was hoping someone
> here might simply point me in the right direction - perhaps a blog
> post or something similar.
>
>  Dale

You could setup a cron job to do it as you mentioned [mysqldump].  You
could try a mysql table syncer
http://code.google.com/p/ruby-roger-useful-functio...
Cheers.
-=r
5ca17be18ed84b27dc0d9062216e2da8?d=identicon&s=25 Christian Johansen (chrisjoha)
on 2008-10-15 11:18
I always use automysqlbackup
(http://sourceforge.net/projects/automysqlbackup/). It's not ruby, but
it's damn fine for backing up MySQL especially if you need to backup
several databases on the same server.
00973881979aa0a660ffbbb2f7a907fb?d=identicon&s=25 Peter De Berdt (Guest)
on 2008-10-16 10:00
(Received via mailing list)
On 15 Oct 2008, at 11:18, Christian Johansen wrote:

> I always use automysqlbackup
> (http://sourceforge.net/projects/automysqlbackup/). It's not ruby, but
> it's damn fine for backing up MySQL especially if you need to backup
> several databases on the same server.

I use my own bash Shell script. It commits all the database dumps to a
git repository and then pushes it to a central repository (but the
script could just as easily be modified to use svn or mercurial
or ...). That way you have versioned backups both on the local machine
as on a remote host (or hosts even) going back as far as you want.
Then just let a cron take care of executing the script as frequently
as you want.

http://pastie.org/293699


Best regards

Peter De Berdt
F745d7fbe0dbe947aa1082aabb2b6a4f?d=identicon&s=25 Save The Vinyls (Guest)
on 2008-11-14 13:53
(Received via mailing list)
Thanks a lot Peter!
This topic is locked and can not be replied to.