DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD Ports and Packages

FreeBSD Ports and Packages Installation and upgrading of ports and packages on FreeBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 18th July 2008
jaymax jaymax is offline
Port Guard
 
Join Date: Jun 2008
Posts: 16
Default portupgrade -a =>Stale Dependency

Hello,
For a quick bit of advice, upgrading ports and get this response, but can't quite interpret it

mach1 # portupgrade -aF
Stale dependency: pear-1.4.11 --> apache-1.3.37_1 -- manually run 'pkgdb -F' to fix, or specify -O to force.

I subsequently ran
portupgrade -aO

and it seems to be upgrading, but omiting something I believe, "pear-1.4.11" or "apache-1.3.37_1" ?

Could someone explain

Thanks
Reply With Quote
  #2   (View Single Post)  
Old 18th July 2008
robbak's Avatar
robbak robbak is offline
Real Name: Robert Backhaus
VPN Cryptographer
 
Join Date: May 2008
Location: North Queensland, Australia
Posts: 366
Default

Why didn't you run 'pkgdb -F'? That would have suggested what package to upgrade or install to fix the problem.

Basically, pear-1.4.11 needs apache=1/3.37_1, but it is not there. Probably it has been updated without portupgrade knowing about it, and the record needs to be changed to the currently instaled version

Specifying -O just tries to go ahead without fixing that up. Who knows what will happen - probably the build will fail because things are not right - and you will have to fix it with pkgdb, like it suggested.

So, when the portupgrade run fails or completes, run pkgdb -F.
__________________
The only dumb question is a question not asked.
The only dumb answer is an answer not given.
Reply With Quote
  #3   (View Single Post)  
Old 18th July 2008
jaymax jaymax is offline
Port Guard
 
Join Date: Jun 2008
Posts: 16
Default

Why didn't you run 'pkgdb -F'?
I did, but not been sure of what I was doing ran the default of all the questions asked

Later on running
Quote:
portupgrade -aO
it seemed to run forever compiling all the programs in the ports, I naively expected it to simply transfer the updated sources to the system. Anyway, it eventually terminated with a
"Packages processed: 77 done, 122 ignored, 349 skipped and 21 failed"
and a listing of the failed and skipped files

I subsequently ran
Quote:
pkgdb -afF
=>
Quote:
Missing origin: bsdpan-CPAN-1.8802
Missing origin: bsdpan-CPAN-1.9205
Missing origin: bsdpan-Compress-Raw-Zlib-2.001
Missing origin: bsdpan-IO-Compress-Base-2.001
Missing origin: bsdpan-IO-Compress-Zlib-2.001
Missing origin: bsdpan-Term-ReadLine-Perl-1.0302
Missing origin: bsdpan-TermReadKey-2.30
Missing origin: bsdpan-razor-agents-2.84
Missing origin: bsdpan-razor-agents-sdk-2.07
and several lines of output to stdout of the nature below --
(Stale and Skipped lines) couldn't find directives in man or other pages

Quote:
Stale origin: 'databases/postgresql74-client': perhaps moved or obsoleted.
Stale dependency: OpenEXR-1.2.2_1 -> pkg-config-0.21 (devel/pkg-config):
Skipped. (running in non-interactive mode; specify -i to ask)
Stale dependency: dvipsk-tetex-5.95a_1 -> pkg-config-0.21 (devel/pkg-config):
Skipped. (running in non-interactive mode; specify -i to ask)
Thanks
Reply With Quote
  #4   (View Single Post)  
Old 18th July 2008
DrJ DrJ is offline
ISO Quartermaster
 
Join Date: Apr 2008
Location: Gold Country, CA
Posts: 507
Default

Your knowledge of portupgrade seems rather incomplete. I'd suggest you read this first:

http://www.onlamp.com/pub/a/bsd/2003...SD_Basics.html

One rule of thumb is *never* to force the upgrade to all your ports. You just are asking for trouble. It is better to do it in bunches, making sure always to read /usr/ports/UPDATING first.

Regarding your question, I'd guess that you have updated you ports tree, and things have moved around somewhat. That is no big deal, but you do have to update the ports databases so that the dependencies you need are handled properly.

You might also consider using "script" to record what happened. The files can be huge, but that is the only way you can wade through what happens if you do a large portupgrade.
Reply With Quote
  #5   (View Single Post)  
Old 19th July 2008
jaymax jaymax is offline
Port Guard
 
Join Date: Jun 2008
Posts: 16
Default

Was looking for a good reference
Reply With Quote
  #6   (View Single Post)  
