9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Fossil on devfs
@ 2005-11-22 19:27 Heiko Dudzus
  2005-11-22 19:37 ` Christoph Lohmann
                   ` (2 more replies)
  0 siblings, 3 replies; 18+ messages in thread
From: Heiko Dudzus @ 2005-11-22 19:27 UTC (permalink / raw)
  To: 9fans

I want to mirror fossil with fs(3) and followed the instructions on
the Wiki page.

The hard drives are mirrored, fscfg partitions prepared on both disks,
the fossil configuration changed to /dev/fs/fossil. And the plan9.ini?

fsconfig is set to /dev/sdC0/fscfg.  But what's the correct bootargs
line?  Still

| bootargs=local!#S/sdC0/fossil

?

What's the point of time when #k is bound in the booting process, and
which process does that?  It has to be bound before the execution of
/rc/bin/cpurc, so I don't have to bind it there, do I?

Heiko



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

* Re: [9fans] Fossil on devfs
  2005-11-22 19:27 [9fans] Fossil on devfs Heiko Dudzus
@ 2005-11-22 19:37 ` Christoph Lohmann
  2005-11-22 20:23   ` Russ Cox
  2005-11-22 19:37 ` andrey mirtchovski
  2006-02-02 20:51 ` Tharaneedharan Vilwanathan
  2 siblings, 1 reply; 18+ messages in thread
From: Christoph Lohmann @ 2005-11-22 19:37 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Good day.

On Tue, 22 Nov 2005 20:27:34 +0100
Heiko Dudzus <heiko.dudzus@gmx.de> wrote:

> fsconfig is set to /dev/sdC0/fscfg.  But what's the correct bootargs
> line?  Still

Right.

> | bootargs=local!#S/sdC0/fossil

bootargs=local!#k/fs/fossil

> What's the point of time when #k is bound in the booting process, and
> which process does that?  It has to be bound before the execution of
> /rc/bin/cpurc, so I don't have to bind it there, do I?

devfs.c tries to read a config file from either  /dev/sdC0/fscfg or what
you specify in /env/fsconfig. After that it represents this configuration
in its file system. So when the kernel is running, then #k can be used.

Sincerely,

Christoph



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

* Re: [9fans] Fossil on devfs
  2005-11-22 19:27 [9fans] Fossil on devfs Heiko Dudzus
  2005-11-22 19:37 ` Christoph Lohmann
@ 2005-11-22 19:37 ` andrey mirtchovski
  2005-11-26 13:30   ` Heiko Dudzus
  2006-02-02 20:51 ` Tharaneedharan Vilwanathan
  2 siblings, 1 reply; 18+ messages in thread
From: andrey mirtchovski @ 2005-11-22 19:37 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

here's what i have:

plan9.ini:
fsconfig=/dev/sdC0/fscfg
bootargs=local!#S/sdC0/fossil

fscfg:
# cat /dev/sdC0/fscfg
fsdev:
mirror fossil /dev/sdC0/fossil /dev/sdD0/fossil
mirror isect /dev/sdC0/isect /dev/sdD0/isect
mirror arenas /dev/sdC0/arenas /dev/sdD0/arenas
mirror nvram /dev/sdC0/nvram /dev/sdD0/nvram
#

and fossil config:
# fossil/conf /dev/sdC0/fossil
srv -p fscmd
fsys main config /dev/fs/fossil
....
#

#k is bound by the kernel if it sees $fsconfig.


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

* Re: [9fans] Fossil on devfs
  2005-11-22 19:37 ` Christoph Lohmann
@ 2005-11-22 20:23   ` Russ Cox
  0 siblings, 0 replies; 18+ messages in thread
From: Russ Cox @ 2005-11-22 20:23 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

#k is outside the name space.  It is always available.

When we say bind -a #k /dev, now #k is bound on /dev
and is available as /dev, as in /dev/fs/whatever.

But #k/fs/whatever is always a valid name and requires
no binds or anything else.

Russ


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

