I am not able to update any plugin.

Hi,

I am not able anymore to update any plugin. The update process starts, but after a few seconds it stops. Please advise what the possible problem can be and how to proceed.

Thanks,
Maarten

  • Adam Czajczyk

    Hey Maarten,

    I hope you're well today and thank you for your question!

    I've visited your site that you granted access to ("Michael Roads International") and tried to update one of the non-active plugins. It seems like an update is taking forever, indeed.

    There might be several reasons for this. Here are a few possibilities:

    - php script execution timeout to low (so script finishes work before completion)
    - too strict file folder/file permissions (so WP is able to download the plugin archive but not unpack and overwrite it, for example)
    - too low memory limit (so the script is unable to unpack the downloaded archive)

    That being said, could you please first check your wp-config.php file for the following definition:

    define('WP_MEMORY_LIMIT', '96M');

    The value might be higher than "96M" though. If it's there, please raise it to 128M or 256M and if it doesn't helpe, set it even to 512M.

    If it's not there, add it somewhere at the beginning of the file after the opening "<?php" tag.

    Let me know if it helped!

    Cheers,
    Adam

  • Adam Czajczyk

    Hey Maarten,

    I hope you're well today!

    This means that the "phpinfo()" function is disabled in php.ini (PHP configuration) file by your hosting provider. It's possible that you may be able to change it from inside your server's admin panel but it's rather unlikely.

    Having said that, I think we need to take a different approach here. Could you please send in

    -WordPress admin username
    -WordPress admin password
    -login URL
    -FTP credentials (host/username/password)
    - server's admin panel login credentials (URL, login and password for your cPanel, DirectAdmin or other - the one that's used on your server)
    -link back to this thread for reference
    -any other relevant URLs and information

    Please use this line as a message subject: "ATTN: Adam Czajczyk"

    Select "I have a different question" for your topic - this and the subject line ensure that it gets assigned to me.

    Use our contact form here: https://premium.wpmudev.org/contact/

    Cheers,
    Adam

  • Adam Czajczyk

    Hey Maarten,

    I hope you're well today!

    I've noticed that now all the plugins at your site are up-to-date. Does this mean that you've managed to resolve the issue or have you updated them manually? Please advise!

    I've also checked your php configuration in your cPanel and it seems like there are some general top limits that cannot be overridden. I think this one here might be a case:

    max_execution_time 60

    This means that the script cannot be executed for longer than 60 seconds. That should be enough in most cases but it's worth raising a bit. I'd give it 300 seconds. I've also found that /wp-content/plugins permissions were set to 0707 which wasn't secure as it gave everyone right to write to this folder but on the other hand might be preventing WP from writing plugin's files there ("0" - means no permission at all for group). I've changed it.

    Let me know if you've manually updated the plugins or if the issue is fixed.

    Cheers,
    Adam

  • Maarten

    Hey Adam,

    Thank you for your assessment and support.
    I manually updated most of the plugins and also the WP update.
    I noticed that I could update two plugins automatically. This makes me thinking that it is as you stated an execution time issue.
    I will ask my hosting service if they can increase the max_execution_time to 300.
    I will update you if this is possible and run a test again with the new execution time.

    Cheers,
    Maarten

  • Adam Czajczyk

    Hey Maarten!

    I noticed that I could update two plugins automatically. This makes me thinking that it is as you stated an execution time issue.

    I agree, this indeed indicates that raising max_execution_time might be what we need here :slight_smile:

    I will ask my hosting service if they can increase the max_execution_time to 300.

    I don't know how fast your hosting's techs react and what's their policy against php settings (I bet it's quite strict though) but you can try adding this line to your .htaccess file:

    php_value max_execution_time 300

    In most environments this works as a charm. If it won't work for you, then you'll most likely need to ask your hosting provider for help.

    Keep me updated please :slight_smile:

    Cheers,
    Adam

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.