9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Re: [9fans] replica
@ 2002-07-30 12:15 Russ Cox
  0 siblings, 0 replies; 16+ messages in thread
From: Russ Cox @ 2002-07-30 12:15 UTC (permalink / raw)
  To: 9fans

> When I have some local change to a file, replica reports it without telling me
> what was changed in the replica server.  Sometime, I want to know what was
> changed at Labs, because I have no such solid confidence to myself in many
> case.  ;_;   
> 
> May I ask you to put the changed file of the replica server to my local disk 
> with modifying the name, say such kenji.c to kenji.c.p9bell?

i really don't want to start copying random files
around when there are conflicts.

i don't care about most of them and don't want to spend the time
downloading.

you could use this script though.

g% cat /bin/updiff
#!/bin/rc

rfork e

path = (/bin/)

d = /n/sources/plan9

if(! test -e $d) 9fs sources

for(i in $*){
	echo '=====' $i '====='
	ls -lmd $i
	switch($i){
	case /*
		diff -n $d/$i $i 
	case *
		i = `{cleanname -d `{pwd} $i}
		diff  -n $d/$i $i
	}
}
g% cd /sys/src/cmd
g% updiff tar.c
===== tar.c =====
[] --rw-rw-r-- M 8 glenda sys 12030 Feb 28 15:04 tar.c
/n/sources/plan9//sys/src/cmd/tar.c:268,269 c /sys/src/cmd/tar.c:268
< 	/* the mode test is ugly but sometimes necessary */
< 	if (dblock.dbuf.linkflag == '5' || (sp->mode&0170000) == 040000) {
---
> 	if(dblock.dbuf.linkflag == '5')
/n/sources/plan9//sys/src/cmd/tar.c:271,272 d /sys/src/cmd/tar.c:269
< 		sp->mode |= DMDIR;
< 	}
g%



^ permalink raw reply	[flat|nested] 16+ messages in thread
* [9fans] replica
@ 2006-08-25  2:30 Richard Bilson
  2006-08-25  3:38 ` Lyndon Nerenberg
  0 siblings, 1 reply; 16+ messages in thread
From: Richard Bilson @ 2006-08-25  2:30 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

I attempted to update my system using replica tonight, using glenda's
pull script, but as bootes and from the file server console. What
seems to have happened is that replica believed that every file ought
to be deleted. I stopped it before it made it out of /sys/src, so my
system is still usable.

Questions:

- Why?

- What can I do to avoid this in future?

- Is there an easy way to get the files resynchronized with sources?
If I try "replica/pull -v /dist/replica/network", it tells me

sys/src/9/ip/devip.c: not replicated; will not update
sys/src/9/pc/etherigbe.c: not replicated; will not update
sys/src/9/pc/fns.h: not replicated; will not update

etc.

I just realized that I didn't have a writable /tmp, so the pull would
have failed anyway, but I usually expect an error message in this
case, not devastation.

- Richard


^ permalink raw reply	[flat|nested] 16+ messages in thread
* [9fans] replica
@ 2005-02-12 13:42 Sergey Reva
  2005-02-12 16:15 ` Russ Cox
  0 siblings, 1 reply; 16+ messages in thread
From: Sergey Reva @ 2005-02-12 13:42 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hello Fans

I got new installation cd, and use replica/pull
I change 'cd' profile from kfs to fossil target, and run replica/pull.

When pull reached /usr/glenda/lib/profile it write '... file does not exist...'
(i remove glenda user from my system).

Does it mean replica/pull broken (and some files after /usr dir not
processed) or it's only report at end of work?

Why not change 'clientroot' (in replica profile) to '/root'? It's
should work in kfs and fossil too.


--
http://rs-rlab.narod.ru                          mailto:rs_rlab@mail.ru



^ permalink raw reply	[flat|nested] 16+ messages in thread
* [9fans] replica
@ 2004-03-24 13:20 David Presotto
  0 siblings, 0 replies; 16+ messages in thread
From: David Presotto @ 2004-03-24 13:20 UTC (permalink / raw)
  To: 9fans

I've rebuilt rio, sam, acme, and vnc{vs} for the keyboard.h change.  I've
also rebuilt aux/vga since it was getting behind.

Make sure you've removed any spaces around = in your /lib/vgadb.  I've already
done it on the sources one.


^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [9fans] replica
@ 2002-07-04 10:20 Fco.J.Ballesteros
  0 siblings, 0 replies; 16+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04 10:20 UTC (permalink / raw)
  To: 9fans

[-- Attachment #1: Type: text/plain, Size: 123 bytes --]

I think -sn would see them.  (you tell it to use the server version
to resolve conflicts, but not to update your files).

[-- Attachment #2: Type: message/rfc822, Size: 5659 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 311 bytes --]

Can replica/pull -n see the changes after I updated the changes?

I updated too many files in a long time, so I came off the desk, and did
other obligations I have for money.   If I could have some backup files
for locally changed ones, I can check it later, and give enough time to
do that...

Kenji


[-- Attachment #2.1.2: Type: message/rfc822, Size: 3889 bytes --]

[-- Attachment #2.1.2.1.1: Type: text/plain, Size: 206 bytes --]

I do a replica/pull -n to see the changes,
then I use diff or acme to look at what changed if I'm not willing
to pull them without looking first at them.

perhaps this may achieve the effect you want.

[-- Attachment #2.1.2.1.2: Type: message/rfc822, Size: 1762 bytes --]

From: okamoto@granite.cias.osakafu-u.ac.jp
To: 9fans@cse.psu.edu
Subject: [9fans] replica
Date: Thu, 4 Jul 2002 18:21:37 +0900
Message-ID: <20020704092234.344EE19988@mail.cse.psu.edu>

Don't laugh me even though I was much delayed to see replica(1). ^_^
Yeah! Replica is very nice interface to maintain and distribute solid
trees of Plan 9.   Thanks everyone who have worked for it.

I have one request here.

When I have some local change to a file, replica reports it without telling me
what was changed in the replica server.  Sometime, I want to know what was
changed at Labs, because I have no such solid confidence to myself in many
case.  ;_;   

May I ask you to put the changed file of the replica server to my local disk 
with modifying the name, say such kenji.c to kenji.c.p9bell?

Kenji

^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [9fans] replica
@ 2002-07-04 10:16 okamoto
  0 siblings, 0 replies; 16+ messages in thread
From: okamoto @ 2002-07-04 10:16 UTC (permalink / raw)
  To: 9fans

[-- Attachment #1: Type: text/plain, Size: 311 bytes --]

Can replica/pull -n see the changes after I updated the changes?

I updated too many files in a long time, so I came off the desk, and did
other obligations I have for money.   If I could have some backup files
for locally changed ones, I can check it later, and give enough time to
do that...

Kenji


[-- Attachment #2: Type: message/rfc822, Size: 3889 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 206 bytes --]

I do a replica/pull -n to see the changes,
then I use diff or acme to look at what changed if I'm not willing
to pull them without looking first at them.

perhaps this may achieve the effect you want.

[-- Attachment #2.1.2: Type: message/rfc822, Size: 1762 bytes --]

From: okamoto@granite.cias.osakafu-u.ac.jp
To: 9fans@cse.psu.edu
Subject: [9fans] replica
Date: Thu, 4 Jul 2002 18:21:37 +0900
Message-ID: <20020704092234.344EE19988@mail.cse.psu.edu>

Don't laugh me even though I was much delayed to see replica(1). ^_^
Yeah! Replica is very nice interface to maintain and distribute solid
trees of Plan 9.   Thanks everyone who have worked for it.

I have one request here.

When I have some local change to a file, replica reports it without telling me
what was changed in the replica server.  Sometime, I want to know what was
changed at Labs, because I have no such solid confidence to myself in many
case.  ;_;   

May I ask you to put the changed file of the replica server to my local disk 
with modifying the name, say such kenji.c to kenji.c.p9bell?

Kenji

^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [9fans] replica
@ 2002-07-04  9:26 Fco.J.Ballesteros
  0 siblings, 0 replies; 16+ messages in thread
From: Fco.J.Ballesteros @ 2002-07-04  9:26 UTC (permalink / raw)
  To: 9fans

[-- Attachment #1: Type: text/plain, Size: 206 bytes --]

I do a replica/pull -n to see the changes,
then I use diff or acme to look at what changed if I'm not willing
to pull them without looking first at them.

perhaps this may achieve the effect you want.

[-- Attachment #2: Type: message/rfc822, Size: 1762 bytes --]

From: okamoto@granite.cias.osakafu-u.ac.jp
To: 9fans@cse.psu.edu
Subject: [9fans] replica
Date: Thu, 4 Jul 2002 18:21:37 +0900
Message-ID: <20020704092234.344EE19988@mail.cse.psu.edu>

Don't laugh me even though I was much delayed to see replica(1). ^_^
Yeah! Replica is very nice interface to maintain and distribute solid
trees of Plan 9.   Thanks everyone who have worked for it.

I have one request here.

When I have some local change to a file, replica reports it without telling me
what was changed in the replica server.  Sometime, I want to know what was
changed at Labs, because I have no such solid confidence to myself in many
case.  ;_;   

May I ask you to put the changed file of the replica server to my local disk 
with modifying the name, say such kenji.c to kenji.c.p9bell?

Kenji

^ permalink raw reply	[flat|nested] 16+ messages in thread
* [9fans] replica
@ 2002-07-04  9:21 okamoto
  0 siblings, 0 replies; 16+ messages in thread
From: okamoto @ 2002-07-04  9:21 UTC (permalink / raw)
  To: 9fans

Don't laugh me even though I was much delayed to see replica(1). ^_^
Yeah! Replica is very nice interface to maintain and distribute solid
trees of Plan 9.   Thanks everyone who have worked for it.

I have one request here.

When I have some local change to a file, replica reports it without telling me
what was changed in the replica server.  Sometime, I want to know what was
changed at Labs, because I have no such solid confidence to myself in many
case.  ;_;   

May I ask you to put the changed file of the replica server to my local disk 
with modifying the name, say such kenji.c to kenji.c.p9bell?

Kenji



^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [9fans] replica
@ 2002-05-29 16:32 Russ Cox
  0 siblings, 0 replies; 16+ messages in thread
From: Russ Cox @ 2002-05-29 16:32 UTC (permalink / raw)
  To: 9fans

> the advantage of keeping a hash (eg, md5 or sha1) is that it distinguishes
> contents of files, which usually is what really matters,
> whereas modification times and file length by themselves
> aren't really adequate (in general, in my experience).

> in short, i thought the use of hash values in wrap was a good idea
> and was surprised it wasn't part of replica!

i may well have dropped the ball on this one.
i'm still not sure.  replica was written only
for the distribution and as such i had little
experience with it before sending it into battle.
originally i used only mtimes and thought that
having the local metadata kept by the file system
was a feature, so you could play games if you knew
what you were doing.  then i got talked into using lengths
too (and rightfully so), and at that point i should
probably have tossed in the hash.
at this point it's hard to add fields to the database
and the log, since the current replica tools won't
like that.

i originally planned to use tra but it was clear that
tra wouldn't be solid enough by the time it was
needed.  once i understand things better i may set
up tra as an alternate way to get updates.  what i like
best about tra is that it's completely general.

with replica you have to declare a server to be the single
point of truth, and if you try to chain things (e.g.,
you try to grab updates using a different machine as
server, or vita nuova adds or tweaks some files) then
you have to be careful, because in general you can't
just grab updates from any other machine and expect everything
to work.

if we were using tra, you could install a new system
using any other plan 9 system you had available on the
network, and it would still be safe to go back to
sources for updates.  i still want to see what that
would be like, but it won't happen until the fall.

russ


^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [9fans] replica
@ 2002-05-29  9:43 forsyth
  0 siblings, 0 replies; 16+ messages in thread
From: forsyth @ 2002-05-29  9:43 UTC (permalink / raw)
  To: 9fans

>>Then you have to spend time downloading the
>>remote file when most of the time you're going to throw it away
>>because the local file _has_ been locally modified.
>>I could have included sha1 hashes in the replica(8) metadata.
>>Oh well.  I expected this not to happen very often,
>>and so far have not been proved wrong.

the advantage of keeping a hash (eg, md5 or sha1) is that it distinguishes
contents of files, which usually is what really matters,
whereas modification times and file length by themselves
aren't really adequate (in general, in my experience).  Qid.path and Qid.vers
might do i suppose, but are unique to Plan 9, and even they can change
when the contents of a file hasn't actually changed.  the hash makes it easier
to track versions historically (eg, if i have a file with a given hash code,
i can check distribution packages or logs to see whether that file was
ever actually distributed as it stands, and if so, when).  similarly,
if i've got an external replica, i can also use
the hash values to relate it to the contents of a (worm) file system dump.
there is a risk with hashing of false hits, but perhaps venti suggests
that people can be relaxed about that if the hash is peculiar enough.

in short, i thought the use of hash values in wrap was a good idea
and was surprised it wasn't part of replica!



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

end of thread, other threads:[~2006-08-28  2:46 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-30 12:15 [9fans] replica Russ Cox
  -- strict thread matches above, loose matches on Subject: below --
2006-08-25  2:30 Richard Bilson
2006-08-25  3:38 ` Lyndon Nerenberg
2006-08-25  4:08   ` geoff
2006-08-25  8:19     ` Martin Neubauer
2006-08-27 23:23       ` geoff
2006-08-28  2:46         ` Richard Bilson
2005-02-12 13:42 Sergey Reva
2005-02-12 16:15 ` Russ Cox
2004-03-24 13:20 David Presotto
2002-07-04 10:20 Fco.J.Ballesteros
2002-07-04 10:16 okamoto
2002-07-04  9:26 Fco.J.Ballesteros
2002-07-04  9:21 okamoto
2002-05-29 16:32 Russ Cox
2002-05-29  9:43 forsyth

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