* Re: [9fans] Fossil on devfs
  2005-11-22 19:37 ` andrey mirtchovski
@ 2005-11-26 13:30   ` Heiko Dudzus
  2005-11-26 13:55     ` andrey mirtchovski
  0 siblings, 1 reply; 18+ messages in thread
From: Heiko Dudzus @ 2005-11-26 13:30 UTC (permalink / raw)
  To: 9fans

Andrey Mirtchovski wrote:
> here's what i have:
> 
> plan9.ini:
> fsconfig=/dev/sdC0/fscfg
> bootargs=local!#S/sdC0/fossil

Ok. That was it. Thanks.

> fscfg:
> # cat /dev/sdC0/fscfg
> fsdev:
> mirror fossil /dev/sdC0/fossil /dev/sdD0/fossil
> mirror isect /dev/sdC0/isect /dev/sdD0/isect
> mirror arenas /dev/sdC0/arenas /dev/sdD0/arenas
> mirror nvram /dev/sdC0/nvram /dev/sdD0/nvram

What's the point of having /dev/fs/nvram?  To be more specific: I do
see the point of having to copies of the nvram partition.  But out of
curiosity: where do you reference /dev/fs/nvram when using the system?

Isn't /dev/sdC0/9fat worth to be mirrored with devfs?

Heiko



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

* Re: [9fans] Fossil on devfs
  2005-11-26 13:30   ` Heiko Dudzus
@ 2005-11-26 13:55     ` andrey mirtchovski
  2005-11-26 14:34       ` Christoph Lohmann
  2005-11-26 17:55       ` Heiko Dudzus
  0 siblings, 2 replies; 18+ messages in thread
From: andrey mirtchovski @ 2005-11-26 13:55 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> What's the point of having /dev/fs/nvram?  To be more specific: I do
> see the point of having to copies of the nvram partition.  But out of
> curiosity: where do you reference /dev/fs/nvram when using the system?
>

my thinking was that i may need to update a password and didn't want
the disks to be out of sync. that hasn't happened yet in the three
years that i've had this setup...

> Isn't /dev/sdC0/9fat worth to be mirrored with devfs?
>

i don't remember why i didn't have it there. it would require a change
to 9fat: or a new script to mount 9fat from /dev/fs. i simply did a
'dd' from one disk to the other every time i updated a kernel.


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

* Re: [9fans] Fossil on devfs
  2005-11-26 13:55     ` andrey mirtchovski
@ 2005-11-26 14:34       ` Christoph Lohmann
  2005-11-26 14:42         ` andrey mirtchovski
  2005-11-26 17:55       ` Heiko Dudzus
  1 sibling, 1 reply; 18+ messages in thread
From: Christoph Lohmann @ 2005-11-26 14:34 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Good day.

On Sat, 26 Nov 2005 06:55:18 -0700
andrey mirtchovski <mirtchovski@gmail.com> wrote:

> > Isn't /dev/sdC0/9fat worth to be mirrored with devfs?
> >
> 
> i don't remember why i didn't have it there. it would require a change
> to 9fat: or a new script to mount 9fat from /dev/fs. i simply did a
> 'dd' from one disk to the other every time i updated a kernel.

9grid.de mirrors 9fat too, so if one HDD crashes, that you can boot the
other disk with the second boot option - without devfs -, go to the next
shop and buy a replacement.

Sincerely,

Christoph


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

* Re: [9fans] Fossil on devfs
  2005-11-26 14:34       ` Christoph Lohmann
@ 2005-11-26 14:42         ` andrey mirtchovski
  0 siblings, 0 replies; 18+ messages in thread
From: andrey mirtchovski @ 2005-11-26 14:42 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> 9grid.de mirrors 9fat too, so if one HDD crashes, that you can boot the
> other disk with the second boot option - without devfs -, go to the next
> shop and buy a replacement.

i have options in plan9.ini for booting from the first or the second
hard drive via different bootargs options. i wouldn't want to boot a
system with a dead hard drive casually as if nothing has happened. if
anything, a failed boot will force me to mirror the other drive onto a
new disk.


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

* Re: [9fans] Fossil on devfs
  2005-11-26 13:55     ` andrey mirtchovski
  2005-11-26 14:34       ` Christoph Lohmann
@ 2005-11-26 17:55       ` Heiko Dudzus
  2005-11-27  0:54         ` Russ Cox
  1 sibling, 1 reply; 18+ messages in thread
From: Heiko Dudzus @ 2005-11-26 17:55 UTC (permalink / raw)
  To: 9fans

Andrey Mirtchovski wrote:
>> Isn't /dev/sdC0/9fat worth to be mirrored with devfs?
>>
> 
> i don't remember why i didn't have it there. it would require a change
> to 9fat: or a new script to mount 9fat from /dev/fs.

I have made the necessary change to my 9fat: and sent a patch to
sources.



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

* Re: [9fans] Fossil on devfs
  2005-11-26 17:55       ` Heiko Dudzus
