Jump to content

Smarty compiled templated is always recompiling generating a blank page.


shaman80

Recommended Posts

Hi everyone!!

 

I have an issue that I cant solved. In someway my compiled templated are been deleted every second, I mean, the cache/smarty/compile folder it's changing all the time so when brower goes to read a compiled template, the file doesn`t exist.

 

The enviroment its nginx and fastcgi. And its hosted in a m4.2xlarge EC2 instance in AWS .

 

Error log line .

2016/05/16 09:36:36 [error] 1250#0: *1972 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught exception 'UnexpectedValueException' with message 'RecursiveDirectoryIterator::__construct(

 

Had someone the same problem.

 

Thanks in advance. :)

Link to comment
Share on other sites

Does the re-compile for all pages or for a specific page?

 

 

first please check your configuration if it is set as force compile.

back office - Advanced Parameters - Performances tab

looking for Smarty section and check your configuraiton.

 

secondly, you have error in your PHP file, not sure which file, it could be from a module or your custom changes.

you need to figure out where is the error comes from and fix the error.

Link to comment
Share on other sites

The Re-compilation is  been produced for all pages.

My setting in AdminPerformace is N

  • never recompile templates files.
  • Cache on
  • FileSystem
  • Never clean the cache files.

I have check the table ps_configuration and all looks fine.

The php error is produced when prestashop try to read the file in cache.

Like this

2016/05/16 11:00:32 [error] 1253#0: *14095 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught exception 'UnexpectedValueException' with message 'RecursiveDirectoryIterator::__construct(/var/www/html/electrocosto/cache/smarty/compile/e5/bf/fa): failed to open dir: No such file or directory' in /var/www/html/electrocosto/tools/smarty/sysplugins/smarty_internal_utility.php:242
 

I have created several stores with pretashop, and only this one with better enviroment throws this error.

It would be because of the traffic?

Link to comment
Share on other sites

It could be file/folder permission or ownership problem.

 

Please check if the file/folder permission is set correctly and also check the owner group of the those folder/files to see if it is the same of owner group of web application user.

 

You may also consult with your service provider support to see if they can help.

Link to comment
Share on other sites

It has the right permissions. I think I have it. My files are running in a EC2 instance from an amazon service, and my database on another services called rds. So by mistake each server has an hour with a difference of 2 hours between one an the other. So when I execute an cleancache database has two hour more than the server where files are removing.

Thanks again Shokinro

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...