[Kolab-devel] pfbcache.db is not created automatically

Steffen Hansen steffen at klaralvdalens-datakonsult.se
Fri Apr 7 14:40:33 CEST 2006


On Thursday 06 April 2006 22:48, Marcus Hüwe wrote:
> Hi,
>
> Richard and I found out that the pfbcache.db isn't created
> automatically. So if you browse to
> https://<your-domain>/kolab/freebusy/<user>%40<your-domain>.ifb and
> the pfbcache.db doesn't exist you'll get the following error:
>
>
> Warning: dba_open(/srv/www/htdocs/kolab/freebusy/cache/pfbcache.db)
> [function.dba-open]: failed to open stream: No such file or directory
> in /usr/share/php/kolab/freebusy/freebusycache.class.php on line 182
>
> Warning: Cannot modify header information - headers already sent by
> (output started
> at /usr/share/php/kolab/freebusy/freebusycache.class.php:182)
> in /usr/share/php/kolab/freebusy/misc.php on line 64 Not Found
>
> The requested URL /kolab/freebusy/marcus%40linux-network.tld.ifb was
> not found on this server.
>
>
>
> The dba_open warning is the important one (the header warning can be
> ignored..).
> I attached a patch that checks if the pfbcache.db file exists and if
> it doesn't exist it will be created.

I don't think we have to create the db if we just want to read. If you 
look throught the code, everywhere were we write to the db, it is 
created first if missing. On read we check if the db could be opened 
and fail nicely if not. To get rid of the warning, put an @ in front of 
dba_open. Or are there errors that I dont see?

regards
-- 
Steffen Hansen          |       Klarälvdalens Datakonsult AB
Senior Software Engineer|       http://www.klaralvdalens-datakonsult.se
                        |
                        |       Platform-independent
                        |       software solutions




More information about the devel mailing list