@ 2005-11-27  0:54         ` Russ Cox
  2005-11-27  0:55           ` Russ Cox
  0 siblings, 1 reply; 18+ messages in thread
From: Russ Cox @ 2005-11-27  0:54 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> I have made the necessary change
>  to my 9fat: and sent a patch to
> sources.

I would rather see a merging of devfs
into the devsd framework.  Then 9fat:
doesn't need to change at all and we're
back to having all the disk devices served
by #S.  I'm not sure what the name should
be (sdV0 for virtual?), but then you can
just parse ctl commands written to
/dev/sdV0/ctl to create new disks under
/dev/sdV0.

Russ


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

* Re: [9fans] Fossil on devfs
  2005-11-27  0:54         ` Russ Cox
@ 2005-11-27  0:55           ` Russ Cox
  0 siblings, 0 replies; 18+ messages in thread
From: Russ Cox @ 2005-11-27  0:55 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> I would rather see a merging of devfs
> into the devsd framework.  Then 9fat:
> doesn't need to change at all and we're
> back to having all the disk devices served
> by #S.  I'm not sure what the name should
> be (sdV0 for virtual?), but then you can
> just parse ctl commands written to
> /dev/sdV0/ctl to create new disks under
> /dev/sdV0.

Along with this, I would like to see some disk i/o
kprocs so that devfs is not slower than the usual
disks.

Russ


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

* Re: [9fans] Fossil on devfs
  2005-11-22 19:27 [9fans] Fossil on devfs Heiko Dudzus
  2005-11-22 19:37 ` Christoph Lohmann
  2005-11-22 19:37 ` andrey mirtchovski
@ 2006-02-02 20:51 ` Tharaneedharan Vilwanathan
  2006-02-02 23:20   ` Steve Simon
  2 siblings, 1 reply; 18+ messages in thread
From: Tharaneedharan Vilwanathan @ 2006-02-02 20:51 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hi,

I tried to set up mirroring and I got into some issues. With the
available documentation, I tried setting it up. I tried to just use
9pcf kernel. Since I figured that 'fs' is missing, I added it to pcf
config file, built a kernel and tried to use it. The config I tried is
similar to andrey's. But fossil doesnt seem to recognize
/dev/fs/fossil. Does it mean /dev/fs isnt perfect before fossil
starts? Shouldnt I be using 9pcf kernel at all? I tried to dig as much
as I can and found that '#k' is bound somewhere in
connectlocalfossil() and to me it looked like this function is called
both in pccpuf and pcf cases. What could be the problem, then? Am I
missing something?

Any help appreciated.

Thanks
dharani

-----------------------andrey's config sent on 11/23/05------------------
here's what i have:

plan9.ini:
fsconfig=/dev/sdC0/fscfg
bootargs=local!#S/sdC0/fossil

fscfg:
# cat /dev/sdC0/fscfg
fsdev:
mirror fossil /dev/sdC0/fossil /dev/sdD0/fossil
mirror isect /dev/sdC0/isect /dev/sdD0/isect
mirror arenas /dev/sdC0/arenas /dev/sdD0/arenas
mirror nvram /dev/sdC0/nvram /dev/sdD0/nvram
#

and fossil config:
# fossil/conf /dev/sdC0/fossil
srv -p fscmd
fsys main config /dev/fs/fossil
....
#

#k is bound by the kernel if it sees $fsconfig.
---------------------------------------------------------------------------------


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

