New juju-mongodb package
Kapil Thangavelu
kapil.thangavelu at canonical.com
Mon Dec 2 16:51:47 UTC 2013
Isn't what mongo and mongo export are doing trivially avail to a client API
script for juju backup purposes.
On Monday, December 2, 2013, roger peppe wrote:
> On 2 December 2013 12:48, John Arbash Meinel <john at arbash-meinel.com<javascript:;>>
> wrote:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > On 2013-12-02 16:39, roger peppe wrote:
> >> On 2 December 2013 11:40, Ian Booth <ian.booth at canonical.com<javascript:;>
> >
> >> wrote:
> >>> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
> >>>
> >>>>
> >>>> I don't fully understand the difference from mongoexport vs
> >>>> mongodump (it looks like dump generates a binary snapshot
> >>>> compatible with restore, while export/import generate text
> >>>> representations of the data.)
> >>>>
> >>>> I'd *really* like us to stick with *one* of them as the
> >>>> recommended method for backing up the content.
> >>>>
> >>>
> >>> Both export and dump are used by the Juju backup tool. dump is
> >>> used to do a full bson export of the database and is required for
> >>> a database recovery. export is used to write to json the
> >>> environment settings document so that there is a human readable
> >>> copy of the full environment settings contained in the backup
> >>> tarball.
> >>
> >> ISTM that the mongo command could be used to similar effect, as
> >> John suggests, couldn't it? Then we would not need mongexport at
> >> all.
> >>
> >
> > For what we are using this page:
> >
> >
> http://stackoverflow.com/questions/11255630/how-to-export-all-collection-in-mongodb
> >
> > has something like:
> > mongo --eval 'printjson(db.getCollectionNames())'
> >
> > We can easily change the internal one to something like
> > db.find('session') or whatever it needs to be.
> >
> > Now, we wouldn't need 'mongo' otherwise, but I think if we have to
> > pick a tool 'mongo' is more generally useful, and it doesn't bundle v8
> > so it is a smaller binary as well.
>
> We will probably use the mongo command for restoring,
> and may use it for backing up if that's a convenient way
> to use fsyncLock to avoid taking down the whole
> system for backing up.
>
> And it's potentially useful for escaping awkward situations
> too, so I'm definitely in favour of its inclusion.
>
> Which brings us to {mongod, mongo, mongodump, mongorestore}
> as the set of executables that we'd like to have, I think.
>
> cheers,
> rog.
>
> --
> Juju-dev mailing list
> Juju-dev at lists.ubuntu.com <javascript:;>
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/juju-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju-dev/attachments/20131202/8c930402/attachment.html>
More information about the Juju-dev
mailing list