[ovs-dev] [db-backup 5/5] Avoid unneeded database compaction at startup, and improve backups.

Ethan Jackson ethan at nicira.com
Tue Feb 15 20:22:16 UTC 2011


Ohh oops, now that I look at it again I misread the code.  My bad.

Ethan


On Tue, Feb 15, 2011 at 12:17 PM, Ben Pfaff <blp at nicira.com> wrote:
> On Tue, Feb 15, 2011 at 11:33:42AM -0800, Ethan Jackson wrote:
>> This looks fine to me. However I'm certainty not the worlds best shell
>> programmer.
>>
>> > +        elif test "X`ovsdb-tool needs-conversion $conf_file $schema_file`" != Xno; then
>> > +            # Back up the old version.
>> > +            version=`ovsdb-tool db-version "$conf_file"`
>> > +            cksum=`ovsdb-tool db-cksum "$conf_file" | awk '{print $1}'`
>>
>> I would tend to prefer to prepend the cksum with something so we don't
>> end up creating a hidden file in the case where there is no cksum.
>
> Can you explain why you think that would happen?  As far as I can tell,
> if there is no checksum, we just end up with a trailing hyphen in the
> filename.  That's slightly ugly but not a real problem, right?
>




More information about the dev mailing list