How to compile and install php on redhat enterprise linux5

Hi

Please let me know how to compile and install php on redhat enterprise linux 5. I need to install PHP with the modules like “php5 php5-mhash php5-mcrypt php5-curl php5-cli php5-mysql php5-gd php-xml” when i use yum it is show the message as

“yum install php-xml
Loading “installonlyn” plugin
Loading “rhnplugin” plugin
This system is not registered with RHN.
RHN support will be disabled.
Setting up repositories
No Repositories Available to Set Up
Reading repository metadata in from local files
Setting up repositories
No Repositories Available to Set Up
Reading repository metadata in from local files
No Matches found”

Please help me …

Thanks
Kiran

PHP5 is not available on other repositories for that you need a special type of repositories known as Webtatic REPO for EL5

# wget http://mirror.webtatic.com/yum/el5/latest.rpm

# rpm -ivh latest.rpm

# yum clean all

# yum upgrade

# yum install php5*

Thats all…

Hii Thanks for the reply I am struck at this point please help me.

[root@androidajay opt]# rpm -ivh latest.rpm
warning: latest.rpm: Header V4 DSA signature: NOKEY, key ID cf4c4ff9
Preparing… ########################################### [100%]
file /etc/yum.repos.d/webtatic-archive.repo from install of webtatic5-release-5.1-5 conflicts with file from package webtatic5-release-5.1-4
file /etc/yum.repos.d/webtatic-el5.repo from install of webtatic5-release-5.1-5 conflicts with file from package webtatic5-release-5.1-4
file /etc/yum.repos.d/webtatic-testing.repo from install of webtatic5-release-5.1-5 conflicts with file from package webtatic5-release-5.1-4

Hii
Resolved conflicts by removing previous version but getting below issues while following above step.

[root@androidajay opt]# rpm -ivh latest.rpm
warning: latest.rpm: Header V4 DSA signature: NOKEY, key ID cf4c4ff9
Preparing… ########################################### [100%]
package webtatic5-release-5.1-5 is already installed

[root@androidajay opt]# yum clean all
Loading “installonlyn” plugin
Loading “rhnplugin” plugin
This system is not registered with RHN.
RHN support will be disabled.
Cleaning up Everything

[root@androidajay opt]# yum upgrade
Loading “installonlyn” plugin
Loading “rhnplugin” plugin
This system is not registered with RHN.
RHN support will be disabled.
Setting up Upgrade Process
Setting up repositories
Traceback (most recent call last):
File “/usr/bin/yum”, line 29, in ?
yummain.main(sys.argv[1:])
File “/usr/share/yum-cli/yummain.py”, line 102, in main
result, resultmsgs = do()
File “/usr/share/yum-cli/cli.py”, line 359, in doCommands
return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd, self.extcmds)
File “/usr/share/yum-cli/yumcommands.py”, line 353, in doCommand
return base.updatePkgs(extcmds)
File “/usr/share/yum-cli/cli.py”, line 628, in updatePkgs
self.doRepoSetup()
File “/usr/share/yum-cli/cli.py”, line 102, in doRepoSetup
yum.YumBase.doRepoSetup(self, thisrepo=thisrepo)
File “/usr/lib/python2.4/site-packages/yum/init.py”, line 299, in doRepoSetup
repo.setup(self.conf.cache)
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 497, in setup
self.baseurlSetup()
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 337, in baseurlSetup
mirrorurls = getMirrorList(self.mirrorlist, self.proxy_dict)
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 692, in getMirrorList
fo = urlresolver.urlopen(url, proxies=pdict)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 605, in urlopen
return default_grabber.urlopen(url, **kwargs)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 884, in urlopen
return self._retry(opts, retryfunc, url)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 845, in _retry
r = apply(func, (opts,) + args, {})
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 883, in retryfunc
return URLGrabberFileObject(url, filename=None, opts=opts)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1001, in init
self._do_open()
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1072, in _do_open
fo, hdr = self._make_request(req, opener)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1172, in _make_request
fo = opener.open(req)
File “/usr/lib/python2.4/urllib2.py”, line 358, in open
response = self._open(req, data)
File “/usr/lib/python2.4/urllib2.py”, line 376, in _open
‘_open’, req)
File “/usr/lib/python2.4/urllib2.py”, line 337, in _call_chain
result = func(args)
File “/usr/lib/python2.4/site-packages/M2Crypto/m2urllib2.py”, line 66, in https_open
h.request(req.get_method(), req.get_full_url(), req.data, headers)
File “/usr/lib/python2.4/httplib.py”, line 804, in request
self._send_request(method, url, body, headers)
File “/usr/lib/python2.4/httplib.py”, line 827, in _send_request
self.endheaders()
File “/usr/lib/python2.4/httplib.py”, line 798, in endheaders
self._send_output()
File “/usr/lib/python2.4/httplib.py”, line 679, in _send_output
self.send(msg)
File “/usr/lib/python2.4/httplib.py”, line 646, in send
self.connect()
File “/usr/lib/python2.4/site-packages/M2Crypto/httpslib.py”, line 47, in connect
self.sock.connect((self.host, self.port))
File “/usr/lib/python2.4/site-packages/M2Crypto/SSL/Connection.py”, line 159, in connect
if not check(self.get_peer_cert(), self.addr[0]):
File “/usr/lib/python2.4/site-packages/M2Crypto/SSL/Checker.py”, line 86, in call
fieldName=‘subjectAltName’)
M2Crypto.SSL.Checker.WrongHost: Peer certificate subjectAltName does not match host, expected mirror.webtatic.com, got DNS:
.webtatic.com, DNS:webtatic.com, DNS:.repo.webtatic.com, DNS:andytson.com, DNS:.andytson.com


