电脑桌面
添加小米粒文库到电脑桌面
安装后可以在桌面快捷访问

人力资源-redhat搭建PHP运行环境LAMPVIP免费

人力资源-redhat搭建PHP运行环境LAMP_第1页
1/13
人力资源-redhat搭建PHP运行环境LAMP_第2页
2/13
人力资源-redhat搭建PHP运行环境LAMP_第3页
3/13
REDHATENTERPRISELINUX搭建PHP运行环境搭建一个论坛,以discuz为模板,RedHat为系统,阿帕奇为web服务器,搭建PHP环境,后台为MySQL数据库,即时下流行的“LAMP”。Discuz_7.2_FULL_SC_UTF8mysql-5.0.22-2.1httpd-2.2.3-6.el5php-5.1.6-5.el51、PHP的运行是在阿帕奇服务之上的,首先要安装httpd服务[root@localhost~]#clear[root@localhost~]#rpm-qa|grephttpd[root@localhost~]#mount/dev/cdrom/mnt/cdrom[root@localhost~]#yuminstall-yhttpd重启httpd服务,测试阿帕奇服务器:阿帕奇测试页:2、安装PHP解释器:默认安装后,再次查询会显示以下组件:[root@localhost~]#rpm-qa|grepphpphp-common-5.1.6-5.el5php-5.1.6-5.el5php-cli-5.1.6-5.el5[root@localhost~]#还需要一个rpm包,来支持php与MySQL数据库包名为php-mysql编辑php配置文件:[root@localhost~]#vi/etc/httpd/conf.d/php.conf增加拓展名为.php文件的处理关系测试PHP环境:在Apache主目录/var/www/html中建立一个名为test.php文件文件内容如下:重启httpd服务测试:3、安装MySQL数据库,为安装起见,并修改数据库密码为123[root@localhost~]#yuminstall–ymysql*[root@localhost~]#rpm–qa|grepmysql启动MySQL数据库:[root@localhost~]#servicemysqldstart初始化MySQL数据库:InstallingallpreparedtablesFillhelptablesTostartmysqldatboottimeyouhavetocopysupport-files/mysql.servertotherightplaceforyoursystemPLEASEREMEMBERTOSETAPASSWORDFORTHEMySQLrootUSER!Todoso,starttheserver,thenissuethefollowingcommands:/usr/bin/mysqladmin-urootpassword'new-password'/usr/bin/mysqladmin-uroot-hlocalhost.localdomainpassword'new-password'Seethemanualformoreinstructions.YoucanstarttheMySQLdaemonwith:cd/usr;/usr/bin/mysqld_safe&YoucantesttheMySQLdaemonwiththebenchmarksinthe'sql-bench'directory:cdsql-bench;perlrun-all-testsPleasereportanyproblemswiththe/usr/bin/mysqlbugscript!ThelatestinformationaboutMySQLisavailableonthewebathttp://www.mysql.comSupportMySQLbybuyingsupport/licensesathttp://shop.mysql.com[确定]启动MySQL:[确定]修改密码:[root@localhost~]#mysqladmin-urootpassword123登陆数据库:查看数据库:4、搭建samba服务,将discuz安装程序目录upload放到/var/www/html/下如果samba配置没错误,但是仍然无法将安装文件复制到linux中,请将selinux设置为允许,同时在iptables中放行相关端口修改upload目录中相关目录权限:以下这些目录及文件需要可读写权限./config.inc.php./templates./attachments./forumdata./forumdata/cache./forumdata/templates./forumdata/threadcaches./forumdata/logs./uc_client/data/cache/5、开始安装:在浏览器中输入:http://192.168.2.2/upload/install/根据提示进行安装环境以及文件目录权限检查:填写数据库信息:数据库用户名:默认为username修改为root数据库密码:123Admin密码:在此设置为admin其他根据情况填写直至安装完成后跳转到论坛首页:我们再来看一下MySQL数据库:[root@localhostinstall]#mysql-uroot-pEnterpassword:WelcometotheMySQLmonitor.Commandsendwith;or\g.YourMySQLconnectionidis52toserverversion:5.0.22Type'help;'or'\h'forhelp.Type'\c'toclearthebuffer.mysql>showdatabases;+--------------------+|Database|+--------------------+|information_schema||discuz||mysql||test|+--------------------+4rowsinset(0.00sec)mysql>usediscuzReadingtableinformationforcompletionoftableandcolumnnamesYoucanturnoffthisfeaturetogetaquickerstartupwith-ADatabasechangedmysql>showtables;+-------------------------+|Tables_in_discuz|+-------------------------+|cdb_access||cdb_activities||cdb_activityapplies||cdb_addons||cdb_adminactions||cdb_admincustom||cdb_admingroups||cdb_adminnotes||cdb_adminsessions||cdb_advertisements||cdb_announcements||cdb_attachme...

1、当您付费下载文档后,您只拥有了使用权限,并不意味着购买了版权,文档只能用于自身使用,不得用于其他商业用途(如 [转卖]进行直接盈利或[编辑后售卖]进行间接盈利)。
2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。
3、如文档内容存在违规,或者侵犯商业秘密、侵犯著作权等,请点击“违规举报”。

碎片内容

人力资源-redhat搭建PHP运行环境LAMP

确认删除?
VIP
微信客服
  • 扫码咨询
会员Q群
  • 会员专属群点击这里加入QQ群
客服邮箱
回到顶部