Old 19th July 2008
jb_daefo jb_daefo is offline
Spam Deminer
 
Join Date: May 2008
Posts: 303
Default

when running pkgdb -F: I usually encounter stale dependencies when I
cannot reinstall a dependency a port needs because it conflicts with some
other port (so usually the port itself cannot be bumped to a newer version;
however it remains usually usable as is). The stock answer in that case is:
...............
such-and-such is the stale dep? NO
install the actual stale dep? NO
new actual dependency ? [no answer]=enter key
skip this[y]? y
....................
which usually solves the problem for the time being.
for the last question above, an a rather than a y skips all remaing
questions about that stale dependency (the other ports which
may depend on it)
....................
__________________
FreeBSD 13-STABLE
Reply With Quote
  #7   (View Single Post)  
Old 19th July 2008
robbak's Avatar
robbak robbak is offline
Real Name: Robert Backhaus
VPN Cryptographer
 
Join Date: May 2008
Location: North Queensland, Australia
Posts: 366
Default

Generally, when you cannot reinstall a dependency because it conflicts, you need to set up the installed conflicting port as the dependency.

So, if netABC1 conflicts with the installed netCBA2, and AlphaApp has a dependency on netABC1, it is usually because netCBA is providing the files and services AlphaApp needs. So, you need to use pkgdb -F to change AlphaApp's dependency to netCBA2.

So when it asks for the new actual dependency, type in the name of the new dependency. (netCBA-2.0.32_2) Tab completion works to fill in all the version cruft, as well.
__________________
The only dumb question is a question not asked.
The only dumb answer is an answer not given.
Reply With Quote
  #8   (View Single Post)  
Old 20th July 2008
Weaseal's Avatar
Weaseal Weaseal is offline
Package Pilot
 
Join Date: May 2008
Location: East Coast, US
Posts: 177
Default

Life can be easier... get away from portupgrade and its pkgdb! Try portmaster, which only uses INDEX.
__________________
FreeBSD addict since 4.2-RELEASE.
My FreeBSD wiki.
Reply With Quote
  #9   (View Single Post)  
Old 20th July 2008
DrJ DrJ is offline
ISO Quartermaster
 
Join Date: Apr 2008
Location: Gold Country, CA
Posts: 507
Default

That is actually a good suggestion. I've found recently that portupgrade does not work on certain ports any longer. Portmaster works fine. Personally I still use portupgrade, just because I know it, save for those few special cases.
Reply With Quote
Old 20th July 2008
robbak's Avatar
robbak robbak is offline
Real Name: Robert Backhaus
VPN Cryptographer
 
Join Date: May 2008
Location: North Queensland, Australia
Posts: 366
Default

Good suggestion: however, the only reason why i have not migrated away from portupgrade completely is that it is still the most supported upgrade tool: things like the gnome upgrade scripts still work on portupgrade. At least, they did when I last touched them.

This will change, I believe, and we will some day see portmaster in base, too; and portmaster is certainly very good, and works well; but I don't think it is time to dump portupgrade quite yet.
__________________
The only dumb question is a question not asked.
The only dumb answer is an answer not given.
Reply With Quote
Old 20th July 2008
DrJ DrJ is offline
ISO Quartermaster
 
Join Date: Apr 2008
Location: Gold Country, CA
Posts: 507
Default

Quote:
Originally Posted by robbak View Post
the only reason why i have not migrated away from portupgrade completely is that it is still the most supported upgrade tool: things like the gnome upgrade scripts still work on portupgrade.
Agreed. The upgrade scripts are becoming "multilingual" in that usually commands for both portupgrade and portmaster are given. I've not tried anything major with portmaster (other than ImageMagick, which seems to need it); portupgrade has always worked well enough otherwise. And that includes Gnome, which is not a trivial matter.
Reply With Quote
Old 22nd July 2008
jaymax jaymax is offline
Port Guard
 
Join Date: Jun 2008
Posts: 16
Default

Thanks for a very spirited discussion. I've always had problems with the ports, even after reading the handbook, this helped considerably.

Now. I have one other issue if I use cvsup to sync the ports tree, which I can do as a cron job do I still have to use portupgrade or would that be redundant?

I have used cvsup and this is what it produces =>

The file --
cat /usr/local/sup/supfile
*default host=cvsup.ca.freebsd.org
*default base=/usr/local/etc/cvsup
*default prefix=/usr
*default release=cvs delete use-rel-suffix compress
ports-all tag=.
The command line --
cvsup -g -L 2 /usr/local/sup/supfile
Parsing supfile "/usr/local/sup/supfile"
Connecting to cvsup.ca.freebsd.org
Connected to cvsup.ca.freebsd.org
Server software version: SNAP_16_1h
Negotiating file attribute support
Exchanging collection information
Establishing multiplexed-mode data connection
Running
Cleaning up ...
Inactivity timeout
Will retry at 21:07:09
----

