Alright, I feel stupid but I'm going to ask anyway... Portversion exists in /usr/local/sbin on one FreeBSD 5.2.1 server, but not on the other, which is an install off the *same CD*. What package or port does portversion come from?
Thanks.... ::-----Original Message----- ::From: Randy Pratt [mailto:[EMAIL PROTECTED] ::Sent: Tuesday, June 08, 2004 12:16 PM ::To: Kent Stewart ::Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] ::Subject: portupgrade -c (was Re: Boot GUI / Boot data and ::process / Fragmentation) :: :: ::On Tue, 8 Jun 2004 00:59:58 -0700 ::Kent Stewart <[EMAIL PROTECTED]> wrote: :: ::> On Tuesday 08 June 2004 12:37 am, Bruce Hunter wrote: ::> > Thanks for your help Kent ::> > ::> > I read something about using portversion -c with the portupgrade ::> > command to upgrade installed pkgs that needed to be updated. ::> > ::> > When I run portversion -c :: I get a print out of things ::needed to ::> > be upgraded and at the end, it shows a 'if' statment. ::> > ::> > How do you use this command with portupgrade so it just ::updates them ::> > instead of just showing me. Just do it dang it... just do it! ;o) :: ::The output of "portversion -c" needs to be redirected to a file: :: :: portversion -c > scriptname.sh :: ::To make it usable as a shell script, it needs to have :: :: #!/bin/sh :: ::added at the top to insure that it uses the sh command ::interperter. Then, the script needs to be made executable: :: :: chmod 744 scriptname.sh :: ::Then it can be run as root: :: :: ./scriptname.sh :: ::> I'm not the one to ask because I use the -c and do them one ::at a time. ::> The portupgrade option -rRa will do some of it. I just want ::it to do it ::> at my convience and choosing :). I also have an AMD 2400+ ::that sits off ::> to the side of my computer desk and I build everything on it. The ::> problem with the -c list is that it doesn't build ::dependancies first. :: ::I think it will build the required dependencies first *if* ::they need updated. The synopsis of portupgrade is: :: :: portupgrade [ ... bunch of options ... ] pkgname-glob :: ::A list of ports can be passed to portugrade and it will check ::which needs to be built first. This can easily be checked if ::you have doubts. Use -n for "no-execute" and -f to "force". ::This is a test case I tried where liveMedia is a dependency ::of mplayer: :: :: # portupgrade -nf mplayer-gtk-esound-0.92.1_2 liveMedia-2004.06.07,1 :: ---> Session started at: Tue, 08 Jun 2004 11:06:39 -0400 :: ---> Reinstallation of net/liveMedia started at: Tue, 08 Jun 2004 :: 11:06:40 -0400 :: ---> Reinstalling 'liveMedia-2004.06.07,1' (net/liveMedia) :: OK? [no] :: ---> Reinstallation of net/liveMedia ended at: Tue, 08 Jun 2004 :: 11:06:40 -0400 (consumed 00:00:00) :: ---> Reinstallation of multimedia/mplayer started at: Tue, 08 Jun :: 2004 11:06:41 -0400 :: ---> Reinstalling 'mplayer-gtk-esound-0.92.1_2' :: (multimedia/mplayer) :: OK? [no] :: ---> Reinstallation of multimedia/mplayer ended at: Tue, 08 Jun :: 2004 11:06:41 -0400 (consumed 00:00:00) :: ---> Listing the results (+:done / -:ignored / *:skipped / ::!:failed) :: + net/liveMedia (liveMedia-2004.06.07,1) :: + multimedia/mplayer (mplayer-gtk-esound-0.92.1_2) :: ---> Packages processed: 2 done, 0 ignored, 0 skipped and 0 failed :: ---> Session ended at: Tue, 08 Jun 2004 11:06:41 -0400 ::(consumed 00:00:01) :: # :: ::Notice that liveMedia was updated first even though it was ::last in the list of ports passed to portupgrade. The portversion -c ::produces a list of ports and stores them in its variable ::$pkgs. Portupgrade will take the list and build them in the ::correct dependency order. :: ::I've used this approach for several years now and it works fine. :: ::However, caution should be used when scripting the upgrading ::of ports. After cvsupping and running portsdb -Uu, the ::/usr/ports/UPDATING should be read and any items that are ::applicable to the installation should be followed before ::running any scripts or other portupgrade commands. :: ::If you still prefer doing ports manually, the output of ::portupgrade -c can still be useful. By modifying the script ::slightly, it will produce a list of ports to be updated in ::the order they should be updated. Just change the line: :: :: portupgrade "$@" $pkgs :: ::to: :: :: pkg_glob $pkgs | pkg_sort :: ::It should be noted that some ports may not work until the ::entire list is updated and as usual, your mileage may vary. :: ::I'm sure someone will correct me if I'm thinking wrong about this. :: ::Best regards, :: ::Randy :: ::[ ... other topics snipped ... ] :: ::_______________________________________________ ::[EMAIL PROTECTED] mailing list ::http://lists.freebsd.org/mailman/listinfo/free::bsd-questions :: ::To unsubscribe, send any mail to ::"[EMAIL PROTECTED]" :: _______________________________________________ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"