Page 1 of 1

Cache Files for WURFL are not created.

Posted: Sun Feb 22, 2015 3:52 pm
by vlad3d
hi.
I have the problem - cache files for WURFL are not created

“WURFLres/storage/cache”
“WURFLres/storage/persistence”
have 777
PHP process have the access to the following folders - but cash files is not created anymore.
script which use WURFL try find non existing file - that request multiple - it loads my server

SIGNAL 9 (SIGKILL)
clock_gettime(13,{1424373895.000000000 }) = 0 (0x0)
clock_gettime(13,{1424373896.000000000 }) = 0 (0x0)
clock_gettime(13,{1424373897.000000000 }) = 0 (0x0)
clock_gettime(13,{1424373898.000000000 }) = 0 (0x0)
clock_gettime(13,{1424373899.000000000 }) = 0 (0x0)
clock_gettime(13,{1424373900.000000000 }) = 0 (0x0)
lstat("/*/*/*/WURFLres//storage/persistence/d/4/1d8cd98f00b204e9800998ecf8427e",0x7fffffffa8c0) ERR#2 'No such file or directory'
open("/*/*/*/WURFLres/storage/persistence/d/4/1d8cd98f00b204e9800998ecf8427e",O_RDONLY,0666) ERR#2 'No such file or directory'
process exit, rval = 0

That type of request appears again and again and multiply.
The main problem that I can not stop that file request - even if I create empty file - it does not work.
WURFL uses by CPVlab script - but they can not help me a week already. They have no idea how to fix that and how to stop
that non existing file request.
It works line a charm about 2 month but when I try to get info about mobile device name, carrier, models from huge database - it stopt work and since that time cash files not created.

Re: Cache Files for WURFL are not created.

Posted: Mon Feb 23, 2015 7:14 am
by vlad3d
done by admins
thanks

Re: Cache Files for WURFL are not created.

Posted: Mon Feb 23, 2015 11:54 am
by Elliotfehr
Hello,

I'm glad to hear that the issue has been resolved. I am interested to hear what was causing the cache and persistence directories to not be readable by the API. How were you able to resolve this?

Thank you,

Elliot

Re: Cache Files for WURFL are not created.

Posted: Sat May 16, 2015 7:02 pm
by tekjava
I'm having a similar issue...

My issue is once the cron job goes off the php script goes in a loop and the log file starts to fill up until I reboot the server.

(Infinite loop error: PHP Warning: feof() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0)

Other error that made me reference here: PHP Warning: fopen(http://www.scientiamobile.com/wurfl/xxxxx/wurfl.zip): failed to open stream: HTTP request failed! HTTP/1.0 402 Payment Required
in /sys/www/server/public_html/cron-wurfl.php on line 0

Either one of these Cron jobs will trigger the same error in the php.log file:
#0 0 * * * cd /sys/www/server/public_html/;php cron-wurfl.php
#0 0 * * * php /sys/www/server/public_html/cron-wurfl.php

Could not attached entire log file sorry for the paste:
[16-May-2015 13:00:01] PHP Warning: visualStylesCheckCall(license/license.php): failed to open stream: No such file or directory in /sys/www/server/public_html/lib/app.inc on line 0
[16-May-2015 13:00:01] PHP Warning: visualStylesCheckCall(): Failed opening 'license/license.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /sys/www/server/public_html/lib/app.inc on line 0
[16-May-2015 13:00:01] PHP Notice: Undefined index: License in /sys/www/server/public_html/lib/app.inc on line 0
[16-May-2015 13:00:02] PHP Warning: fopen(http://www.scientiamobile.com/wurfl/xxxxx/wurfl.zip): failed to open stream: HTTP request failed! HTTP/1.0 402 Payment Required
in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: feof() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: fread() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: feof() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: fread() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: feof() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: fread() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: feof() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0
[16-May-2015 13:00:02] PHP Warning: fread() expects parameter 1 to be resource, boolean given in /sys/www/server/public_html/cron-wurfl.php on line 0

Re: Cache Files for WURFL are not created.

Posted: Mon May 18, 2015 9:25 am
by Elliotfehr
Hello,

It appears that your cron job is failing to download the wurfl.xml and causing it to go into a loop. It would be best to wrap your `fopen()` method in a try/catch block to handle download failures.

Thank you,

Elliot

Re: Cache Files for WURFL are not created.

Posted: Mon May 18, 2015 7:06 pm
by tekjava
I resolved this issue by getting an updated zip package from CPVlabs and also installing zlib extension. Using the command "yum install zlib-devel"

No php error in log any-more and cron job starts and finishes!