• Resolved jmkennedy

    (@jmkennedy)


    Tried several times to install the Matomo WordPress Plugin on a site. Every time it makes the backend crash and I have to go in recovery mode and deactivate. (It looks normal on the frontend.) I get a message about write permissions which I can also see in the backend. I have tried to fix this by activating write permissions on this file:
    /wp-content/plugins/matomo/app/core/Config.php

    This other file that is mentioned seems not to exist:(config/config.ini.php)

    I don’t know what it means when it says for example “…/wp-content/plugins/matomo/app/core/Config.php:448” and various numbers at the end.

    How can I fix this please?

    I still get this message:

    This plugin failed to load properly and is paused during recovery mode.

    An error of type E_ERROR was caused in line 448 of the file /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/app/core/Config.php. Error message: Uncaught Piwik\Exception\MissingFilePermissionException: The Matomo configuration file (config/config.ini.php) is not writable, some of your changes might not be saved. Please change permissions of the config file to make it writable. in /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/app/core/Config.php:448 Stack trace: #0 /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/app/core/Config.php(410): Piwik\Config->getConfigNotWritableException() #1 /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/app/core/Config.php(439): Piwik\Config->writeConfig() #2 /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/classes/WpMatomo/Installer.php(283): Piwik\Config->forceSave() #3 /www/webvol19/69/ht44iydarzutl3u/robinhoodfritids.se/public_html/wp-content/plugins/matomo/classes/WpMatomo/Installer.php(107): WpMatomo\Installer->create_config(Array) #4 /www/webvol`

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi @jmkennedy

    The plugin needs to write the config/config.ini.php file: please make sure that your folders wp-content/uploads, wp-content/uploads/matomo and wp-content/uploads/matomo/config are writeable.
    if you have a shell access on your server, please run the following commands:

    chmod +w wp-content/uploads
     chmod +w wp-content/uploads/matomo
     chmod +w wp-content/uploads/matomo/config
    

    if you don’t have a shell access, you can do it with your ftp client.

    Kind regards

    Mat

    Thread Starter jmkennedy

    (@jmkennedy)

    Hi @mattmary

    OK. Using Cyberduck FTP I have the option to make files writeable for the categories Owner / Group / Others.

    Should I make them all writeable – or which ones? Just want to make sure that these changes will not cause any security issues.

    Anyway, I did the first one (wp-content/uploads) for all so far. But then, I noticed regarding “wp-content/uploads/matomo and wp-content/uploads/matomo/config” that no such folders are present in this installation. Do I need to do something about that?

    Hi @jmkennedy

    Difficult to answer, it depends of your configuration and the user set as the owner: Owner is required to write, it could be required for the group too.
    If the folders do not exist, this is not a problem: they will be created by the plugin.
    Kind regards

    Mat

    Thread Starter jmkennedy

    (@jmkennedy)

    I set write permissions to config/config.ini.php file and wp-content/uploads/matomo which were the only files present of the ones you mentioned.

    However this did not seem to improve things much. Instead the backend crashed even worse now. Before I was able to deactivate through recovery mode. This time I wasn’t even able to do that but had to contact the host’s support to deactivate. It wasn’t complaining about the write permissions anymore but something broke with the login where it was trying to redirect between wp-admin and wp-login which resulted in error. This error again was fixed after deactivating Matomo.

    I have never had this kind of problem just to install… Could you explain why this would happen in the first place? Afaik this kind of thing is always handled automatically when you install. Why should I have to go in manually and handle these permissions?

    Hi @jmkennedy

    You don’t have to ask your hosting provider to disable it, just remove by FTP the content of the wp-content/plugins/matomo folder and it will remove the plugin.

    These permissions depend of your hosting configuration. If you have a custom permission management it can lead to this kind of errors. We expect that the wp-content/uploads folder is writeable by the webserver user. We cannot manage different configurations.
    It’s solved now.

    Regarding your login problem it is very stranged as our plugin is not involved in the login process. You may have a plugins conflict which appears initially on your login page.
    Can you share your system report available from the menu Matomo Analytics > Diagnostics?
    Can you also share your php_errors and wordpress logs files to my email [email protected]?

    Thanks in advance

    Kind regards

    Mat

    Thread Starter jmkennedy

    (@jmkennedy)

    Yes I know actually, but I also wanted to check with the host if the had an explanation of the problem which they didn’t.

    “These permissions depend of your hosting configuration. If you have a custom permission management it can lead to this kind of errors. We expect that the wp-content/uploads folder is writeable by the webserver user. We cannot manage different configurations.
    It’s solved now.”

    What do you mean by custom permission management? I can change them byt FTP is what I know. I never even had to go into this stuff with ANY plugin ever before and I tried many on different sites and hosts before. Is Matomo different to toher plugins in this respect?

    Also: What is solved? It still was not working.

    I uninstallaed Matomo for now so I don’t think I can give what you asked right now. I don’t have time to try this again right now. I tried to deactivate Wordfence and caching plugin to see if that was a conflict before this did not solve it though. I checked my plugins against a list you have on your site of incompatible plugins. I found none of the ones I use there. I will email a screenshot of my plugins if you can check if any other is one you think could conflict with Matomo. Subject: Regarding ticket “Fatal error when installing Matomo”

    Hi @jmkennedy

    I wrote “this part is done now” because you fixed your files permissions and the plugin has been able to write the config.ini.php file.
    Your webserver user was unable to write in your wp-content/uploads/ folder. Many reasons could explain that. I don’t know why you identified it only after installing our plugin. Maybe your plugins do not write in this folder?

    I’m sorry that you uninstall our plugin.
    If you install it back and need further support, feel free to contact us here, we’re happy to help.

    Kind regards

    Mat

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Fatal error when installing Matomo’ is closed to new replies.