PDA

Bekijk de volledige versie : MySql and PHP5



gegy
03-04-2007, 16:15
Hello!

I have a ASUS WL500gP with Oleg Firmware on it.
I installed mysql described in this post:

http://wl500g.info/showthread.php?t=8236

I can start mysql server (S70mysqld start) without any problems.
Also my webserver lighttpd works. PHP also works fine.

But how can i use mysql now in PHP? I know that i have to load an extension in PHP but which one? I have no mysql.so

Can someone Please help me in using PHP5 and mysql?
I can change also to php4, but i don't know where to find php4 packet for ipkg.

....and sorry for my bad english... i am better in german.

oleo
03-04-2007, 21:33
there is no php4. lighthttpd should work with mysql embeded under php.

gegy
04-04-2007, 10:49
i don't need to use an extension in php?

gegy
07-04-2007, 20:45
You are right oleo!!

I installed not the right package.
Now i have a mysql.so and can use it in php with lighttpd!
Now torrentflux also works. With sqlite i didn't work.

YEAAAA!

THX!

mcdull
12-04-2007, 07:28
can you share with us on how you get them to work?
Which ipkg feed you are using?
Thanks.

gegy
12-04-2007, 10:12
Shure i can Share... but it isn't work correct yet.

1.) instal right mysql pack

ipkg install php-mysql

NOT only mysql

mysql should work and start with success

2.) you have to use the mysql.so extension in php.ini

i used lighttpd with fast-cgi as webserver

now it is possible to install the torrent flux

BUT.....

php-fcgi and lighttpd is not working perfect.
i have a phpinfo.php file and it sucks after some seconds.
But thats not a problem of mysql it is a problem of php-fcgi

with httpd-php Webserver i had no problems with PHP.

so now i try it with apache:

1.) fresh formated USB Drive

2.) install better ipkg
wget http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/ipkg-opt_0.99.163-9_mipsel.ipk
#install it (ignore tne missing lists/wl500g error)
ipkg.sh install ipkg-opt_0.99.163-9_mipsel.ipk

3.) install better uclibc
wget http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/uclibc-opt_0.9.28-12_mipsel.ipk
# install it (ignore tne missing lists/wl500g error)
ipkg.sh install uclibc-opt_0.9.28-12_mipsel.ipk

4.) ipkg upgrade

5.) ipkg install apache-php (or php-apache i dont know it now)

6.) ipkg install mysql-php

But now the problem is that i can't start apache. some errors
MySql starts success!