How to upgrade a single product on old FreeBSD 5.3 system

I have an older FreeBSD system (I would like to be on a newer version but it is not my server and I do not have carte blanche to change just anything.)

Code:
------ $ uname -a
FreeBSD [url]www.xxxxxxxxx.com[/url] 5.3-RELEASE-p5 FreeBSD 5.3-RELEASE-p5 #0: Tue Jan 25 11:14:51 UTC 2005 [email]root@www.xxxxxxxxx.com[/email]:/usr/obj/usr/src/sys/GENERIC  i386

The currently installed versions of mysql and php are:

Code:
------ $ pkg_version -v
  ...
cvsup-without-gui-16.1h             =   up-to-date with port
  ...
mysql-client-4.1.5                  <   needs updating (port has 4.1.9)
mysql-server-4.1.5                  <   needs updating (port has 4.1.9)
  ...
php4-ctype-4.3.10_2                 =   up-to-date with port
php4-extensions-1.0                 =   up-to-date with port
php4-mysql-4.3.10_2                 =   up-to-date with port
php4-overload-4.3.10_2              =   up-to-date with port
php4-pcre-4.3.10_2                  =   up-to-date with port
php4-posix-4.3.10_2                 =   up-to-date with port
php4-session-4.3.10_2               =   up-to-date with port
php4-tokenizer-4.3.10_2             =   up-to-date with port
php4-xml-4.3.10_2                   =   up-to-date with port
php4-zlib-4.3.10_2                  =   up-to-date with port
  ...
I would like to upgrade mysql to 5.0.75 or better, and php to 5.2.6, to match an Ubuntu linux server.

From other posts, I see that the way to do this is to:
- update the ports tree to current levels (such as with portsnap or cvsup or csup),
- then perform pkg_delete on the old versions,
- then perform 'make install clean' for the new versions from the appropriate newer version ports directories

Question: Is my FreeBSD 5.3 system too old to perform the specific upgrades I mention above via a ports install (meaning recompile)? The MySQL documentation says 5.x can be installed (recompiled) on FreeBSD 4.x or later. Not sure about php at this moment but I will verify.

Question: Is it reasonable to want to avoid updating the entire ports tree when I really only want to update two or three products? This is a production server so I am trying to change as little as possible at one time.

Question: If it is reasonable to do just a couple products, how do I update the ports collection for just one product at a time? All the examples I see for updating the ports versions seem to update the entire ports tree.

Thank for any help on these questions.
 
Naa it should upgrade it after portsnap or whatever you do. PHP4 to PHP5 can be done as follows.
Code:
portmaster -o /usr/ports/lang/php5 php4-4.4.9 to upgrade php5
replace 4.9 with your current version. If I were you I will run the following commands first:
Code:
portnsap fetch update
portmaster -Da

Once done I will upgrade PHP4 to PHP5. If you are new to this, make backup first.
 
Hi, Thanks but your reply doesn't quite do it for me.

On this FreeBSD 5.3 system, the only tool I appear to have is 'cvsup'. The ports tree /usr/ports/ does not have a 'ports-mgmt' directory, which I believe is where portmaster comes from. (And as for portsnap, I can't even find it in a search of the ports on this web page http://www.freebsd.org/ports/index.html, but that's beside the point right now)

So my question is still, can I use cvsup to upgrade the ports tree to give me more current mysql and php release directories, while leaving the rest of the ports tree contents alone? Then I can do a 'make install' on whichever newer versions of mysql and php I choose?

For example, does the -i option of the 'cvsup' command give me what I am looking for? It refers to updating only those files/directories that match a pattern, maybe like this:
$ cvsup -i "/usr/ports/databases/mysql*" /root/my_supfile_name
or
$ cvsup -i "/usr/ports/lang/php*" /root/my_supfile-name

Or am I just misunderstanding this whole ports upgrade concept? Thanks.
 
LateNiteTV said:
portsnap wasnt in the base system in 5.3
it is now, so thats why you cant find it in ports.

This is straying a little from my original questions, but as long as you brought it up, I understand the portsnap tool would not be in a 5.3 ports installation from a 5.3 CD. However I can't even find it in the freebsd.org webpage that let's you list all ports or search them all. As I mentioned above, go here and see if you can find portsnap: http://www.freebsd.org/ports/index.html. I will eat humble pie if you can show me how to find portsnap at that webpage :(.

My original questions are still about how to use cvsup to update the ports tree ( /usr/ports/ ) so I can do a make on mysql 5.x and php 5.x.x. Thank you.
 
The ports tree is not OS-version dependent. Once a tool gets dropped from the ports tree, it is no longer in any ports tree on any OS version.
 
Sometimes, it is version dependent :) Support for 5.x was dropped back in 2008, AFAIR. You can use RELEASE_5_EOL tag to get what was ports at that time.
 
Sure, good luck finding the outdated versions' tarballs, I guess ..
 
Hmm, if I were asked to do this I would simply say no. Too much trouble.
If I really had to do it, I would set up another machine running the exact same version of the os, install the required ports on that and make packages that I could install on the other machine. Still much hassle.
 
Back
Top