LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 04-30-2004, 04:21 AM   #1
ashokn
LQ Newbie
 
Registered: Apr 2004
Location: mumbai
Posts: 7

Rep: Reputation: 0
how do i install apache php and mysql


Hello,
I am new to linux. I have installed rh9. rh9 comes with apache 2.0.40 php 4.2.2 and mysql 3.23. I want to upgrade default version of (apache 2.0.40, php 4.2.2 and mysql 3.23) to (apache 2.0.49, php 4.3.6 and mysql 4).
I tried to install apache 2.0.49 and php 4.3.6 in usr/local directory. Both were working but when tried to run phpmyadmin it was giving me error can not connect to mysql database please check username password and host name and also it tried to locate mysql.sock file in /tmp folder. i configure hostname as "localhost" username as "root" and password as "" in the config.ini.php file. But still phpmyadmin is not working.

Please give me idea/ suggestion. Have I not installed apache 2.0.49 and php 4.3.6 ? or should i install all mysql also in /usr/local folder if yes then how should i install.What could be the problem and its answer.

I want to install php 4.3.6, apache 2.0.49 and mysql 4 on my system.

Thanks in you all
Bye
 
Old 04-30-2004, 05:58 AM   #2
ac1980
Member
 
Registered: Aug 2003
Location: Trento, Italy
Distribution: Debian testing
Posts: 394

Rep: Reputation: 30
I'm not familiar with RH, but I think to upgrade a package you use something like
Code:
rpm -U nameorpackage.rpm
It looks like the mysql server is not running. Are you sure apache or init starts it?

PS: please don't connect to mysql as root, there's no need to and it's dangerous, even on localhost. Maybe mysql even defaults to refuse any connection from root. Use your normal user name or (best) make a dedicated mysql user.
 
Old 04-30-2004, 06:20 AM   #3
PolyPerception
LQ Newbie
 
Registered: Feb 2004
Location: Fort Worth, Texas
Distribution: Slackware-9.1
Posts: 29

Rep: Reputation: 15
If I understand correctly you have removed the old packages with "rpm -e apache/php/mysql.rpm" then you installed the new packages and they installed without error? yes?

So now you are attempting to get phpMyAdmin to work but you get an error and it says "Cannot connect to MySQL server". I am assuming that the rpm version doesn't set a default password so you have to set one yourself. To do this you enter this command:
Code:
mysqladmin -u root -h localhost password <password_Here>
After issuing that command in a shell, open the "config.inc.php" in the phpMyAdmin directory and enter the password around line 84 where it says:
Code:
$cfg['Servers'][$i]['password']      = '<password_Here>';
In theory this should all work. Also to clarify something the 'root' user on mysql is different then the 'root' user on your RH system, therefore also making the password different among other things.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
apache 2, php 5 and mysql 5 install and configure librano Linux - Enterprise 3 11-13-2005 05:52 AM
Apache, PHP, MySQL Install SpiderIRE Linux - Software 3 10-03-2005 04:50 AM
Please tell me how to install PHP/MySQL and apache in RedHat AS3 txkss Linux - Newbie 7 02-14-2005 05:10 AM
Xine fails after Mysql,Apache,PHP install 9.2 1kyle Suse/Novell 1 12-02-2004 05:54 PM
How do I find and install MySQL/Apache/PHP? jefx Linux - Software 3 04-26-2003 04:33 PM


All times are GMT -5. The time now is 03:30 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration