9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] venti...err 2: decompression gave partial block
@ 2007-03-25 20:12 Jerome Ibanes
  2007-03-26 12:57 ` Richard Miller
  0 siblings, 1 reply; 4+ messages in thread
From: Jerome Ibanes @ 2007-03-25 20:12 UTC (permalink / raw)
  To: 9fans

I've had great luck running plan 9 from Xen (using a debian kernel
2.6.18-3-xen-686) on Intel hardware with hardware virtualization...
until recently.

I've recently recreated my cpu+fileserver using a more recent iso
(I was using one from January 07 before that) downloaded on March
24.

I've done the following, which I'm pretty sure is the standard
procedure (non-relevant parts removed):

dd if=/dev/zero of=/usr/xen9/plan9.img seek=$((4 * 1024 * 1024 * 1024 -
1)) bs=1 count=1
xm create plan9inst -c
 use DMA for ide drives[yes]:[enter]
 % inst/textonly[enter]
 Task to do [configfs]:[enter]
 File system (fossil, fossil+venti)[fossil]:fossil+venti[enter]
 Task to do [partdisk]:[enter]
 Disk to partition (sd00, sd01)[no default]:sd00[enter]
 Install mbr (y, n)[no default]:y[enter]
 >>>w[enter]
 >>>q[enter]
 Task to do [prepdisk]:[enter]
 Plan 9 partition to subdivide (/dev/sd00/plan9)[/dev/sd00/plan9]:[enter]
 >>>w[enter]
 >>>q[enter]
 Task to do [fmtfossil]:[enter]
 Fossil partition to format (/dev/sd00/fossil)[/dev/sd00/fossil]:[enter]
 Task to do [mountfs]:[enter]
 Fossil partition (/dev/sd00/fossil)[/dev/sd00/fossil]:[enter]
 Task to do [configdist]:[enter]
 Distribution is from (local, net)[local]:[enter]
 Task to do [mountdist]:[enter]
 Distribution disk [no default]:/dev/sd01/data[enter]
 Location of archives [browse]:[enter]
 /% exit[enter]
 Task to do [fmtventi]:[enter]
 Venti arena partitions to use [/dev/sd00/arenas]:[enter]
 Venti index partitions to use [/dev/sd00/isect]:[enter]
 Task to do [copydist]:[enter]
 Task to do [bootsetup]:[enter]
 Task to do [bootsetup]:[enter]
 Enable boot method (floppy, plan9, win9x, winnt)[no default]:plan9[enter]
 Install the Plan 9 master boot record (y, n)[no default]:y[enter]
 Task to do [finish]:[enter]
 Please make sure the install floppy is in the floppy drive and press
enter.^T^Tr

xm create cpu+fileserver -c
 authid: glenda[enter]
 authdom: google.com[enter]
 secstore key: [enter]
 password: google[enter]
 cd /lib/ndb
 mv local local.old
 cat >/lib/ndb/local <<EOF
# /lib/ndb/local
#
# main network database configuration file


#  files comprising the database
database=
    file=/lib/ndb/local
    file=/lib/ndb/common
    file=/lib/ndb/auth

ipnet=google.com ip=10.0.0.0 ipmask=255.255.255.0
    dnsdomain=google.com
    dns=10.0.0.1
    ntp=router
    smtp=router
    authdom=google.com
    auth=cerberus
    cpu=wopr
    fs=wopr

# what's my name:
ip=10.0.0.7 sys=wopr

# localhost
ip=127.0.0.1 sys=localhost dom=localhost

auth=sources.cs.bell-labs.com authdom=outside.plan9.bell-labs.com
EOF
 cd /rc/bin
 mv cpurc cpurc.old

 cat > /rc/bin/cpurc <<EOF
#!/bin/rc
# /rc/bin/cpurc
#
# cpurc for fileserver

echo -n cpu > /env/service
date > /env/boottime

# replace FILESERVER with the name of your file server
# here we start with kfs, your local disk file system
fileserver=kfs

# default authdom
authdom=google.com

# the local domain to be used in the faces database
facedom=google.com

# mount points
mntgen -s slashn && chmod 666 /srv/slashn

# configure ip address
#ip/ipconfig
ip/ipconfig -g 10.0.0.1 ether /net/ether0 10.0.0.7 255.255.255.0

# name translation, cs sets /dev/sysname
ndb/cs
sysname=`{cat /dev/sysname}
ndb/dns -r

# extract info about our network from ndb
ndb/query ipnet google |rc

# parallelism for mk
NPROC = `{wc -l </dev/sysstat}

# The fileserver will also be timeserver with stratum 9
aux/timesync -n -l -S 9

# services available to networks
aux/listen -q -t /rc/bin/service.auth -d /rc/bin/service il
aux/listen -q -t /rc/bin/service.auth -d /rc/bin/service tcp
EOF
 chmod 775 cpurc
 auth/wrkey
 authid: glenda[enter]
 authdom: google.com[enter]
 secstore key: google42[enter]
 password: google[enter]
 cd
 fossil/conf /dev/sd00/fossil >flproto.bak
 cp flproto.bak flproto
 cat >> flproto <<EOF
 listen tcp!*!564
 listen il!*!17008
EOF
 fossil/conf -w /dev/sd00/fossil flproto
 fshalt
 done halting^T^Tr

Then when I try to boot it, I get the following:

Plan 9
127 holes free
001c5000 027a4000 39710720
39710720 bytes free
cpu0: 1196MHz GenuineIntel P6 (cpuid: AX 0x06E8 DX 0xAFE9FBFF)
#l0: xen: 100Mbps port 0x0 irq -1: 506c616e39ff
128M memory: 40M kernel data, 88M user, 713M swap
cpu0: spurious interrupt 101, last 0
sdxen: backend /local/domain/0/backend/vbd/6/2048/ secsize 512 sectors
8388608
#S/sd00/: part plan9 63 8385930
#S/sd00/: part 9fat 63 204863
#S/sd00/: part nvram 204863 204864
#S/sd00/: part fossil 204864 1463489
#S/sd00/: part arenas 1463489 7756617
#S/sd00/: part isect 7756617 8071273
#S/sd00/: part swap 8071273 8385930
time...
venti...err 2: decompression gave partial block: 5947/8192

clump=10770 failed to read correctly: decompression gave partial block:
5947/8192

fatal /boot/venti error: can't sync server: decompression gave partial
block: 5947/8192

fossil(#S/sd00/fossil)...warning: connecting to venti: connection refused
version...time...
init: can't open /adm/timezone/local
init: exec error: venti i/o error block
54874d82df9e781bd451d3a62a76e7f74c6d223e: not connected to venti server
init: rc exit status: init 32: exec

init: starting /bin/rc
init: exec error: venti i/o error block
54874d82df9e781bd451d3a62a76e7f74c6d223e
init: rc exit status: init 33: exec

init: starting /bin/rc
init: exec error: venti i/o error block
54874d82df9e781bd451d3a62a76e7f74c6d223e
init: rc exit status: init 34: exec
[...]

At this point we're stuck in an endless loop, I suspect a bug in Venti, as
the same steps previously prefectly worked to create a cpu+fileserver
(back in January), I can provide the xen configuration files upon request,
but they haven't changed since I've successfully installed a cpu &
fileserver in January.

Please note that I haven't updated Xen or any of the Xen components or my
linux kernel since January either. Finally, installing plan 9 with the
same Xen machine without Venti (for an auth server) works perfectly.


Thank you for looking into this,
Jerome


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [9fans] venti...err 2: decompression gave partial block
  2007-03-25 20:12 [9fans] venti...err 2: decompression gave partial block Jerome Ibanes
@ 2007-03-26 12:57 ` Richard Miller
  2007-03-26 13:24   ` erik quanstrom
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Miller @ 2007-03-26 12:57 UTC (permalink / raw)
  To: 9fans

>  Task to do [fmtventi]:[enter]
>  Venti arena partitions to use [/dev/sd00/arenas]:[enter]
>  Venti index partitions to use [/dev/sd00/isect]:[enter]

Did this step appear to work properly - no warnings or strange
messages?



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [9fans] venti...err 2: decompression gave partial block
  2007-03-26 12:57 ` Richard Miller
@ 2007-03-26 13:24   ` erik quanstrom
  2007-03-26 20:55     ` Jerome Ibanes
  0 siblings, 1 reply; 4+ messages in thread
From: erik quanstrom @ 2007-03-26 13:24 UTC (permalink / raw)
  To: 9fans

i've had this problem.  it came from not shutting
down venti properly before reboot.  venti is very
sensitive about this.  i haven't used venti in quite
some time (kenfs is less sensitive) so i don't quite
remember the solution. but there are some venti 
maintence commands that'll fix the problem.

- erik

On Mon Mar 26 09:02:25 EDT 2007, 9fans@hamnavoe.com wrote:
> >  Task to do [fmtventi]:[enter]
> >  Venti arena partitions to use [/dev/sd00/arenas]:[enter]
> >  Venti index partitions to use [/dev/sd00/isect]:[enter]
> 
> Did this step appear to work properly - no warnings or strange
> messages?
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [9fans] venti...err 2: decompression gave partial block
  2007-03-26 13:24   ` erik quanstrom
@ 2007-03-26 20:55     ` Jerome Ibanes
  0 siblings, 0 replies; 4+ messages in thread
From: Jerome Ibanes @ 2007-03-26 20:55 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Folks,

I may have found the root cause, when I use a loopback "block device" both
Dom0 and DomU cache the metadata, and this affects Venti's initialization
somehow even if I increase the vfs_cache_pressure kernel tunnable. The
answer here is to use some real block devices (no loop0) to avoid this
caching issue and eventually, from time to time:

echo 3 > /proc/sys/vm/drop_caches

to wipe the metadata cache if you are using a loopback device for the
plan9 cdrom.

Since I've moved to real block devices, I can not repro this issue, which
is a satisfactory workaround.

Thank you for looking into this, if one has the same problem with Xen, I
strongly recommend to use gparted and create some block devices for plan 9
until linux is mature enough to disable metadata caching on loopback
devices, which doesn't appear to be the case as of today.

Jerome Ibanes

On Mon, 26 Mar 2007, erik quanstrom wrote:

> i've had this problem.  it came from not shutting
> down venti properly before reboot.  venti is very
> sensitive about this.  i haven't used venti in quite
> some time (kenfs is less sensitive) so i don't quite
> remember the solution. but there are some venti
> maintence commands that'll fix the problem.
>
> - erik
>
> On Mon Mar 26 09:02:25 EDT 2007, 9fans@hamnavoe.com wrote:
> > >  Task to do [fmtventi]:[enter]
> > >  Venti arena partitions to use [/dev/sd00/arenas]:[enter]
> > >  Venti index partitions to use [/dev/sd00/isect]:[enter]
> >
> > Did this step appear to work properly - no warnings or strange
> > messages?
> >
>

Jerome Ibanes <jibanes@eskimo.com>
Infrastructure Architect & Systems Network Security Administrator
PGP key fingerprint: 3FD68890 6D660FBE F92539EF 6F7BAC03 68151C51


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-03-26 20:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-25 20:12 [9fans] venti...err 2: decompression gave partial block Jerome Ibanes
2007-03-26 12:57 ` Richard Miller
2007-03-26 13:24   ` erik quanstrom
2007-03-26 20:55     ` Jerome Ibanes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).