0

A beginner here , trying to install / update PHP in my CentOS (virtual machine).

Existing PHP version : 5.3

Need to update to : 5.5+

I tried a lot of things, may be not enough but I am unable to reach to the conclusion.

I even tried

yum update 

I got the following error:

Loaded plugins: fastestmirror, refresh-packagekit, security Setting up Install Process Error: File contains no section headers. file: file:///etc/yum.repos.d/remi-php56.repo, line: 1 "name=Remi's PHP 5.6 RPM repository for Enterprise Linux 6 - x86_64\n"

I checked the file and this is the first line in the file

name=Remi's PHP 5.6 RPM repository for Enterprise Linux $releasever - $basearch 

Getting the above error for all the methods I tried. Losing brains now. Pleas help! Thank you.

2
  • this is the only repo for rpm PHP 5.6 ? perhaps test other... Commented Dec 28, 2015 at 9:06
  • I am afraid this is the only repository, the other is remi-php70 but I am unsure about that Commented Dec 28, 2015 at 9:19

3 Answers 3

1

it seem to be a syntax error. Read this and proceed with example file : syntax error repo

perhaps solve your problem

Sign up to request clarification or add additional context in comments.

1 Comment

the link you provided did not help, but you did point me in the right direction. Thanks !
0

I don't known where the /etc/yum.repos.d/remi-php56.repo file comes from.

$ rpm -ql remi-release /etc/pki/rpm-gpg/RPM-GPG-KEY-remi /etc/yum.repos.d/remi-php70.repo /etc/yum.repos.d/remi-safe.repo /etc/yum.repos.d/remi.repo 

Please use the remi-release package matching your CentOS version (it seems you are trying to use a fedora one)

You can also follow the information given by the wizard: http://rpms.remirepo.net/wizard/

Comments

0

I was able to update. Edited the repo file and added

[epel] 

on first line.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.