|
|
[9fans] simple venti question.
The situation:
- standard laptop with fossil+venti
- dead fossil (filled up, can't boot the machine at this point as fossil
is full -- not sure yet why this keeps happening ...)
- I lost the venti score file I was keeping
- Plan is to boot the bootable cd, do the hget of the index,
do the 8.printarenas thing, get a good vac, and restore fossil.
Do I take the lastest or the firstest vac that gets printed when I do the
8.printarenas ?
If I boot the CD, and I do this:
venti/conf /dev/sdC0/arenas0 > /tmp/v.conf I get this:
index main
areas /dev/sdC0/arenas0
areas /dev/sdC0/arenas1
isect /dev/sdC0/isect0
isect /dev/sdC0/isect1
which matches the machine as it has been running.
I have no venti environment variable at this point.
If I run
venti/venti -c /tmp/v.conf
I get this:
err 2: mistmatched number index sections: found 2 expected 1
fatal venti error blah blah blah
Not sure what this is, anyone seen it?
ron
|
|
0
|
|
|
|
Reply
|
rminnich1 (1136)
|
2/4/2004 5:17:34 AM |
|
On Tue, 3 Feb 2004, ron minnich wrote:
> areas /dev/sdC0/arenas0
arenas, sorry.
> areas /dev/sdC0/arenas1
ditto.
|
|
0
|
|
|
|
Reply
|
rminnich1 (1136)
|
2/4/2004 5:21:22 AM
|
|
> Do I take the lastest or the firstest vac that gets printed when I do the
> 8.printarenas ?
Regarding the vac for your fossil, perhaps you could use the
script from rsc that I include below to print the last fossil vac number, and then do
a fossil/flfmt -v using that vac to recover from venti.
> err 2: mistmatched number index sections: found 2 expected 1
> fatal venti error blah blah blah
I've never seen this. I think that it's just that your venti
index is wrong. But from the man page it seems that you'd better
try venti/checkindex and then venti/buildindex, should checkindex
fail.
venti/checkindex [ -f ] [ -B blockcachesize ] venti.config
tmp
venti/buildindex [ -B blockcachesize ] [ -Z ] venti.config
tmp
Buildindex .... This command is typically
used to build a new index for a Venti system when the old
index becomes too small, or to rebuild an index after media
failure.
Checkindex examines the Venti index described in
venti.config. The program detects various error conditions
including: blocks that are not indexed, index entries for
blocks that do not exist, and duplicate index entries. If
requested, an attempt can be made to fix errors that are
found.
#!/bin/rc
rfork e
switch($#*){
case 0
file=/dev/sdC0/fossil
case 1
file=$1
case *
echo 'usage: lastfossil [/dev/sdC0/fossil]' >[1=2]
exit usage
}
fn h2d { echo 'ibase=16;' print `{echo $1|tr a-z A-Z} |bc }
header=`{dd -bs 1024 -iseek 128 -count 1 -if $file >[2]/dev/null| xd -b | sed 1q}
bsize=`{h2d $header(8)^$header(9)}
super=`{h2d 0$header(10)^$header(11)^$header(12)^$header(13)}
x=`{dd -bs $bsize -iseek $super -count 1 -if $file >[2]/dev/null | xd -b |
sed '1,2d;3s/^....... .. .. //;4s/^....... (.. .. .. .. .. ..).*/\1/;4q' | tr -d ' '}
echo vac:^$x(1)^$x(2)
|
|
0
|
|
|
|
Reply
|
nemo5289 (166)
|
2/4/2004 7:24:42 AM
|
|
> - dead fossil (filled up, can't boot the machine at this point as fossil
> is full -- not sure yet why this keeps happening ...)
You probably haven't set up snapshot timeouts for your fossil. From
fossilcons(8):
....
[ fsys name ] snaptime [ -a hhmm ] [ -s interval ] [ -t
timeout ]
....
Snaptime displays and edits the times at which snapshots are
automatically taken. An archival snapshot is taken once a
day, at hhmm, while temporary snapshots are taken at multi-
ples of interval minutes. Temporary snapshots are discarded
once they are timeout minutes old. With no arguments,
snaptime prints the current snapshot times. The -a and -s
options set the archive and snapshot times. An hhmm or
interval of `none' can be used to disable that kind of auto-
matic snapshot. The -t option sets the snapshot timeout.
If timeout is `none', temporary snapshots are not automati-
cally discarded. By default, all three times are set to
`none'.
....
Without that, your fossil will fill up with as many snapshots as fit.
I believe you can make space in your fossil by using the epoch
fossilcons command. But the proper way is to set up a timeout for it
to discard old snapshots.
When this happened to me ages ago, I was able to boot using my old kfs
partition and then start the fossil manually (it wasn't able to serve
files, but the my fscons was available), connect to its console, use
epoch to clear some space and finally boot using fossil again.
Hope this helps,
Robby
|
|
0
|
|
|
|
Reply
|
plan91 (19)
|
2/4/2004 10:12:19 AM
|
|
|
3 Replies
12 Views
(page loaded in 0.081 seconds)
|
|
|
|
|
|
|
|
|