cache-update (portindex) - hangs(?)

2004-12-10 Thread Christopher Illies
Hi,

I am trying to figure out the correct way to use 
sysutils/p5-FreeBSD-Portindex. From how I understand it, the procedure for
updating the ports system would be:

to initialise cache, afterwards occasionally :
# cache-init

then for upating the portstree:
# cvsup -g -L 2 ports-supfile
# cache-update
# portindex -o /usr/ports/INDEX-5 (I am using 5-stable)
# portsdb -u (I am also using portupgrade)
# portupgrade -arR (or whatever)

The problem I have is now that cache-init seems to hang: When I start
it there is activity for some seconds (as seen in top), but no output
at all, then silence - but the command promt does not come back. From a
different terminal I get this (not wrapped):

~%ps aux | grep cache-update
root58657  6.3  2.6  8052 6684  p1  I+9:50AM   0:08.27 cache-update 
(perl)

Since cache-update seems to be idle I used to ctrl-C cache-update and 
then proceed, so far without getting into trouble. Is this expected 
behaviour or am I doing something wrong here?

Christopher


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: cache-update (portindex) - hangs(?)

2004-12-10 Thread Joshua Lokken
On Fri, 10 Dec 2004 14:57:21 +0100, Christopher Illies
<[EMAIL PROTECTED]> wrote:
> Hi,
> 
> I am trying to figure out the correct way to use
> sysutils/p5-FreeBSD-Portindex. From how I understand > it, the procedure for
> updating the ports system would be:
> 
> to initialise cache, afterwards occasionally :
> # cache-init
> 
[snip]
> 
> The problem I have is now that cache-init seems to >hang:  

It took a couple of hours for cache-init to complete on my
K-6/2 450 / 128MB machine at home.  You may just want 
to give it some time.

-- 
Joshua Lokken
Open Source Advocate
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Typo in: cache-update (portindex) - hangs(?)

2004-12-11 Thread Christopher Illies
> > 
> > The problem I have is now that cache-init seems to >hang:  
   ^^

Sorry, this was a typo: I meant cache-update, not cache-init.

> 
> It took a couple of hours for cache-init to complete on my
> K-6/2 450 / 128MB machine at home.  You may just want 
> to give it some time.

Thanks for your reply and sorry for the typo. Yes cache-init also took
a couple of hours on my computer, but when it finished i got the command-promt
back. But I am having problems with cache-update. I include the last
paragraphs of my original post with the typo corrected:

for upating the portstree I do:
# cvsup -g -L 2 ports-supfile
# cache-update
# portindex -o /usr/ports/INDEX-5 (I am using 5-stable)
# portsdb -u (I am also using portupgrade)
# portupgrade -arR (or whatever)


The problem I have is now that cache-update seems to hang: When I start
it there is activity for some seconds (as seen in top), but no output
at all, then silence, but the command promt does not come back. From a
different terminal I get this (not wrapped):

~%ps aux | grep cache-update
root58657  6.3  2.6  8052 6684  p1  I+9:50AM   0:08.27
cache-update (perl)

Since cache-update seems to be idle I used to ctrl-C cache-update and 
then proceed, so far without getting into trouble. Is this expected 
behaviour or am I doing something wrong here?

Christopher

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Typo in: cache-update (portindex) - hangs(?)

2004-12-12 Thread Joshua Lokken
On Sat, 11 Dec 2004 13:24:31 +0100, Christopher Illies
<[EMAIL PROTECTED]> wrote:
> > >
> > > The problem I have is now that cache-init seems to >hang:
>   ^^
> 
> Sorry, this was a typo: I meant cache-update, not cache-init.
> 
> >
> > It took a couple of hours for cache-init to complete on my
> > K-6/2 450 / 128MB machine at home.  You may just want
> > to give it some time.
> 
> Thanks for your reply and sorry for the typo. Yes cache-init also took
> a couple of hours on my computer, but when it finished i got the command-promt
> back. But I am having problems with cache-update. I include the last
> paragraphs of my original post with the typo corrected:
> 
> for upating the portstree I do:
> # cvsup -g -L 2 ports-supfile
> # cache-update
> # portindex -o /usr/ports/INDEX-5 (I am using 5-stable)
> # portsdb -u (I am also using portupgrade)
> # portupgrade -arR (or whatever)
 
What happens if you add

# make fetchindex

immediately after the cvsup?


-- 
Joshua Lokken
Open Source Advocate
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Typo in: cache-update (portindex) - hangs(?)

2004-12-13 Thread Christopher Illies
 > Thanks for your reply and sorry for the typo. Yes cache-init also took
> > a couple of hours on my computer, but when it finished i got the 
> > command-promt
> > back. But I am having problems with cache-update. I include the last
> > paragraphs of my original post with the typo corrected:
> > 
> > for upating the portstree I do:
> > # cvsup -g -L 2 ports-supfile
> > # cache-update
> > # portindex -o /usr/ports/INDEX-5 (I am using 5-stable)
> > # portsdb -u (I am also using portupgrade)
> > # portupgrade -arR (or whatever)
>  
> What happens if you add
> 
> # make fetchindex
> 
> immediately after the cvsup?

