OpenWrt Forum Archive

Topic: PHP5+SQLITE(2?3?) = 500 - Internal Server Error !!!

The content of this topic has been archived on 29 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

What i have :

/usr/bin/php: ./src/btree.c: 702: sqliteBtreeOpen: Assertion `sizeof(ptr)==sizeof(char*)' failed.
2007-07-03 18:44:52: (mod_cgi.c.553) cgi died, pid: 22720

What is installed :

libsqlite2    2.8.17-1   
libsqlite3    3.3.3-1
lighttpd    1.4.11-2
lighttpd-mod-auth    1.4.11-2   
lighttpd-mod-cgi    1.4.11-2   
lighttpd-mod-proxy    1.4.11-2   
lighttpd-mod-rewrite    1.4.11-2   
lighttpd-mod-setenv    1.4.11-2   
lighttpd-mod-simple-vhost    1.4.11-2   
lighttpd-mod-status    1.4.11-2
php5    5.0.5-1   
php5-cgi    5.0.5-1   
php5-cli    5.0.5-1   
php5-mod-ftp    5.0.5-1   
php5-mod-gd    5.0.5-1   
php5-mod-session    5.0.5-1   
php5-mod-sqlite    5.0.5-1   
php5-mod-xml    5.0.5-1

From http://downloads.openwrt.org/backports/0.9/

I follow forum2006 here : http://forum.openwrt.org/viewtopic.php?pid=43696#p43696
but i am not lucky sad

Is there a howto to have SQLITE with PHP ?

Is anyone knowing what this error does it mean ?

thanks sad

(Last edited by $@m on 3 Jul 2007, 18:11)

Same trouble as you,
i've been forced to kamikaze due to lack of updated packages and support on whiterussian, but now i'm dealing with sd/mmc hack (with kamikaze doesn't work).
I'd like to use PHP5+SQLITE3 ('cause my application need both) and i'm facing to use kamikaze, let me know if you can solve something with WR

Cheers
Ben

I test with 2 and 3... nothing
i downgrade my conf to have exactlye the same packages.... => nothing sad

I need mmc...

I think I will create my own php function to have an interface with SQLite....

I had the same problem but now all ok wink

the problem is the libsqlite2
do solve the problem follow the instructions from
http://forum.openwrt.org/viewtopic.php?pid=52509

or use my binaries.
1) remove the current libsqlite2
ipkg remove libsqlite2 -force-depends

2) add the following line to your /etc/ipkg.conf on your router:
src sqlite-port http://lamp2.fh-stpoelten.ac.at/~tm0410 … /backports
(use "~tm041085/openwrt/backports" instead of "~tm0410 … /backports")

3) update the package-list
ipkg update

4) install the libsqlite from the new backport (use the full address instead of only the name)
ipkg install http://lamp2.fh-stpoelten.ac.at/~tm0410 … mipsel.ipk
(use "~tm041085/openwrt/backports/libsqlite2_2.8.17-1_mipsel.ipk" instead of "~tm0410 … mipsel.ipk" )

5) now you can remove the added line from /etc/ipkg.conf

sorry for my bad english sad

(Last edited by snowfire on 18 Jul 2007, 21:59)

hi,

now it works with sqlite2, but i get an error with count and distinct in a query. is this only a disadvantage from sqlite2 or is it a error in this lib?

does it work with sqlite3? where do i get sqlite3?

Thanks

Thank you snowfire! You solved my problem too! It was a (one day) nightmare to install lighttpd + php5 + sqlite2 and let them work.

Thanks for snowfire ,my sqlite2 works too !

If any people have got the libsqlite from the new backport http://lamp2.fh-stpoelten.ac.at/~tm0410 … mipsel.ipk

please re-upload working libsqlite2 packages again ex. on rapidshare or hotfile (prev link gone/dead)? My problem is same. Thanks.

Please so much!

(Last edited by zulas on 27 May 2010, 11:15)

The discussion might have continued from here.