[root@androidajay opt]# yum install php*
Loading “installonlyn” plugin
Loading “rhnplugin” plugin
This system is not registered with RHN.
RHN support will be disabled.
Setting up Install Process
Setting up repositories
Traceback (most recent call last):
File “/usr/bin/yum”, line 29, in ?
yummain.main(sys.argv[1:])
File “/usr/share/yum-cli/yummain.py”, line 102, in main
result, resultmsgs = do()
File “/usr/share/yum-cli/cli.py”, line 359, in doCommands
return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd, self.extcmds)
File “/usr/share/yum-cli/yumcommands.py”, line 134, in doCommand
return base.installPkgs(extcmds)
File “/usr/share/yum-cli/cli.py”, line 509, in installPkgs
self.doRepoSetup()
File “/usr/share/yum-cli/cli.py”, line 102, in doRepoSetup
yum.YumBase.doRepoSetup(self, thisrepo=thisrepo)
File “/usr/lib/python2.4/site-packages/yum/init.py”, line 299, in doRepoSetup
repo.setup(self.conf.cache)
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 497, in setup
self.baseurlSetup()
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 337, in baseurlSetup
mirrorurls = getMirrorList(self.mirrorlist, self.proxy_dict)
File “/usr/lib/python2.4/site-packages/yum/yumRepo.py”, line 692, in getMirrorList
fo = urlresolver.urlopen(url, proxies=pdict)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 605, in urlopen
return default_grabber.urlopen(url, **kwargs)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 884, in urlopen
return self._retry(opts, retryfunc, url)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 845, in _retry
r = apply(func, (opts,) + args, {})
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 883, in retryfunc
return URLGrabberFileObject(url, filename=None, opts=opts)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1001, in init
self._do_open()
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1072, in _do_open
fo, hdr = self._make_request(req, opener)
File “/usr/lib/python2.4/site-packages/urlgrabber/grabber.py”, line 1172, in _make_request
fo = opener.open(req)
File “/usr/lib/python2.4/urllib2.py”, line 358, in open
response = self._open(req, data)
File “/usr/lib/python2.4/urllib2.py”, line 376, in _open
‘_open’, req)
File “/usr/lib/python2.4/urllib2.py”, line 337, in _call_chain
result = func(args)
File “/usr/lib/python2.4/site-packages/M2Crypto/m2urllib2.py”, line 66, in https_open
h.request(req.get_method(), req.get_full_url(), req.data, headers)
File “/usr/lib/python2.4/httplib.py”, line 804, in request
self._send_request(method, url, body, headers)
File “/usr/lib/python2.4/httplib.py”, line 827, in _send_request
self.endheaders()
File “/usr/lib/python2.4/httplib.py”, line 798, in endheaders
self._send_output()
File “/usr/lib/python2.4/httplib.py”, line 679, in _send_output
self.send(msg)
File “/usr/lib/python2.4/httplib.py”, line 646, in send
self.connect()
File “/usr/lib/python2.4/site-packages/M2Crypto/httpslib.py”, line 47, in connect
self.sock.connect((self.host, self.port))
File “/usr/lib/python2.4/site-packages/M2Crypto/SSL/Connection.py”, line 159, in connect
if not check(self.get_peer_cert(), self.addr[0]):
File “/usr/lib/python2.4/site-packages/M2Crypto/SSL/Checker.py”, line 86, in call
fieldName=‘subjectAltName’)
M2Crypto.SSL.Checker.WrongHost: Peer certificate subjectAltName does not match host, expected mirror.webtatic.com, got DNS:
.webtatic.com, DNS:webtatic.com, DNS:.repo.webtatic.com, DNS:andytson.com, DNS:.andytson.com
[root@androidajay opt]#