I just tried it and it does not change the behaviour of cache-update.
cache-update still shows a short burst of activity before it becomes
idle, but does not return to the command promt.

But if I understand it correctly, isn't the whole purpose of the
portindex-suite to provide yet another mechamism to create an up to
date INDEX(-5) file, but both being faster than 'make index' (portsdb 
-U) and more up to date than 'make fetchindex'? So wouldn't the 'make
fetchindex' kind of defeat the purpose of using portindex? Sorry,  for
all the questions, I am still trying to figure this all this out for
myself. I am still quite unexperienced in FreeBSD .. ;-) 

Christopher

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Typo in: cache-update (portindex) - hangs(?)

2004-12-13 Thread Paul Mather
On Mon, 13 Dec 2004 09:55:55 +0100, Christopher Illies
<[EMAIL PROTECTED]> wrote:


>  > Thanks for your reply and sorry for the typo. Yes cache-init also
> took
> > > a couple of hours on my computer, but when it finished i got the
> command-promt
> > > back. But I am having problems with cache-update. I include the
> last
> > > paragraphs of my original post with the typo corrected:
> > > 
> > > for upating the portstree I do:
> > > # cvsup -g -L 2 ports-supfile
> > > # cache-update
> > > # portindex -o /usr/ports/INDEX-5 (I am using 5-stable)
> > > # portsdb -u (I am also using portupgrade)
> > > # portupgrade -arR (or whatever)
> >  
> > What happens if you add
> > 
> > # make fetchindex
> > 
> > immediately after the cvsup?
> 
> I just tried it and it does not change the behaviour of cache-update.
> cache-update still shows a short burst of activity before it becomes
> idle, but does not return to the command promt.

The reason cache-update becomes idle is that it is waiting for input:
specifically, it's waiting for something from which it can determine the
latest changes to your /etc/ports hierarchy.  (See the cache-update man
page for more details.)

In your case, you should just be able to pipe the output of the cvsup
command into cache-update to achieve the desired effect.  (You might
need to use "cache-update -f cvsup-output" the tell it what kind of
input format you're feeding it.)  In other words, try something akin to
this:

 cvsup -g -L 2 ports-supfile | cache-update -f cvsup-output

I use the "cvsup-checkouts" input format when running cache-update.  In
other words, my cache-update command is as follows (I'm running
-CURRENT):

cache-update -f cvsup-checkouts -i /var/db/sup/ports-all/checkouts.cvs:.

(Note that the final "." is significant.)

Cache-update can also use the "-f plain" input format in conjunction
with its "find-updated" command to look for changes made after a given
date.  See the find-updated man page for details.

So, you have a lot of flexibility in how you can update the portindex
cache.

> But if I understand it correctly, isn't the whole purpose of the
> portindex-suite to provide yet another mechamism to create an up to
> date INDEX(-5) file, but both being faster than 'make index' (portsdb 
> -U) and more up to date than 'make fetchindex'? So wouldn't the 'make
> fetchindex' kind of defeat the purpose of using portindex? Sorry,  for
> all the questions, I am still trying to figure this all this out for
> myself. I am still quite unexperienced in FreeBSD .. ;-) 

You are correct.  If you have portindex installed then using "make
fetchindex" does indeed defeat the purpose. :-)

Cheers,

Paul.
-- 
e-mail: [EMAIL PROTECTED]

"Without music to decorate it, time is just a bunch of boring production
 deadlines or dates by which bills must be paid."
--- Frank Vincent Zappa
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Typo in: cache-update (portindex) - hangs(?)

2004-12-13 Thread Christopher Illies
> The reason cache-update becomes idle is that it is waiting for input:
> specifically, it's waiting for something from which it can determine the
> latest changes to your /etc/ports hierarchy.  (See the cache-update man
> page for more details.)
> 
> In your case, you should just be able to pipe the output of the cvsup
> command into cache-update to achieve the desired effect.  (You might
> need to use "cache-update -f cvsup-output" the tell it what kind of
> input format you're feeding it.)  In other words, try something akin to
> this:
> 
>  cvsup -g -L 2 ports-supfile | cache-update -f cvsup-output
> 
> I use the "cvsup-checkouts" input format when running cache-update.  In
> other words, my cache-update command is as follows (I'm running
> -CURRENT):
> 
> cache-update -f cvsup-checkouts -i /var/db/sup/ports-all/checkouts.cvs:.
> 
> (Note that the final "." is significant.)
> 
> Cache-update can also use the "-f plain" input format in conjunction
> with its "find-updated" command to look for changes made after a given
> date.  See the find-updated man page for details.
> 
> So, you have a lot of flexibility in how you can update the portindex
> cache.

Thanks a lot for this explanation. Rereading the man page now I
actually understand what it says. Maybe the cache-update man page, or
indeed any of the portindex man pages would benefit from an examples
section to make life easier for people like me... 
The way I understand FreeBSD works this means that I have to write it
and then contact the maintainer to submit it?

Christopher

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"