Yes it is.
This is why I suggest dumping db per db.
De : Ananda Kumar [mailto:anandkl@stripped]
Envoyé : lundi 28 mai 2007 10:41
À : Geoffroy Cogniaux
Cc : John Meyer; MySQL General
Objet : Re: restore one database.
Very true, restore depends on the kind of backup we do. I was just wondering
if mysql has any option to restore just one database from the mysqldump
having all the database.
So, as of now mysql does not provided option to just restore just one
database from dump having all database..Right?
On 5/28/07, Geoffroy Cogniaux <geoffroy.cogniaux@stripped> wrote:
> Hi Ananda,
> Recovery strategy depends essentially of the backup strategy you choose. I
> think that if you want be able to proceed to a restoration, database per
> database, you should separate their backups. It can simply be done with
> kind of script:
> for db in (`echo 'show databases;' | mysql -u <user> --password=<pwd> |
> -v ^Database$`); do mysqldump -u <user> --password=<pwd> $db
> >/mybackupdir/$db.bak ; done;
> If you want to have all in one file, use tar after your backup:
> cd /mybackupdir && tar -czf mybackup.tar.gz *.bak && rm -fr *.bak
> Best regards,
> -----Message d'origine-----
> De: Ananda Kumar [mailto:anandkl@stripped]
> Envoyé: dimanche 27 mai 2007 13:52
> À: John Meyer
> Cc: MySQL General
> Objet: Re: restore one database.
> Hi All,
> I think my question was not understood.
> All the database are important. Now that one of the database is accidently
> dropped, can i restore from that single database from my dump and use the
> bin log and recover till "AS OF NOW".
> On 5/27/07, John Meyer <john.l.meyer@stripped> wrote:
> > Ananda Kumar wrote:
> > > Hi Pelle,
> > > I dont have enough space on any other storage, so i was thinking if we
> > > would
> > > just restore one database from dump that would save lot of time ,
> > rather
> > > than restoring all the database.
> > >
> > > regards
> > > anandkl
> > >
> > >>
> > Well, if only one database is important enough to back up, then yes it
> > will. But if you have multiple databases that you are actively using
> > then you'll need to back them all up. You don't necessarily need to use
> > an all databases dump, though.
> > --
> > The NCP Revue -- http://www.ncprevue.com/blog
> > --
> > MySQL General Mailing List
> > For list archives: http://lists.mysql.com/mysql
> > To unsubscribe: http://lists.mysql.com/mysql?unsub=1