* Re: [9fans] Fossil on devfs
  2006-02-02 20:51 ` Tharaneedharan Vilwanathan
@ 2006-02-02 23:20   ` Steve Simon
  2006-02-03  0:18     ` Micah Stetson
  0 siblings, 1 reply; 18+ messages in thread
From: Steve Simon @ 2006-02-02 23:20 UTC (permalink / raw)
  To: 9fans

RE: disk mirroring

Have you cloned the data from your existing fossil to its new mirror,
you must do this by hand (with dd) before you first enable mirroring;
I do this booted from the CDROM.

You should be able to see the mirrored partition and the file containing
fs's config in #k/fs, On my home server:

	cpu% ls '#k/fs'
	'#k/fs/arenas0'
	'#k/fs/ctl'
	cpu% cat '#k/fs/ctl'
	mirror arenas0 /dev/sd06/arenas0 /dev/sd010/arenas0
	cpu% 

I use a mirrored venti rather than mirrored fossil but the principal
is the same.

Posting the contents of your plan9.ini, the contents of your fscfg
partition, and the fossil config might help me or others debug the problem,
however if you are using Andreys recpie it should Just Work™

Also rembember, if you are checking for the existance of devfs in your kernel,
if you are connected from a remote plan9/drawterm it may have mounted its
/dev/drivers before your file servers one, try:

	cat /dev/dri?ers | grep devfs

-Steve


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

* Re: [9fans] Fossil on devfs
  2006-02-02 23:20   ` Steve Simon
@ 2006-02-03  0:18     ` Micah Stetson
  2006-02-03  9:10       ` Tharaneedharan Vilwanathan
  0 siblings, 1 reply; 18+ messages in thread
From: Micah Stetson @ 2006-02-03  0:18 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

>         cat /dev/dri?ers | grep devfs

Does that actually print both files?  Wouldn't it just show the first one twice?

Micah


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

* Re: [9fans] Fossil on devfs
  2006-02-03  0:18     ` Micah Stetson
@ 2006-02-03  9:10       ` Tharaneedharan Vilwanathan
  2006-02-03 18:21         ` Heiko Dudzus
  2006-02-04 12:25         ` Steve Simon
  0 siblings, 2 replies; 18+ messages in thread
From: Tharaneedharan Vilwanathan @ 2006-02-03  9:10 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hi Simon,

I did make identical partitions for fossil in two disks and did a dd
copy from CDROM-booted plan9. To me it appears that I have done it
correctly. Your reply seems to be based on /dev/fs and venti. But I am
mirroring fossil. Right now, I couldnt check if /dev/fs is ready with
mirrored partitions before fossil during boot time. I think thats
where the problem is.

Here are my config details:

term% cat plan9.ini
fsconfig=/dev/sdC0/fscfg
bootfile=sdC0!9fat!9pcf
bootargs=local!#S/sdC0/fossil
bootdisk=local!#S/sdC0/fossil

*nomp=1
*nodumpstack=1
partition=new
dmamode=ask

mouseport=ps2
monitor=vesa
vgasize=1280x1024x8

term% cat /dev/sdC0/fscfg
fsdev:
mirror fosssil /dev/sdC0/fossil /dev/sdC1/fossil
term%
term% fossil/conf /dev/sdC0/fossil
fsys main config /dev/sdC0/fossil
fsys main open -V -c 3000

To me, it appears that somehow fs is not ready before fossil asks for
/dev/fs/fossil. The messages I get during boot are :

