Home > php教程 > php手册 > linux下安装oracle和php环境

linux下安装oracle和php环境

WBOY
Release: 2016-06-13 10:28:08
Original
895 people have browsed it

写的比较粗糙,凑合着看吧!linux下oracle比较繁琐!^0^ 一.Redhat7.2 操作系统的安装: 二.Mysql源码的安装: >groupadd mysql >useradd –g mysql mysql >tar –zxvf mysql-VERSION.tar.gz >cd mysql-VERSION >./configure --prefix=/usr./local/mysql >make >make install >chown –R root /usr/local/mysql >chown –R mysql /usr/local/mysql/var >chgrp -R mysql /usr/local/mysql >cp support-files/my-medium.cnf /etc/my.cnf >cd /usr/local/mysql/bin >./safe_mysqld --user=mysql & 三.Oracle8.1.7的安装: 1. 安装以下软件包: compat-libstdc++-6.2-2.9.0.16 compat-glibc-6.2-2.1.3.2 compat-egcs-c++-6.2-1.1.2.16 compat-libs-6.2-3 compat-egcs-6.2-1.1.2.16 compat-egcs-objc-6.2-1.1.2.16 (在redhat 安装碟Disk1和 Disk2 中有以上软件包) 2. 安装jdk118_v3-glibc-2.1.3.tar.bz2 bunzip2 jdk118_v3-glibc-2.1.3.tar.bz2 tar –xvf jdk_v3-glibc-2.1.3.tar ln –s jdk118_v3 java 3.准备用户环境 Groupadd oinstall Groupadd dba Groupadd oper Useradd oracle –g oinstall –G dba,oper 4. 创建安装目录: mkdir /oracle chown oracle.dba /oracle chmod 775 /oracle 5. 设置环境变量: 在 /etc/profile文件中添加以下内容: OARCLE_BASE=/oracle/app/oracle ORACLE_HOME=/oracle/app/oracle/product/8.1.7 ORALCE_SID=orcl ORA_NLS=/oracle/app/oracle/product/8.1.7/ocommon/nls/admin/data ORA_LANG=”SIMPLIFIED CHINESE” CLASSPATH=.:/oracle/app/oracle/product/8.1.7/jdbc/lib/classes111.zip LD_LIBRARY_PATH=/oracle/app/oracle/product/8.1.7/lib PATH=$PATH:$OACLE_HOME/BIN:$ORACLE_HOME/dbs:/etc Export ORACLE_BASE ORALCE_HOME ORACLE_SID ORA_NLS NLS_LANG LD_IBRARY 查看环境变量: . /etc/profile env|grep oracle 看看oracle 的设置是否正确 在 /home/oracle/.bash_profile 文件中添加如下内容: . /usr/i386-glibc21-linux/bin/i386-glibc21-linux-env.sh export LD_ASSUME_KERNEL=2.2.5 . /home/oracle/.bash_profile gcc –v 查看是否已替换。 6. 安装 退出以oracle用户登录进行安装: >su root >tar -xvf linux1701.tar >cd Disk1 >./runInstaller 进行安装。 一路点击next 此时会弹出窗口提示运行orainstRoot.sh >su >cd $ORACHE_HOME >./orainsRoot.sh 继续安装又弹出对话框要求运行root.sh >cd $ORACLE_HOME >./root.sh exit 安装完毕,打一个oracle 补丁 >cp glibc-2.1.3-stubs.tar.gz $ORACLE_HOME >tar –zxvf glibcs-2.1.3-stubs.tar.gz >./setup_stubs.sh 安装完毕启动oracle >svrmgrl >connect internal >startup >quit 启动侦听窗口: >lsnrctl >start >quit 四.Apache php 的安装 >tar –zxvf apache_1.3.26.tar.gz >tar –zxvf php_4.1.2.tar.gz >cd apache_1.3.26 >./configure --prefix=/usr/local/apace >cd ../php-4.1.2 >./configure --with-mysql –with-apache=/usr/local/apache_1.3.26 --with-oci8=/oracle/app/oracle/product/8.1.7 –with-oracle=/oracle/app/oracle/product/8.1.7 --enable-track-vars >make >make install >cp php.ini-dist /usr/local/lib/php.ini >cd ../apache_1.3.26 >./configure --activate-module=src/modules/php4/libphp4.a >make >make install 启动apache >/usr/local/apache/bin/apachectl start 五.配置apache和php >cd /usr/local/apache/conf >vi httpd.conf 设置成自己想设置的路径。 >cd /usr/local/lib >vi php.ini 配置oracle启动模块。

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template