LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-04-2018, 07:12 AM   #1
arrals.vl
Member
 
Registered: May 2012
Posts: 48

Rep: Reputation: Disabled
Cannot install PHP OCI8 for oracle DB


Dear all,

Please would you help me installing oci8 for PHP 5.1.6,
on a CentOS release 5.9.

I have installed oracle clients, and download oci8-1.4.10.tgz.
I have unzipped the file, but there is not a configure script inside the folder and when i try to run:

./configure --with-oci8=instantclient,/usr/lib/oracle/10.2.0.5/client64/lib

it says:
-bash: ./configure: No such file or directory

Please, any help???
 
Old 10-04-2018, 07:58 AM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,636

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by arrals.vl View Post
Dear all,
Please would you help me installing oci8 for PHP 5.1.6, on a CentOS release 5.9.

I have installed oracle clients, and download oci8-1.4.10.tgz. I have unzipped the file, but there is not a configure script inside the folder and when i try to run:

./configure --with-oci8=instantclient,/usr/lib/oracle/10.2.0.5/client64/lib

it says:
-bash: ./configure: No such file or directory
Then you're either not in the right directory, or you didn't unzip things. There are how-to guides for installation:
https://www.orware.com/blog/tips-and...p-installation

But a couple of things stand out:
  • CentOS 5.9 is VERY old, and totally unsupported. No updates any longer; you really need to use a newer version
  • The latest version of oci8 is 2.1.8...and you're installing 1.4.10?
  • Did you download the package.xml file?
  • Run 'pecl build'?
  • Compile PHP with the oci8 extensions (which is the part where you run the './configure'???)
 
1 members found this post helpful.
Old 10-04-2018, 08:32 AM   #3
arrals.vl
Member
 
Registered: May 2012
Posts: 48

Original Poster
Rep: Reputation: Disabled
Dear TB0ne,

- This machine is very Old in fact, but we run several applications there, and for the moment i cannot do anything about this.
- I download 1.4.10 because we already use it in another old machine, but i have download now 2.1.8 as per your suggestion.
- Yes, i have download the package.xml file, but when should i put that? Inside oci8_2.1.8 folder?
- I haven't run pecl build , because pecl is not installed, and i am finding it difficult to install as yum doesn't seems to get working, and i am installing things manually.
 
Old 10-04-2018, 09:52 AM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,636

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by arrals.vl View Post
Dear TB0ne,
- This machine is very Old in fact, but we run several applications there, and for the moment i cannot do anything about this.
You really do need to upgrade, so mentioning that to your bosses would be a good idea.
Quote:
- I download 1.4.10 because we already use it in another old machine, but i have download now 2.1.8 as per your suggestion.
Using the latest packages is usually a good idea.
Quote:
- Yes, i have download the package.xml file, but when should i put that? Inside oci8_2.1.8 folder?
Did you read the instructions?
Quote:
- I haven't run pecl build , because pecl is not installed, and i am finding it difficult to install as yum doesn't seems to get working, and i am installing things manually.
Again, did you read the instructions? You were given a link with detailed steps, that tell you what to copy where, and what procedures to run. Unless you follow them, things won't work.

yum probably *WON'T* work, since (again) CentOS 5.9 is old, and out of support. The production repositories are gone.
 
1 members found this post helpful.
Old 10-04-2018, 02:34 PM   #5
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 4,864
Blog Entries: 1

Rep: Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869
Compiling from source is not easy (except for trivial, dependency-less cases). Maybe this site might give some hints: http://www.linuxfromscratch.org
 
Old 10-04-2018, 07:34 PM   #6
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Quote:
Originally Posted by arrals.vl View Post
- This machine is very Old in fact, but we run several applications there, and for the moment i cannot do anything about this.
- I download 1.4.10 because we already use it in another old machine, but i have download now 2.1.8 as per your suggestion.
- Yes, i have download the package.xml file, but when should i put that? Inside oci8_2.1.8 folder?
- I haven't run pecl build , because pecl is not installed, and i am finding it difficult to install as yum doesn't seems to get working, and i am installing things manually.
While agreeing with others that you should upgrade, here's what you need to do to use yum
on that old version:

In the directory /etc/yum.repos.d/ there are files beginning with CentOS-
Those contain the paths to the repos
Code:
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
#~ baseurl=http://mirror.centos.org/centos/5.11/$basearch/
baseurl=http://vault.centos.org/5.11/os/$basearch/
You'll need to comment out the mirrorlist entry, copy the baseurl line, comment the old one out and change the new one to use the vault instead of the mirror.
My example is from a box running 5.11. Yours will probably say 5.9. Note also the other differences

Do this for every such entry in every CentOS-* file

The versions of software in the vault for 5.9 are what they were when version 5 went end-of-life. They will not contain newer version of anything, nor should you try to use newer versions.

HTH

Last edited by scasey; 10-04-2018 at 07:35 PM.
 
Old 10-04-2018, 08:49 PM   #7
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Quote:
Originally Posted by arrals.vl View Post
Dear all,

Please would you help me installing oci8 for PHP 5.1.6,
on a CentOS release 5.9.

I have installed oracle clients, and download oci8-1.4.10.tgz.
I have unzipped the file, but there is not a configure script inside the folder and when i try to run:

./configure --with-oci8=instantclient,/usr/lib/oracle/10.2.0.5/client64/lib

it says:
-bash: ./configure: No such file or directory
And to the specifics of your OP. Not all source compiles have/require a configure step. That one obviously doesn't.

Is there a README file or an INSTALL file? Did you read those?
 
Old 10-05-2018, 06:03 AM   #8
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,636

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by scasey View Post
And to the specifics of your OP. Not all source compiles have/require a configure step. That one obviously doesn't. Is there a README file or an INSTALL file? Did you read those?
No, they did not. There is an XML file you have to copy, then run a command that generates the configure file. And all that aside, the OP will have to re-compile PHP from source in order to get this to work, since they're using unsupported CentOS 5.x.
 
Old 10-05-2018, 07:09 AM   #9
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 4,864
Blog Entries: 1

Rep: Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869
Well, one could start with building a complete php, that already includes oci8 (directory ext/oci8), but it has infinite number of dependencies (not all mandatory, mind you). But that's not for beginners.
 
Old 10-05-2018, 06:33 PM   #10
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Looks like php 5.1.6 is in the vault for 5.11
Code:
php.i386                                                         5.1.6-45.el5_11
Looks like it's there for CentOS 5.9 too.

Again, I'm not disagreeing about needing to upgrade...but I happened to have been in the same boat a few months back. Got caught by the EOL on version 5. Found and followed directions on centos.org on how to use the vault until I managed an upgrade. I didn't actually need it much, since it was a production server that was current when the repos died, but it is possible to add software from the vault after EOL.

It is important to note (again!) that the software won't be current and can't be updated, but it will install and run on the old server. As has been noted, compiling php from source is likely to be very difficult, and may not work at all.

Last edited by scasey; 10-05-2018 at 06:34 PM.
 
1 members found this post helpful.
Old 10-05-2018, 08:31 PM   #11
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
My apologies. While my suggestions about changing the yum repositories to use the vault will allow yum to install software, neither oci8 or pecl appear to be in the vault, nor does pecl exist on the old 5.11 box I've been looking at. I got lost checking out PHP.

Sorry to have mislead anyone.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to change local value and master value oci8.ping_interval (oci8) in php. greenworld Linux - Server 0 05-22-2012 08:45 AM
compiling oci8 and php 5.3.6 Ernesty Linux - Newbie 1 07-14-2011 09:08 AM
php-oci8 installation fernfrancis Linux - Newbie 1 12-14-2010 03:40 AM
Debian AMD64 Oracle 10g XE and PHP OCI8 he_the_great Linux - Software 0 01-24-2009 12:32 PM
php with oci8 nightmare mariogomide Programming 1 01-31-2006 10:51 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:54 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration