Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

php dom and xml extension warning, but packages are installed? #12211

Open
m4ntic0r opened this issue Oct 19, 2017 · 11 comments
Open

php dom and xml extension warning, but packages are installed? #12211

m4ntic0r opened this issue Oct 19, 2017 · 11 comments

Comments

@m4ntic0r
Copy link

m4ntic0r commented Oct 19, 2017

Today i upgraded my server from ubuntu server 17.04 to 17.10 and so far everything seems to be ok but i get system warnings in piwik system check.

There is a warning for the "dom" extension and "simplexml" extension.

On system -> apt-cache search php-dom, the package php7.1-xml is listed and this is installed
On system -> apt-cache search simplexml, the same package php7.1-xml is found and installed

php-xml is installed, too

php version shown in the webui: 7.0.22-0ubuntu0.17.04.1

apt-get update and apt-get dist-upgrade shows, that everything is updated, no new packages are found.

i am using piwik 3.2.0

@fdellwing
Copy link
Contributor

You are using PHP7.0 and not PHP7.1.

Please install php7.0-xml and php7.0-dom.

To check for installed PHP modules run dpkg -l | grep php

@sgiehl
Copy link
Member

sgiehl commented Oct 27, 2017

Could you create a simple php script to check what get_loaded_extensions() returns?

@fdellwing
Copy link
Contributor

You mean php -m or in this case php7.0 -m? ^^

@m4ntic0r
Copy link
Author

after the error i restored from backup and everything was ok.

now i just tried the upgrade to 17.10 again and now everything seems to run, after upgrade i had to manually install php7.1 and some 7.1 extensions.

system check says everything is ok, and PHP-Version: 7.1.8-1ubuntu1

@sgiehl
Copy link
Member

sgiehl commented Oct 27, 2017

You mean php -m or in this case php7.0 -m? ^^

No, the output of the php function get_loaded_extensions(), not sure if that's always the same as php -m

@fdellwing
Copy link
Contributor

It is.

@robocoder
Copy link
Contributor

php -m loads the cli configuration; technically, it could have different extensions loaded than mod_php or php-fpm.

@BloodyIron
Copy link

Yeah I have php7.2-xml and php7.2-gd installed, yet the checker says they aren't. I'm using the latest version as of today, unsure what on earth it's complaining about.

@robocoder
Copy link
Contributor

robocoder commented Jan 11, 2020

On Ubuntu, there are separate conf.d/ .ini files for php-cli and mod-apache that load PHP extensions.

You can check this by opening your browser to a file in your web server document folder that contains:

<?php phpinfo();

Or

<?php var_dump(get_loaded_extensions());

@BloodyIron
Copy link

But I know that the modules are loaded as apache shows them enabled (in the modules-enabled folder). Same way all the other modules are loaded. I don't see why the behaviour would be different here.

@tsteur
Copy link
Member

tsteur commented Jan 11, 2020

@BloodyIron could you test what @robocoder suggests in #12211 (comment) ? It's important to have it tested through the browser. Maybe you need to make some changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants