How can I update all of my software ?

Installing and maintaining the FreeBSD Ports Collection or FreeBSD Packages (i.e. third party software).

How can I update all of my software ?

Postby chuugar » 13 Jul 2011, 10:16

Hi guys !

So... It is my first message on this forum. :)
Well, I'm a new FreeBSD user (I have got a dual boot with Linux), so I am sorry if my question seems to be... stupid.
How can I update all of my software/dependency ? Because, when I tried to install whatever I need to update 2 or 3 dependency...

I wish I can already say thank you. ;)
(I am French)
chuugar
Junior Member
 
Posts: 4
Joined: 13 Jul 2011, 10:09

Postby SirDice » 13 Jul 2011, 10:19

Try reading the handbook: Chapter 24 Updating and Upgrading FreeBSD

In case English isn't your first language, the handbook is available in other languages too.
Senior UNIX Engineer at Unix Support Nederland
Experience is something you don't get until just after you need it.
User avatar
SirDice
Old Fart
 
Posts: 16185
Joined: 17 Nov 2008, 16:50
Location: Rotterdam, Netherlands

Postby DutchDaemon » 13 Jul 2011, 10:35

Given the subforum this was posted in, I'm assuming this is about ports/packages?

chuugar, you are aware of the strict separation between the base system (FreeBSD kernel and FreeBSD userland) and add-on software (third-party applications, i.e. ports and packages), which are not updated together?

BSD vs Linux

The aforementioned Chapter 24 covers both, but make sure you understand the difference.
User avatar
DutchDaemon
Old Fart
 
Posts: 10466
Joined: 16 Nov 2008, 20:17
Location: The Netherlands

Postby chuugar » 13 Jul 2011, 10:54

No, I am not.
I think that what I have to update is not the kernel, but the applications...
I am going to read the handbook.
chuugar
Junior Member
 
Posts: 4
Joined: 13 Jul 2011, 10:09

Postby wblock@ » 13 Jul 2011, 11:33

User avatar
wblock@
Old Fart
 
Posts: 10212
Joined: 07 Sep 2009, 23:23
Location: Milky Way galaxy

Postby chuugar » 13 Jul 2011, 13:07

I did that:
Code: Select all
portsnap update


And FreeBSD returns me:
Code: Select all
Ports tree is already up to date


What I have to do more ??
chuugar
Junior Member
 
Posts: 4
Joined: 13 Jul 2011, 10:09

Postby SirDice » 13 Jul 2011, 13:40

chuugar wrote:What I have to do more ??


Read [file]/usr/ports/UPDATING[/file] and see which of the ports are out of date.

