[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Monotone-devel] file-system archaeology
From: |
hendrik |
Subject: |
Re: [Monotone-devel] file-system archaeology |
Date: |
Tue, 28 Apr 2009 17:15:43 -0400 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
On Tue, Apr 28, 2009 at 01:44:56PM -0700, Zack Weinberg wrote:
> On Tue, Apr 28, 2009 at 1:35 PM, Zack Weinberg <address@hidden> wrote:
> > On Tue, Apr 28, 2009 at 1:11 PM, <address@hidden> wrote:
> >> I'm doing some file-system archaeology again, and I've found a monotone
> >> data base with no branches. It's 311296 bytes long, so it's unlikely to
> >> be empty. Yet,
> >>
> >> address@hidden:~/monotone$ mtn list branches --db w.db
> >> address@hidden:~/monotone$
> >
> > This should give you all head revision IDs, despite the absence of branches:
> >
> > $ mtn -d w.db execute 'select hex(id) from revisions' | tail -n +3 |
> > mtn -d w.db au erase_ancestors -@ -
>
> That's "mtn -d w.db db execute", of course. *headdesk*
>
> This might also be interesting:
>
> $ mtn -d w.db db execute 'select hex(id),keypair,name,value from
> revision_certs order by id,name' | less
>
> zw
Just tried something else:
address@hidden:~/monotone$ mtn db init --db=onion.db
address@hidden:~/monotone$ ls -l onion.db
-rw-r--r-- 1 hendrik sbox 311296 2009-04-28 17:12 onion.db
address@hidden:~/monotone$
So it looks very mich as if those other 311296-byte data bases are
indeed *empty* data bases! Indeed, comparing it with the mystery w.db,
address@hidden:~/monotone$ diff onion.db w.db
address@hidden:~/monotone$
What a surprise! 311296 bytes of nothing.
Yet I have another data base from even darker dark ages, which I
first had to upgrade with mtn upgrade and mtn rosterify. It gives me:
address@hidden:~/monotone$ ls -l database.db
-rw-r--r-- 1 hendrik sbox 46080 2009-04-28 16:09 database.db
address@hidden:~/monotone$ mtn list branches --db=database.db
com.pooq.topoi.sandbox
address@hidden:~/monotone$
This one is smaller -- only 46080 bytes -- and has something in it.
I wonder what all that overhead is doing.
-- hendrik