Solved

How to access which repository

Posted on 2011-03-02
20
424 Views
Last Modified: 2012-05-12
I am not very much experienced with Linux installation, but on my VPS (Centos) we have now  installed PEAR and the PEAR package. We also wanted to install PECL but we need the phpize program to load it.
However we cannot find the php-devel package (or PHP5-dev) 'Package not found it says. Please advise what to do now.
0
Comment
Question by:TheoRichel
  • 10
  • 7
  • 3
20 Comments
 
LVL 4

Expert Comment

by:jlar310
Comment Utility
Contact your VPS provider. They may be limiting the packages available for you to install.
0
 
LVL 4

Expert Comment

by:jlar310
Comment Utility
Have you tried the command:

yum list "php*"

php-devel should be in the base or updates repository, unless, as previously mentioned, your VPS provider is only giving  you access to a subset of the full repositories.
0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
have you tried
yum install php-devel

and then

pear install pecl/ExtensionName

Open in new window

0
 

Author Comment

by:TheoRichel
Comment Utility
Gentlemen, thank you
The suggestion to contact my VPS provider is a good one. However I cannot think of a reason why pear and pecl are available and not this one. However I'll try.

Yes I have tried yum list php, but it was no use.

Nasirbest yum install php-devel ends with nothing to do because it cannot find the files in de repository.

We had already installed pear and that went allright though it couldn t load for lack of phpize, thats was when the need for php devel came up.

Meanwhile I have made things wors. After searching a Centos forum  someone suggested in a similar thread to look into  /etc/yum.repos.d/CentOS-Base.
I did that and discovered that inthere was a line I should uncomment to access a base-url. I tried to do that, but VI is not MS Word and so I managed to ruin that file. When I now open it, it is largely empty.

That is the current state of affairs.
Maybe it is wise to first restore that file and try then to check for that devel file.
But I'll await your suggestions.
0
 
LVL 4

Expert Comment

by:jlar310
Comment Utility
yum databases could be corrupt, try

yum clean all
yum install php-devel
0
 

Author Comment

by:TheoRichel
Comment Utility
Then I get: No package php-devel available. Nothing to do.
0
 

Author Comment

by:TheoRichel
Comment Utility
Total result here:
[root@vps /]# yum clean all
Loaded plugins: fastestmirror
Cleaning up Everything
Cleaning up list of fastest mirrors
[root@vps /]# yum install php-devel
Loaded plugins: fastestmirror
Determining fastest mirrors
 * addons: mirror.rackspace.com
 * base: mirrors.greenmountainaccess.net
 * extras: hpc.arc.georgetown.edu
 * updates: centos.mirror.nac.net
addons                                                   |  951 B     00:00
addons/primary                                           |  202 B     00:00
base                                                     | 2.1 kB     00:00
base/primary_db                                          | 1.6 MB     00:00
extras                                                   | 2.1 kB     00:00
extras/primary_db                                        | 181 kB     00:00
updates                                                  | 1.9 kB     00:00
updates/primary_db                                       | 915 kB     00:00
Excluding Packages in global exclude list
Finished
Setting up Install Process
No package php-devel available.
Nothing to do
0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
whenever you have difficulties in normal installation of any required package you can try manually with rpm command, for this first find out your required rpm package from http://rpm.pbone.net/, copy final download address. got ssh prompt of vps and enter following command (replace rpm url with you own if you have different version, php version and architecture must be same)


cd /tmp
wget 'ftp://ftp.pbone.net/mirror/rpms.famillecollet.com/fedora/10/olds/i386/php-devel-5.2.10-1.fc10.remi.i386.rpm'
rpm -ivh php-devel-5.2.10-1.fc10.remi.i386.rpm

OR install directly

rpm -ivh 'ftp://ftp.pbone.net/mirror/rpms.famillecollet.com/fedora/10/olds/i386/php-devel-5.2.10-1.fc10.remi.i386.rpm'

Open in new window

0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
and for damaged yum repository you can reinstall it via but please be carefull about your system architecture (32bit or 64bit) here is 32bit

wget 'ftp://ftp.chg.ru/.0/Linux/CentOS/5.5/os/i386/CentOS/centos-release-5-5.el5.centos.i386.rpm'
rpm -ivh centos-release-5-5.el5.centos.i386.rpm