[cmd=#]pkg_version -vI[/cmd]
Senior UNIX Engineer at Unix Support Nederland
Experience is something you don't get until just after you need it.
User avatar
SirDice
Old Fart
 
Posts: 16185
Joined: 17 Nov 2008, 16:50
Location: Rotterdam, Netherlands

Postby chuugar » 13 Jul 2011, 13:47

A lot of my ports are out of date.
Must I update all of them manually ?
chuugar
Junior Member
 
Posts: 4
Joined: 13 Jul 2011, 10:09

Postby wblock@ » 13 Jul 2011, 14:31

chuugar wrote:A lot of my ports are out of date.
Must I update all of them manually ?


That's a link in post #5.
User avatar
wblock@
Old Fart
 
Posts: 10212
Joined: 07 Sep 2009, 23:23
Location: Milky Way galaxy

Postby SirDice » 13 Jul 2011, 16:26

chuugar wrote:A lot of my ports are out of date.

Which is why you really shouldn't install any of the packages on the CD/DVDs. By the time you get to install the system they'll all be out of date.
Senior UNIX Engineer at Unix Support Nederland
Experience is something you don't get until just after you need it.
User avatar
SirDice
Old Fart
 
Posts: 16185
Joined: 17 Nov 2008, 16:50
Location: Rotterdam, Netherlands

Read the FreeBSD Handbook.

Postby fender0107401 » 17 Jul 2011, 01:39

Read this.

More specifically, read this for your current question.

More and more specifically, read this.
Just be yourself.
User avatar
fender0107401
Member
 
Posts: 301
Joined: 17 Nov 2008, 03:57
Location: China, Beijing.

Postby vb » 17 Jul 2011, 12:00

chuugar wrote:I did that:
Code: Select all
portsnap update


And FreeBSD returns me:
Code: Select all
Ports tree is already up to date


What I have to do more ??


[CMD=" "]portsnap fetch update[/CMD]
[CMD=" "]portupgrade -u -a[/CMD]
vb
Junior Member
 
Posts: 5
Joined: 16 Jul 2011, 07:07

Postby SirDice » 18 Jul 2011, 10:14

vb wrote:[CMD=" "]portupgrade -u -a[/CMD]

Don't! Read the link in post #5.
Senior UNIX Engineer at Unix Support Nederland
Experience is something you don't get until just after you need it.
User avatar
SirDice
Old Fart
 
Posts: 16185
Joined: 17 Nov 2008, 16:50
Location: Rotterdam, Netherlands

Postby vermaden » 18 Jul 2011, 10:46

How can I update all of my software?


(dependencies)
Code: Select all
# pkg_add -r portmaster
# pkg_add -r portaudit


I use two aliases for packages/ports updates:

Code: Select all
alias [color="Blue"][B]ports-check[/B][/color]="[color="Blue"]portsnap[/color] fetch update; [color="blue"]portmaster[/color] -L --index-only | [color="blue"]grep[/color] -i ' new '; [color="blue"]portaudit[/color] -Fda; [color="Blue"]pkg_updating[/color] -d $( [color="blue"]ls[/color] -ltr -D '%Y%m%d' /var/db/pkg | [color="blue"]awk[/color] 'END{print $6}' )"
alias [color="blue"][B]ports-update[/B][/color]="[color="blue"]portmaster[/color] -y --no-confirm -a --packages-if-newer -m 'BATCH=yes' -d; [color="blue"]portmaster[/color] --check-depends"


example output(s):
Code: Select all
# [color="Blue"][B]ports-check        [/B][/color]                       
Looking up portsnap.FreeBSD.org mirrors... 5 mirrors found.
Fetching snapshot tag from portsnap5.freebsd.org... done.
Fetching snapshot metadata... done.
Updating from Mon Jul 18 11:28:48 CEST 2011 to Mon Jul 18 12:16:56 CEST 2011.
Fetching 3 metadata patches.. done.
Applying metadata patches... done.
Fetching 0 metadata files... done.
Fetching 1 patches. done.
Applying patches... done.
Fetching 0 new ports or files... done.
Removing old files and directories... done.
Extracting new files:
/usr/ports/sysutils/bsdadminscripts/
Building new INDEX files... done.
        ===>>> New version available: bsdadminscripts-6.1.1_1
        ===>>> 1 has a new version available
auditfile.tbz                                 100% of   68 kB   59 kBps
New database installed.
Database created: Mon Jul 18 12:35:00 CEST 2011
0 problem(s) in your installed packages found.



Code: Select all
# [color="Blue"][B]ports-update [/B][/color]
===>>> Starting check of installed ports for available updates
===>>> Launching child to update bsdadminscripts-6.1.1 to bsdadminscripts-6.1.1_1

===>>> Port directory: /usr/ports/sysutils/bsdadminscripts

===>>> Gathering dependency list for sysutils/bsdadminscripts from ports
===>>> No dependencies for sysutils/bsdadminscripts
===>>> Returning to update check of installed ports

        ===>>> The sysutils/libgksuui port moved to sysutils/libgksu
        ===>>> Reason: Removed: It is a part of sysutils/libgksu now

===>>> Launching child to reinstall libgksuui-1.0.7_6

        ===>>> The sysutils/libgksuui port moved to sysutils/libgksu
        ===>>> Reason: Removed: It is a part of sysutils/libgksu now

===>>> Port directory: /usr/ports/sysutils/libgksu

===>>> Gathering dependency list for sysutils/libgksu from ports
===>>> Dependency check complete for sysutils/libgksu
===>>> Returning to update check of installed ports
===>>> Starting build and/or install for for ports that need updating <<<===

===>>> Launching child to install sysutils/bsdadminscripts

===>>> Port directory: /usr/ports/sysutils/bsdadminscripts

===>>> Checking package repository for latest available version

===>>> The newest available package (bsdadminscripts-6.1.1)
       is not newer than the installed version (bsdadminscripts-6.1.1)

===>>> There is no valid package to install, building port instead

===>>> Starting check for build dependencies
===>>> Gathering dependency list for sysutils/bsdadminscripts from ports
===>>> No dependencies for sysutils/bsdadminscripts
===>  Cleaning for bsdadminscripts-6.1.1_1

===>  License check disabled, port has not defined LICENSE
=> bsdadminscripts-6.1.1.tar.gz doesn't seem to exist in /usr/ports/distfiles//.
=> Attempting to fetch http://heanet.dl.sourceforge.net/project/bsdadminscripts/bsdadminscripts/bsdadminscripts-6.1.1.tar.gz
bsdadminscripts-6.1.1.tar.gz                  100% of   72 kB  220 kBps
===>  Extracting for bsdadminscripts-6.1.1_1
=> SHA256 Checksum OK for bsdadminscripts-6.1.1.tar.gz.
===>  Patching for bsdadminscripts-6.1.1_1
===>  Applying FreeBSD patches for bsdadminscripts-6.1.1_1
===>  Configuring for bsdadminscripts-6.1.1_1

===>>> Creating a backup package for old version bsdadminscripts-6.1.1

===>>> Starting check for runtime dependencies
===>>> Gathering dependency list for sysutils/bsdadminscripts from ports
===>>> No dependencies for sysutils/bsdadminscripts
===>  Installing for bsdadminscripts-6.1.1_1
===>   Generating temporary packing list
===>  Checking if sysutils/bsdadminscripts already installed
installing: /usr/local/man/man1/bsdadminscripts.1.gz
installing: /usr/local/share/bsdadminscripts/buildflags.awk
installing: /usr/local/etc/buildflags.conf.sample
installing: /usr/local/share/bsdadminscripts/buildflags.mk
installing: /usr/local/man/man1/buildflags.awk.1.gz
installing: /usr/local/man/man1/buildflags.conf.1.gz
installing: /usr/local/man/man1/buildflags.mk.1.gz
installing: /usr/local/sbin/distviper
installing: /usr/local/man/man1/distviper.1.gz
installing: /usr/local/sbin/pkg_libchk
installing: /usr/local/man/man1/pkg_libchk.1.gz
installing: /usr/local/sbin/pkg_upgrade
installing: /usr/local/man/man1/pkg_upgrade.1.gz
installing: /usr/local/sbin/pkg_validate
installing: /usr/local/man/man1/pkg_validate.1.gz
installing: /usr/local/sbin/portconfig
installing: /usr/local/man/man1/portconfig.1.gz
installing: /usr/local/sbin/rcstart
installing: /usr/local/man/man1/rcstart.1.gz
installing: /usr/local/sbin/uma
installing: /usr/local/man/man1/uma.1.gz
installing: /usr/local/etc/uma.conf.sample
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rcstatus
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rcstop
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rcrestart
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rconestart
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rconestatus
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rconestop
hardlinking: /usr/local/sbin/rcstart -> /usr/local/sbin/rconerestart
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portbuild
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portclean
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portfetch
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portpackage
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portconfig-recursive
hardlinking: /usr/local/sbin/portconfig -> /usr/local/sbin/portfetch-recursive
===>   Registering installation for bsdadminscripts-6.1.1_1
===>  Cleaning for bsdadminscripts-6.1.1_1

===>>> Upgrade of bsdadminscripts-6.1.1 to bsdadminscripts-6.1.1_1 succeeded

===>>> Returning to update check of installed ports

===>>> Launching child to install sysutils/libgksu

===>>> Port directory: /usr/ports/sysutils/libgksu

===>>> Checking package repository for latest available version

===>>> Creating a backup package for old version libgksu-2.0.9
pkg_delete: package 'libgksu-2.0.9' is required by these other packages
and may not be deinstalled (but I'll delete it anyway):
gnochm-0.9.11_6
py27-gnome-extras-2.25.3_11

===>>> Starting check for runtime dependencies
===>>> Gathering dependency list for sysutils/libgksu from ports
===>>> Dependency check complete for sysutils/libgksu
===>>> Installing package

===>>> Updating dependencies for libgksu-2.0.9 to match installed versions
===>>> Updating dependency entry for libgksu-2.0.9 in each dependent port
===>>> Re-installation of libgksu-2.0.9 succeeded

===>>> Returning to update check of installed ports

===>>> Update check of installed ports complete

===>>> The following actions were performed:
        Upgrade of bsdadminscripts-6.1.1 to bsdadminscripts-6.1.1_1
        Re-installation of libgksu-2.0.9

(...)
===>>> Checking libgksu-2.0.9
===>>> Checking libgksuui-1.0.7_6
        ===>>> /usr/ports/sysutils/libgksuui does not exist
        ===>>> This port should probably be updated
===>>> Checking libglade2-2.6.4_4
===>>> Checking libglut-7.4.4
(...)
===>>> Checking pcre-8.12
===>>> Checking pdfedit-0.4.5
===>>> Checking perl-5.10.1_3
        ===>>> Updating perl-5.10.1_3/+REQUIRED_BY
===>>> Checking perl-5.12.3
===>>> Checking perl-5.12.4
(...)
Religions, worst damnation of mankind.
"FreeBSD has always been the operating system that GNU/Linux should have been." Frank Pohlmann, IBM
[FILE][color="DarkSlateBlue"]http://vermaden.blogspot.com[/color][/FILE]
User avatar
vermaden
Giant Locked
 
Posts: 2317
Joined: 16 Nov 2008, 19:37
Location: pl_PL.lodz

Postby Kiiski » 19 Jul 2011, 09:40

Of course there is always many ways to do things, but these aliases don't seem to contain checking [FILE]/usr/ports/UPDATING[/FILE]. But that is cladly covered in earlier posts.

Some examples of easing that is covered at least in this thread:
http://forums.freebsd.org/showthread.php?t=25015 in posts #4 and #5.

If you are planning on using aliases, maybe you could consider adding that example to ports-check alias.
User avatar
Kiiski
Junior Member
 
Posts: 55
Joined: 10 Jan 2009, 11:10

Postby vermaden » 19 Jul 2011, 10:19

@Kiiski

Added, thanks ;)
Religions, worst damnation of mankind.
"FreeBSD has always been the operating system that GNU/Linux should have been." Frank Pohlmann, IBM
[FILE][color="DarkSlateBlue"]http://vermaden.blogspot.com[/color][/FILE]
User avatar
vermaden
Giant Locked
 
Posts: 2317
Joined: 16 Nov 2008, 19:37
Location: pl_PL.lodz


Return to Installation and Maintenance of FreeBSD Ports or Packages

Who is online

Users browsing this forum: No registered users and 2 guests