It seemed to have been running, why would it timeout, there did not seem to be any interactive mode.

Thanks again
Reply With Quote
Old 22nd July 2008
jaymax jaymax is offline
Port Guard
 
Join Date: Jun 2008
Posts: 16
Default

Think I found the answers in
http://www.onlamp.com/pub/a/bsd/2003...SD_Basics.html

Run cvsup to sync the ports tree.
Run portsdb to update INDEX.db.
Use portversion to determine which applications need upgrading.
Use portupgrade to upgrade those applications.
Reply With Quote
Old 22nd July 2008
Weaseal's Avatar
Weaseal Weaseal is offline
Package Pilot
 
Join Date: May 2008
Location: East Coast, US
Posts: 177
Default

Quote:
Originally Posted by jaymax View Post
Think I found the answers in
http://www.onlamp.com/pub/a/bsd/2003...SD_Basics.html

Run cvsup to sync the ports tree.
Run portsdb to update INDEX.db.
Use portversion to determine which applications need upgrading.
Use portupgrade to upgrade those applications.
That article is 5 years old and unfortunately none/little of the information is still particularly correct.

Don't use cvsup to sync ports; use csup. It's included in the base install of FreeBSD-6.2+/FreeBSD-7.0+. It works exactly like cvsup.

Better yet, don't even use csup, but use portsnap. Examples:
For the first time you ever run portsnap (this will take a while):
Code:
# portsnap fetch extract
For future updates, you can run the much faster:
Code:
# portsnap fetch update
This is far faster than c[v]sup and uses much less bandwidth.


In terms of portupgrade, I don't recommend using it. I don't even have it on my system and haven't for quite some time. Its database is slow and breaks easily. Use portmaster, I've never had it complain about "broken dependencies." See ports-mgmt/portmaster, and issue:
Code:
# portmaster -uad
and see how easy life can be.

In short, here is everything I do to update my ports tree:
Code:
# portsnap fetch update
# portmaster -uad
And then I go have a tea.
__________________
FreeBSD addict since 4.2-RELEASE.
My FreeBSD wiki.

Last edited by Weaseal; 22nd July 2008 at 06:39 AM.
Reply With Quote
Old 22nd July 2008
DrJ DrJ is offline
ISO Quartermaster
 
Join Date: Apr 2008
Location: Gold Country, CA
Posts: 507
Default

Quote:
Originally Posted by jaymax View Post
Now. I have one other issue if I use cvsup to sync the ports tree, which I can do as a cron job do I still have to use portupgrade or would that be redundant?
Yes, you still need portupgrade (or friends). cvsup or csup updates the ports tree in /usr/ports and nothing more. You still have to update the ports themselves. Don't forget to update pkgdb and portsdb is you use portupgrade.
Reply With Quote
Old 23rd July 2008
DutchDaemon's Avatar
DutchDaemon DutchDaemon is offline
Real Name: Ben
Spam Refugee
 
Join Date: Jul 2008
Location: Rotterdam, The Netherlands
Posts: 336
Default

I normally use these in order (there's a script running these commands in this order anyway; there are checks for errors in there)

/usr/sbin/portsnap fetch
/usr/sbin/portsnap update
/usr/local/sbin/portsdb -Fu
/usr/sbin/pkg_version -L '='
/usr/bin/grep -B 1 AFFECTS: /usr/ports/UPDATING | /usr/bin/head -20
/usr/local/sbin/pkgdb -L

Running 'portupgrade someport' or even 'portupgrade -a' comes after that, of course.

Last edited by DutchDaemon; 23rd July 2008 at 10:13 AM.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
portupgrade, upgrading the whole system deadeyes FreeBSD Ports and Packages 2 24th August 2009 05:25 AM
pthread/portupgrade problems magic FreeBSD Installation and Upgrading 1 18th August 2009 07:35 AM
portupgrade -af, how to submit fetch options? bsdfan FreeBSD Ports and Packages 4 28th December 2008 09:05 PM
Portupgrade problem hitete FreeBSD Ports and Packages 1 28th August 2008 03:53 PM
PATCH errors during portupgrade shinjii FreeBSD Installation and Upgrading 4 23rd June 2008 02:47 AM


All times are GMT. The time now is 04:11 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick