Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

For example, if the server (CentOS) has PHP 5.2.6 installed and has added a third party repository that provides both PHP 5.2.12 and PHP 5.3.1.

PHP 5.2.12 and PHP 5.3.1 are the latest versions for PHP 5.2 and PHP 5.3 respectively.

When yum update command runs, will yum simply upgrade PHP 5.2.6 to PHP 5.3.1?

Or it has some intelligence that a major upgrade (5.2 to 5.3) may cause problems and thus to be safe, it decides to upgrade to PHP 5.2.12 instead?

By the way, will a repository contain multiple versions of a package, or it only contains the latest version?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

If you are using the remi repos there's a lot of help here - I used this upgrading Fedora 6:

yum --enable remi --exclude=mysql-libs install php

Although more generally, all you need is

yum upgrade php

Or for a specific version, remove .i386 etc, add a hyphen then add the version

yum install php-5.3.1-1.fc6.remi

Alternatively

yum check-update

Will show you all packages and

yum update --exclude=kernel

Will update everything except kernel packages etc

By the way, will a repository contain multiple versions of a package, or it only contains the latest version?

Generally the maintainer will only provide the latest version, however it's possible to have more than one version in a repository.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.