Open in new window

0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
As per discussion it seems that you are using a "managed vps". it is real panic to upgrade / customize such a system. to avoid such a situation they normally disable potential packages from yum. you can check your /etc/yum.conf for "exclude" tag.

0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 

Author Comment

by:TheoRichel
Comment Utility
Here is my yum.conf it looks like this package is excluded doesnt it?
[main]
cachedir=/var/cache/yum
keepcache=1
debuglevel=2
logfile=/var/log/yum.log
pkgpolicy=newest
distroverpkg=redhat-release
tolerant=1
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
metadata_expire=1800

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=apache* httpd* mod_* mysql* MySQL* da_* *ftp* exim* sendmail* php* bind-chroot*
~
~
~
~
~

0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
OK, keep your yum.conf as it is. and install php-devel via rpm method
0
 

Author Comment

by:TheoRichel
Comment Utility
OK, If I search that location for Centos and php devel I get this, which one should I take? I am on PHP 5.2.16 (http://www.groenerekenkamer.nl/admin/reports/status/php ):
      
Search results for php-devel :
Other       ftp.rpmhelp.net/pub/releases/1.0-CURRENT/i586/RPMS/php432-devel-4.3.4-3sls.i586.rpm
Other       rpms.famillecollet.com/enterprise/6/remi/x86_64/php-devel-5.3.5-1.el6.remi.x86_64.rpm
Other       rpms.famillecollet.com/enterprise/6/remi/i386/php-devel-5.3.5-1.el6.remi.i686.rpm
Other       rpms.famillecollet.com/enterprise/6/remi/x86_64/php-devel-5.3.4-1.el6.remi.x86_64.rpm
Other       rpms.famillecollet.com/enterprise/6/remi/i386/php-devel-5.3.4-1.el6.remi.i686.rpm
CentOS 5       ftp.centos.org/5.5/updates/x86_64/RPMS/php-devel-5.1.6-27.el5_5.3.x86_64.rpm
CentOS 5       ftp.centos.org/5.5/updates/i386/RPMS/php-devel-5.1.6-27.el5_5.3.i386.rpm
CentOS 5       ftp.centos.org/5.5/os/x86_64/CentOS/php-devel-5.1.6-27.el5.x86_64.rpm
CentOS 5       ftp.centos.org/5.5/os/i386/CentOS/php-devel-5.1.6-27.el5.i386.rpm
0
 

Author Comment

by:TheoRichel
Comment Utility
And: how do I check if I am on 32 or 64 bit . I can as the host of course, but that takes a long time.
0
 
LVL 6

Expert Comment

by:nasirbest
Comment Utility
check output of following command
uname -a

Open in new window

0
 

Author Comment

by:TheoRichel
Comment Utility

Linux vps.klimatosoof.nl 2.6.18-194.26.1.el5xen #1 SMP Tue Nov 9 14:13:46 EST 2010 i686 i686 i386 GNU/Linux


Sounds like 32 bit

That leaves:
CentOS 5       ftp.centos.org/5.5/updates/i386/RPMS/php-devel-5.1.6-27.el5_5.3.i386.rpm
CentOS 5       ftp.centos.org/5.5/os/i386/CentOS/php-devel-5.1.6-27.el5.i386.rpm

I suppose I should take the last one.
0
 
LVL 6

Accepted Solution

by:
nasirbest earned 500 total points
Comment Utility
you can google for your desired rpm with "rpm php-devel-5.2.16" i have got following
http://www.jasonlitka.com/media/EL5/i386/php-devel-5.2.16-jason.1.i386.rpm

Open in new window

0
 

Author Comment

by:TheoRichel
Comment Utility
I am still working on this but other problems disallow me to continue now,please give me some more time
0
 

Author Comment

by:TheoRichel
Comment Utility
Well I have switched to another VPS-host meanwhile and this server does what we want without installing extra software. My apologies for letting this question hang so long.
0
 

Author Closing Comment

by:TheoRichel
Comment Utility
I am convinced that Nasirbest is highly knowledgeable in this field, although in the end I bypassed his solutions because of a switch to another VPS.

Thanks
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now