time...
fossil(#S/sdC0/fossil)...fsOpen: open /dev/fs/fossil: 'dev/fs/fossil'
does not exit
fsys main open -V -c 3000: fsOpen: open /dev/fs/fossil:
'dev/fs/fossil' does not exit
version...boot: mount /: fsys: 'main' not open
panic: boot process died: unknown
dumpstack disabled
cpu0: exiting

Thanks
dharani



On 2/3/06, Micah Stetson <micah@stetsonnet.org> wrote:
> >         cat /dev/dri?ers | grep devfs
>
> Does that actually print both files?  Wouldn't it just show the first one twice?
>
> Micah
>


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

* Re: [9fans] Fossil on devfs
  2006-02-03  9:10       ` Tharaneedharan Vilwanathan
@ 2006-02-03 18:21         ` Heiko Dudzus
  2006-02-04 15:28           ` Tharaneedharan Vilwanathan
  2006-02-04 12:25         ` Steve Simon
  1 sibling, 1 reply; 18+ messages in thread
From: Heiko Dudzus @ 2006-02-03 18:21 UTC (permalink / raw)
  To: 9fans

> I did make identical partitions for fossil in two disks and did a dd
> copy from CDROM-booted plan9. To me it appears that I have done it
> correctly. [...] Right now, I couldnt check if /dev/fs is ready with
> mirrored partitions before fossil during boot time. I think thats
> where the problem is.

#k/fs is ready once the kernel is running.  That shouldn't be the
problem.

> term% cat /dev/sdC0/fscfg
> fsdev:
> mirror fosssil /dev/sdC0/fossil /dev/sdC1/fossil
> term%

There is a typo ("fosssil").  If this typo is really in your fscfg
(and not only in the mail) this is the reason for your problem.

Heiko



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

* Re: [9fans] Fossil on devfs
  2006-02-03  9:10       ` Tharaneedharan Vilwanathan
  2006-02-03 18:21         ` Heiko Dudzus
@ 2006-02-04 12:25         ` Steve Simon
  1 sibling, 0 replies; 18+ messages in thread
From: Steve Simon @ 2006-02-04 12:25 UTC (permalink / raw)
  To: 9fans

This looks very strange, given your error message I agree with you,
it looks like devfs is not up.

try:
	grep devfs '#c/drivers'

to prove that the devfs driver is compiled in.

Interestingly your fossil conf seems to refer to
/dev/sdC0/fossil rather than /dev/fs/fossil. This would
mean fossil would start normally (not with an error)
but not use mirroring.

Perhaps this fossil.conf info is a modified version
of the config you used when you had problems?

-Steve


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

* Re: [9fans] Fossil on devfs
  2006-02-03 18:21         ` Heiko Dudzus
@ 2006-02-04 15:28           ` Tharaneedharan Vilwanathan
  0 siblings, 0 replies; 18+ messages in thread
From: Tharaneedharan Vilwanathan @ 2006-02-04 15:28 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hi Heiko,

On 2/3/06, Heiko Dudzus <heiko.dudzus@gmx.de> wrote:
> > I did make identical partitions for fossil in two disks and did a dd
> > copy from CDROM-booted plan9. To me it appears that I have done it
> > correctly. [...] Right now, I couldnt check if /dev/fs is ready with
> > mirrored partitions before fossil during boot time. I think thats
> > where the problem is.
>
> #k/fs is ready once the kernel is running.  That shouldn't be the
> problem.
>
> > term% cat /dev/sdC0/fscfg
> > fsdev:
> > mirror fosssil /dev/sdC0/fossil /dev/sdC1/fossil
> > term%
>
> There is a typo ("fosssil").  If this typo is really in your fscfg
> (and not only in the mail) this is the reason for your problem.

yep! the output i sent is a capture of actual files and so i guess
thats the problem. since i havent tried devfs before i thought the
problem is elsewhere. so sorry.

i gave up mirroring temporarily and continued fossil+venti
installation and i have made some progress. in a day or so i will
continue mirroring effort and let you know the progress. thanks a lot
for figuring out the problem!

thanks
dharani


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

end of thread, other threads:[~2006-02-04 15:28 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-11-22 19:27 [9fans] Fossil on devfs Heiko Dudzus
2005-11-22 19:37 ` Christoph Lohmann
2005-11-22 20:23   ` Russ Cox
2005-11-22 19:37 ` andrey mirtchovski
2005-11-26 13:30   ` Heiko Dudzus
2005-11-26 13:55     ` andrey mirtchovski
2005-11-26 14:34       ` Christoph Lohmann
2005-11-26 14:42         ` andrey mirtchovski
2005-11-26 17:55       ` Heiko Dudzus
2005-11-27  0:54         ` Russ Cox
2005-11-27  0:55           ` Russ Cox
2006-02-02 20:51 ` Tharaneedharan Vilwanathan
2006-02-02 23:20   ` Steve Simon
2006-02-03  0:18     ` Micah Stetson
2006-02-03  9:10       ` Tharaneedharan Vilwanathan
2006-02-03 18:21         ` Heiko Dudzus
2006-02-04 15:28           ` Tharaneedharan Vilwanathan
2006-02-04 12:25         ` Steve Simon

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).