Author Topic: Problems with sqlite2 - "attempt to write a readonly database"  (Read 5590 times)

Offline jkv

  • Newbie
  • *
  • Posts: 2
Hi, im having trouble getting roundcube to accept my sqlite db, im using sqlite2, php5 and lighttpd - sqlite interactions works in other php scripts.

I make the database by using 'sqlite -init SQL/sqlite.initial.sql sqlite.db"
After this i make temp and logs chown www:www, same with sqlite.db.
When trying to login i get this in the errorlog:

Code: [Select]
[17-Mar-2007 19:31:58 +0000] DB Error: DB Error: unknown error Query: 8 ** INSERT INTO session (sess_id, vars, ip, created,
 changed) VALUES ('db12be5f267157b55819ab9602faa78f', 'user_lang|s:5:"en_US";auth_time|i:1174159917;task|s:4:"mail";user_id|s:0:"
&quot;;', '10.0.0.15', now(), now()) [nativecode=sqlite_query() [<a href='function.sqlite-query'>function.sqlite-query</a>]:
attempt to write a readonly database] in /servers/rctest.unixcluster.dk/program/include/rcube_db.inc on line 479

For some reason i think's its a readonly db, any suggestions?

The directory structure:

Code: [Select]
-rw-r--r-- 1 root daemon 12852 Mar 17 19:38 CHANGELOG
-rw-r--r-- 1 root daemon 3346 Mar 17 19:38 INSTALL
-rw-r--r-- 1 root daemon 15129 Mar 17 19:38 LICENSE
-rw-r--r-- 1 root daemon 2925 Mar 17 19:38 README
drwxr-xr-x 2 root daemon  512 Mar 17 19:38 SQL
-rw-r--r-- 1 root daemon 5647 Mar 17 19:38 UPGRADING
drwxr-xr-x 2 root daemon  512 Mar 17 19:40 config
-rw-r--r-- 1 root daemon 10920 Mar 17 19:38 index.php
drwxrwx--- 2 www www   512 Mar 17 19:41 logs
drwxr-xr-x 7 root daemon  512 Mar 17 19:38 program
drwxr-xr-x 3 root daemon  512 Mar 17 19:38 skins
-rw-rw---- 1 www www  27648 Mar 17 20:30 sqlite.db
drwxrwx--- 2 www www   512 Mar 17 19:38 temp

Offline jkv

  • Newbie
  • *
  • Posts: 2
Re: Problems with sqlite2 - "attempt to write a readonly database"
« Reply #1 on: March 18, 2007, 09:51:43 AM »
Solved.

I renamed sqlite.db to sqlite2.db - and it worked...
I suspect this to be a php 5 issue, and not a rc issue - anyone?

/jkv
http://unixcluster.dk