Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Dec 2008 11:08:44 +0100 (CET)
From:      Pieter Donche <Pieter.Donche@ua.ac.be>
To:        "mail.list freebsd-questions" <freebsd-questions@freebsd.org>
Subject:   portsnap and portupgrade
Message-ID:  <Pine.GSO.4.63.0812181105160.2794@hmacs.cmi.ua.ac.be>

next in thread | raw e-mail | index | archive | help
If one installed a fresh FREEBSD-7.0-RELEASE on a new computer,
with 'yes' to installing the Ports Collection during sysinstall,
and opts for portsnap as the tool to keep /usr/ports updated in the future,
and opts for portupgrade to upgrade ports
then,
what is the correct procedure to do after FreeBSD is installed and
up and running, and installing and updating particular ports in the 
following years...

This is what I collected from the FreeBSD handbook, but am not sure
if everything is OK. Please verify and adapt and tell why some things
are wrong and why your corrections are the right thing to do.. 
I'm trying to make a text for future reference ...

( After install of FreeBSD, /var/db/portsnap is still empty, so
   I get compressed snapshot of the Ports collection )
# portsnap fetch

( decompress to /usr/ports )
# portsnap extract

( it is not clear to me if this is correct if one already has a /usr/ports
created during sysinstall .. )

In root /etc/crontab, shedule daily updates of /var/db/portsnap :
0 3 * * * root /usr/sbin/portsnap cron

- For a first install + subsequent updates of a port
( e.g. port  ghostview (gv)  in /usr/ports/print/gv )

a. To install  gv  for the very first time:
# cd /usr/ports/print/gv
# make install clean
# pkg_info | grep -i gv    (to see its version number)


b. For every future upgrade of  gv  (using portupgrade):
b.1. ( update ports collection )
# portsnap update

b.2. check http://vuxml.freebsd.org/ for possible security issues related to gv

b.3. check if gv needs updating
# pkg_version -v  | grep -i gv
   (let's suppose it does: u.v.w. greater than x.y.z.)
gv-x.y.z               <   needs updating (port has gv-u.v.w)

b.4. check /usr/ports/UPDATING for issues related to  gv
and follow instructions if any

b.5. do the port upgrade
# portupgrade -R gv

b.6. install the updated version of ghostview 
# cd /usr/ports/print/gv
# make install clean

b.7. check you have the newer version of gv now
# pkg_info | grep -i gv




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.4.63.0812181105160.2794>