Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 Apr 2008 13:22:20 +0300
From:      Andriy Gapon <avg@icyb.net.ua>
To:        Andy Kosela <andy.kosela@gmail.com>
Cc:        Michel Talon <talon@lpthe.jussieu.fr>, freebsd-ports@freebsd.org
Subject:   Re: purely package-based/oriented solution
Message-ID:  <48105F5C.8090300@icyb.net.ua>
In-Reply-To: <3cc535c80804240214k2b3059f7xeee9eee22574ed24@mail.gmail.com>
References:  <480E3F5E.3060501@icyb.net.ua> <481032B1.2040907@icyb.net.ua> <3cc535c80804240214k2b3059f7xeee9eee22574ed24@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
on 24/04/2008 12:14 Andy Kosela said the following:
> On Thu, Apr 24, 2008 at 9:11 AM, Andriy Gapon <avg@icyb.net.ua> wrote:
>> on 22/04/2008 22:41 Andriy Gapon said the following:
>>  > Sorry if this is something obvious or a FAQ.
>>  >
>>  > Is there a tool for purely package-based management of third-party software?
>>  > That is, something that meets the following criteria:
>>  > 1. doesn't require ports tree
>>  > 2. works similarly to package installation in FreeBSD installer
>>  > 3. can properly handle upgrading packages (including dependencies)
>>  > 4. can check remote package repositories and, based on timestamp or
>>  > INDEX, can find new versions for installed packages
>>  > 5. can verify that all dependencies would be met before downloading all
>>  > packages in full (e.g. based on INDEX data or can download initial
>>  > blocks of packages, so that package metadata could be extracted and
>>  > examined).
>>  >
>>
>>  Results so far:
>>  1. One tool that I found in ports was bpkg, its description and manual
>>  page sounded promising.
>>  But after I saw the following line in its code I decided to not even try it:
>>  pkg_delete -fa && pkg_add -r $all
>>
> 
>>From my own experience the most stable and reliable as well as the
> most simple method
> for upgrading all packages is still the old "wipe them all first and
> install from scratch", especially when
> using binary only packages and recently you just upgraded to the new
> FreeBSD RELEASE version.
> I used nearly all package managers in the past: 'portupgrade',
> 'portmaster' etc. and all of them had
> some peculiarities which I did not like, and especially portupgrade
> gave me some headaches in the past, so I
> decided to write a simple wrapper shell script around the base, rock
> solid package tools pkg_add, pkg_delete etc.
> On the other note on production systems I usually do not upgrade ALL
> packages using any "automated" scripts
> as usually all of them fail sooner or later :)
> Cleanly upgrading third party packages is still not one of the
> FreeBSD's strong points. On the positive note though, because
> someone mentioned 'yum' you still can't cleanly upgrade RedHat/CentOS
> between major version upgrades.. like RHEL 4 to RHEL 5.
> The only recommended method is still to install from scratch.

Andy,

I agree with everything you said.
It is just that that particular simple way of upgrading all packages is
not very safe (should I say "very unsafe"?). What happens if script for
some reason dies, especially near '&&' point - you are left with no
packages at all. If you haven't saved manually your list of packages
prior to running bpkg even that wouldn't be saved. The script doesn't
automatically account for local/"thirdparty" packages or packages
installed from ports with restrictions - those packages will not be
available from standard package repository.
Your tool is quite good when you know what you are doing, but it can be
dangerous otherwise. And manual page doesn't warn about that.

P.S. I've recently upgraded FC6 to F7 using yum update/upgrade, however
I did have to do rpm magic several times.

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?48105F5C.8090300>