LinuxQuestions.org
Review your favorite Linux distribution.
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 05-05-2005, 11:49 PM   #1
Red Squirrel
Member
 
Registered: Dec 2003
Distribution: FC9 on main server
Posts: 792

Rep: Reputation: 36
debian php installs without mysql


I installed debian and selected the webserver option. The problem is that php is installed without mysql. I installed mysql but it did not reconfigure php with mysql. In phpinfo() it shows this configure string:

../configure' '--prefix=/usr' '--with-apxs2=/usr/bin/apxs2' '--with-config-file-path=/etc/php4/apache2' '--enable-memory-limit' '--disable-debug' '--with-regex=php' '--disable-rpath' '--disable-static' '--with-pic' '--with-layout=GNU' '--with-pear=/usr/share/php' '--enable-calendar' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-track-vars' '--enable-trans-sid' '--enable-bcmath' '--with-bz2' '--enable-ctype' '--with-db4' '--with-iconv' '--enable-exif' '--enable-filepro' '--enable-ftp' '--with-gettext' '--enable-mbstring' '--with-pcre-regex=/usr' '--enable-shmop' '--enable-sockets' '--enable-wddx' '--disable-xml' '--with-expat-dir=/usr' '--with-xmlrpc' '--enable-yp' '--with-zlib' '--without-pgsql' '--with-kerberos=/usr' '--with-openssl=/usr' '--with-zip=/usr' '--enable-dbx' '--with-mime-magic=/usr/share/misc/file/magic.mime' '--with-exec-dir=/usr/lib/php4/libexec' '--without-mm' '--without-mysql' '--without-sybase-ct'

How can I reinstall it but change the --without-mysql part to with-mysql? I can't seem to find anything with this in the documentation. It simply states that everything should be working and all I have left to do is set the root password. But that's not the case since mysql_connect() and other sql functions are not even reconized.
 
Old 05-06-2005, 02:15 AM   #2
hw-tph
Senior Member
 
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 57
Installing the php4-mysql package is probably a good start.


Håkan
 
Old 05-06-2005, 03:24 AM   #3
RomanG
Member
 
Registered: Jan 2005
Location: Russia, Kazan
Distribution: Mandrake 10.2, RedHat sometimes..
Posts: 110

Rep: Reputation: 15
Hello.
Code:
./configure --with-mysql=/usr/local/mysql --with-mysql-sock=/tmp --with-mysqli=/usr/local/mysql/bin/mysql_config --enable-sockets
and add other parameters you need
Code:
./configure --help
will help you alot.


Last edited by RomanG; 05-06-2005 at 03:27 AM.
 
Old 05-06-2005, 11:58 AM   #4
Red Squirrel
Member
 
Registered: Dec 2003
Distribution: FC9 on main server
Posts: 792

Original Poster
Rep: Reputation: 36
How do I do that with apt-get? And if I install the php4-mysql package will it conflict with the current php4-common one? or will it automaticly just reconfigure it?
 
Old 05-06-2005, 12:20 PM   #5
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 64
Quote:
Originally posted by Red Squirrel
How do I do that with apt-get? And if I install the php4-mysql package will it conflict with the current php4-common one? or will it automaticly just reconfigure it?
It should be automatically configured and the package depends on php4-common being installed so there will be no conflict.

Code:
>$ apt-cache show php4-mysql
Package: php4-mysql
Priority: optional
Section: web
Installed-Size: 76
Maintainer: Adam Conrad <adconrad@0c3.net>
Architecture: i386
Source: php4
Version: 4:4.3.10-13
Replaces: php4-cgi-mysql
Depends: libc6 (>= 2.3.2.ds1-21), libmysqlclient12, debconf (>= 0.5) | debconf-2.0, phpapi-20020918, php4-common (= 4:4.3.10-13)
Filename: pool/main/p/php4/php4-mysql_4.3.10-13_i386.deb
Size: 21280
MD5sum: d72955d515598a1d6e313d749c2058de
Description: MySQL module for php4
 This package provides a module for MySQL database connections directly from
 PHP scripts.
 .
 PHP4 is an HTML-embedded scripting language. Much of its syntax is borrowed
 from C, Java and Perl with a couple of unique PHP-specific features thrown
 in. The goal of the language is to allow web developers to write
 dynamically generated pages quickly.
 
Old 05-06-2005, 06:13 PM   #6
Red Squirrel
Member
 
Registered: Dec 2003
Distribution: FC9 on main server
Posts: 792

Original Poster
Rep: Reputation: 36
Turns out I had to reboot and everything works now! I usually don't forget that part, having worked with windows for so long. You plug in a different mouse and have to restart lol.
 
Old 05-06-2005, 06:37 PM   #7
RomanG
Member
 
Registered: Jan 2005
Location: Russia, Kazan
Distribution: Mandrake 10.2, RedHat sometimes..
Posts: 110

Rep: Reputation: 15
linux is quite different from Windows. You do not need to reboot at all, except you install new kernel. Simply restart some services and that is all you need to be happy with your new soft.
 
Old 05-06-2005, 07:06 PM   #8
Red Squirrel
Member
 
Registered: Dec 2003
Distribution: FC9 on main server
Posts: 792

Original Poster
Rep: Reputation: 36
Yeah that's what I figured but for php it must of been different, since I was restarting apache and it was not working. Unless I had to restart mysql too. Either way it works now so that's good. Moving on to email, which is the harder part.
 
Old 05-31-2005, 05:29 AM   #9
tkarkkainen
LQ Newbie
 
Registered: Mar 2004
Location: Finland
Distribution: Kubuntu
Posts: 11

Rep: Reputation: 0
I'm having the very same problem. I've installed at least the following packages with apt-get:

apache2
mysql-server-4.1
php4
libapache2-mod-php4
php4-mysql

It must be something very simple. Any ideas?
 
Old 05-31-2005, 07:51 AM   #10
tkarkkainen
LQ Newbie
 
Registered: Mar 2004
Location: Finland
Distribution: Kubuntu
Posts: 11

Rep: Reputation: 0
This is solved now. It turned out that I had edited the php.ini for apache, while it should've been php.ini for apache2.
 
Old 11-06-2005, 07:10 AM   #11
mrspcs
LQ Newbie
 
Registered: Sep 2005
Posts: 5

Rep: Reputation: 0
Same problem here, I also installed the php4-mysql but after that mysql still doesn't work.
Also reinstalled everything several times. but still no luck.

Can anyone help me.
 
  


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
Debian + Apache + PHP + MySQL.so = Error critical Linux - Software 4 08-04-2005 04:18 AM
3Q's: TV Tuner, source installs, PHP for users gothgeek84 Mandriva 4 02-01-2005 10:53 AM
Debian, Apache, PHP, MySQL rossp Linux - Software 2 10-30-2004 06:51 AM
Problem getting PHP to recognize MySQL, Using PHP 4.0 and MySQL 4.0.20 d2army Programming 4 06-27-2004 08:54 PM
Apache / PHP / Mysql config problem - debian bandit Linux - Software 14 09-03-2003 09:04 AM


All times are GMT -5. The time now is 07:01 PM.

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