Weird pkg_info behavior?

2008-09-30 Thread Slim Joe
When I invoke something like "pkg_info vim*",
pkg_info insists on downloading all the packages named
"vim*". That is, I see a bunch of "vim*" packages on
"." (present directory). Is there a way to get package
info for a file not already downloaded or installed without
such heavy bandwidth (just the package info).

Note that my $PKG_PATH is set to ftp://[mirror site].



Re: Weird pkg_info behavior?

2008-09-30 Thread Bryan Irvine
On Tue, Sep 30, 2008 at 11:16 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
> When I invoke something like "pkg_info vim*",
> pkg_info insists on downloading all the packages named
> "vim*". That is, I see a bunch of "vim*" packages on
> "." (present directory). Is there a way to get package
> info for a file not already downloaded or installed without
> such heavy bandwidth (just the package info).
>
> Note that my $PKG_PATH is set to ftp://[mirror site].
>
>

There's probably a better way but since nobody has responded maybe try

ftp $PKG_PATH

ftp> ls vim*
-r--r--r--1 00 6253054 Mar 14  2008 vim-7.1.244p0-gtk2.tgz
-r--r--r--1 00 6168107 Mar 11  2008 vim-7.1.244p0-no_x11.tgz
-r--r--r--1 00 1216459 Mar 14  2008
vim-lang-7.1.244-gtk2.tgz

ftp> get  vim-7.1.244p0-no_x11.tgz " | pkg_info - "

-B



Re: Weird pkg_info behavior?

2008-09-30 Thread James Hartley
On Tue, Sep 30, 2008 at 11:16 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
> Is there a way to get package
> info for a file not already downloaded or installed without
> such heavy bandwidth (just the package info).

Look at the -Q option on the pkg_info(1) manpage.



Re: Weird pkg_info behavior?

2008-09-30 Thread Nick Guenther
On Tue, Sep 30, 2008 at 8:14 PM, James Hartley <[EMAIL PROTECTED]> wrote:
> On Tue, Sep 30, 2008 at 11:16 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
>> Is there a way to get package
>> info for a file not already downloaded or installed without
>> such heavy bandwidth (just the package info).
>
> Look at the -Q option on the pkg_info(1) manpage.
>

I think he's asking for how to read package descriptions without
downloading everything. But pkg_info has to download the entirety of
each package first because a package is a compressed archive file.

If you are looking for package descriptions, install the ports tree
and read the Makefiles. Also, if you are lazy/not on an OpenBSD box,
most of the descriptions are available at
http://www.openbsd.org/4.3_packages/.

-Nick



Re: Weird pkg_info behavior?

2008-09-30 Thread andrew fresh
On Tue, Sep 30, 2008 at 10:47:56PM -0400, Nick Guenther wrote:
> If you are looking for package descriptions, install the ports tree
> and read the Makefiles. Also, if you are lazy/not on an OpenBSD box,
> most of the descriptions are available at
> http://www.openbsd.org/4.3_packages/.

or even 
http://openports.se/search.php?so=vim

l8rZ,
-- 
andrew - ICQ# 253198 - Jabber: [EMAIL PROTECTED]

BOFH excuse of the day: internet is needed to catch the etherbunny



Re: Weird pkg_info behavior?

2008-10-01 Thread Stuart Henderson
On 2008-10-01, Nick Guenther <[EMAIL PROTECTED]> wrote:
> If you are looking for package descriptions, install the ports tree
> and read the Makefiles.

For 4.4/-current, landry@ has written a curses-based package browser,
pkg_mgr. It's in the ports tree and of course a package is available,
"pkg_add pkg_mgr".



Re: Weird pkg_info behavior?

2008-10-01 Thread Slim Joe
On 2008/10/1, Stuart Henderson <[EMAIL PROTECTED]> wrote:
> On 2008-10-01, Nick Guenther <[EMAIL PROTECTED]> wrote:
>> If you are looking for package descriptions, install the ports tree
>> and read the Makefiles.

A lynx dump of http://www.openbsd.org/4.3_packages/i386.html
seems more handy.

> For 4.4/-current, landry@ has written a curses-based package browser,
> pkg_mgr. It's in the ports tree and of course a package is available,
> "pkg_add pkg_mgr".

That's something to wait for then. From what I read it references
openports.se.



Re: Weird pkg_info behavior?

2008-10-02 Thread Landry Breuil
On Thu, Oct 2, 2008 at 3:20 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
> On 2008/10/1, Stuart Henderson <[EMAIL PROTECTED]> wrote:
>> On 2008-10-01, Nick Guenther <[EMAIL PROTECTED]> wrote:
>>> If you are looking for package descriptions, install the ports tree
>>> and read the Makefiles.
>
> A lynx dump of http://www.openbsd.org/4.3_packages/i386.html
> seems more handy.
>
>> For 4.4/-current, landry@ has written a curses-based package browser,
>> pkg_mgr. It's in the ports tree and of course a package is available,
>> "pkg_add pkg_mgr".
>
> That's something to wait for then. From what I read it references
> openports.se.

It has nothing to do with openports.se, it uses databases/sqlports as
its backend.

Landry



Re: Weird pkg_info behavior?

2008-10-03 Thread Marc Espie
On Tue, Sep 30, 2008 at 10:47:56PM -0400, Nick Guenther wrote:
> On Tue, Sep 30, 2008 at 8:14 PM, James Hartley <[EMAIL PROTECTED]> wrote:
> > On Tue, Sep 30, 2008 at 11:16 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
> >> Is there a way to get package
> >> info for a file not already downloaded or installed without
> >> such heavy bandwidth (just the package info).
> >
> > Look at the -Q option on the pkg_info(1) manpage.
> >
> 
> I think he's asking for how to read package descriptions without
> downloading everything. But pkg_info has to download the entirety of
> each package first because a package is a compressed archive file.

Nope, that's incorrect.

pkg_info will only download the beginning of the package, since it only
needs the packing information, and we're very careful to store it at
the beginning.

Now, a lot of FTP servers tend to not like abort in the middle of transfer,
especially when coupled with idiot firewalls. http transfers should be
slightly better.

Strangely enough, pkg transfers over scp is the fastest, due to using
a specialized protocol that avoids this set-up/tear-down altogether.

So what you see is very much set-up/tear-down of connections, pkg_info
actually uses very little bandwidth, but it has a high latency.



Re: Weird pkg_info behavior?

2008-10-04 Thread Slim Joe
On 2008/10/4, Marc Espie <[EMAIL PROTECTED]> wrote:

> pkg_info will only download the beginning of the package, since it only
> needs the packing information, and we're very careful to store it at
> the beginning.
>
> Now, a lot of FTP servers tend to not like abort in the middle of transfer,
> especially when coupled with idiot firewalls. http transfers should be
> slightly better.

I'm not sure but the partial transfer appears to work with single
(versioned) files. I think I'm using (I'm not at the machine atm)
PKG_PATH=ftp://ftp.eu.openbsd.org/pub/OpenBSD/.

Also I think it would be nice if the packages are dumped not into
the present directory but in the $PKG_CACHE that I have set.
This makes it convenient to export PKG_PATH=$PKG_CACHE:etc

> Strangely enough, pkg transfers over scp is the fastest, due to using
> a specialized protocol that avoids this set-up/tear-down altogether.
>
> So what you see is very much set-up/tear-down of connections, pkg_info
> actually uses very little bandwidth, but it has a high latency.

I'm not familiar with scp (never used it). Where's the list of scp mirrors?



Re: Weird pkg_info behavior?

2008-10-04 Thread Philip Guenther
[In the context of pkg_info only downloading the first part of a
package to get the info]

On Sat, Oct 4, 2008 at 5:09 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
...
> Also I think it would be nice if the packages are dumped not into
> the present directory but in the $PKG_CACHE that I have set.

pkg_add does that (assuming you actually export PKG_CACHE), but I
don't see why pkg_info would, given that it expects to only download
the start of the package file and not the entire thing.  Leaving
partial package files in your cache would be confusing, IMO.

(Or did I misunderstand your suggestion?)


Philip Guenther



Re: Weird pkg_info behavior?

2008-10-05 Thread Slim Joe
On 2008/10/5, Philip Guenther <[EMAIL PROTECTED]> wrote:
> [In the context of pkg_info only downloading the first part of a
> package to get the info]
>
> On Sat, Oct 4, 2008 at 5:09 AM, Slim Joe <[EMAIL PROTECTED]> wrote:
>>
>> Also I think it would be nice if the packages are dumped
>> not into the present directory but in the $PKG_CACHE that
>> I have set.
>
> pkg_add does that (assuming you actually export PKG_CACHE),
> but I don't see why pkg_info would, given that it expects
> to only download the start of the package file and not the
> entire thing.  Leaving partial package files in your cache
> would be confusing, IMO.
>
> (Or did I misunderstand your suggestion?)

Does the pkg install mechanism allow for resumable downloads? Up
to now I've managed to finish all my installs in one run. But
I assume resuming is possible, since pkg_add uses plain ftp
to download the package tgz. It would then save bandwidth
if pkg_add resumes from the partial download already made
by pkg_info.