• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

  • Chevereto Support CLST

    Support response

    Support checklist

    • Got a Something went wrong message? Read this guide and provide the actual error. Do not skip this.
    • Confirm that the server meets the System Requirements
    • Check for any available Hotfix - your issue could be already reported/fixed
    • Read documentation - It will be required to Debug and understand Errors for a faster support response

Guest images are not automatically deleted...

dr_brown

Chevereto Member
Hello. Help with another problem, after transferring the domain on the server, guest pictures are not deleted in php-cgi and php 7.2.8, the logs are empty, although log_errors = On is set in php.ini, the rights to folders and files are the same as they were before how the domain was set to php mode as apache module ... where to look? In the settings, deletion is enabled after 1 month, also the expiration_date_gmt date is set for the guest pictures.
 
If it was working before then clearly is your new server setup which is giving you issues. What to check? Being honest I don't know, get logs to work to start with, otherwise you are asking us to just try to guess how to help you.
 
If it was working before then clearly is your new server setup which is giving you issues. What to check? Being honest I don't know, get logs to work to start with, otherwise you are asking us to just try to guess how to help you.
I don't even write a log. I do not know what's the problem. In php.ini write_log = on ....
 
Turned on everything that is possible, displaying all errors. The log is empty, so is the screen. Files are not deleted. What a nonsense ...
 
Welcome to servers.

somehow you can manually initiate the deletion of images, can you set what flag in the lock folder?
I want to see errors on the screen...
can make a separate file, with a method call from the Image :: deleteExpired class?
 
in other words.....

I have commented out the condition in the following function of the web.php file:

PHP:
if (method_exists('CHV\Image', 'deleteExpired')) {
            try {
                $lock = new Lock('delete-expired-images');
                //if (!$lock->check() && $lock->create()) {
                    Image::deleteExpired(50);
                    $lock->destroy();
                //}
            } catch (Exception $e) {
                error_log($e);
            }
        }

specifically checking the condition

PHP:
if (!$lock->check() && $lock->create())

And I have perfectly deleted all the photos, and physically too, I checked all the folders, they are empty!

What could be the problem?
 
I did not move, just change the mode of php to cgi so that php version 7 and higher became available to me. The permissions were the same. I had three files in the lock folder, with the extension lock which disappeared after I commented out the above mentioned code and the images started to be deleted. What creates files in the lock folder?
 
I uncommented now, everything works fine. I have suspicions that in the settings - loading and storing data is not stored. As I understand it, when we turn off this feature in the loks folder, .loc files should be added to what is disabled. If enabled, then these files should be deleted.
 
The problem with locking in V3 is that it relies in the filesystem, so any change in permissions, like when you change the php pid will break the locking as the previous locks will be tied to other permission mask. It happens when you move servers or when you change how the php interpreter works.

This has been a long time issue, it has happened to too many users that I will change the system to use a database lock.
 
Back
Top