Uutiset:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu
Advertisement:

Not working with PHP 7.1 - cPanel warning apc.so

Aloittaja L2Scarlet, lokakuu 01, 2019, 03:22:41 IP

« edellinen - seuraava »

L2Scarlet

SMF forum 2.0.15 not working with PHP 7.1+ (max. allowed 7.0)


[01-Oct-2019 19:16:02 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/cpanel/ea-php71/root/usr/lib64/php/modules/apc.so' - /opt/cpanel/ea-php71/root/usr/lib64/php/modules/apc.so: cannot open shared object file: No such file or directory in Unknown on line 0


Any help please? Ty

Arantor

That's a problem for your host to deal with, where you're trying to load apc.so on PHP 7+ which isn't going to work out particularly well for you (seeing that you really want apcu.so as apc.so isn't compatible properly with PHP7)
Holder of controversial views, all of which my own.


L2Scarlet

Hi Arantor and thank you for your fast reply. I don't have apc on my shared hosting and I don't need it, it was working before 3 days ago on PHP 7.1 without these warnings and now I was forced to switch on PHP 7.0.
SMF 2.0 is looking for apc.so module or what? It is deactivated in Admin > Cache section. It is recommended level 1 cache.

?? Any fix in SMF to remove this warning so I can switch back on PHP 7.1?

Illori

as said above you need to contact your host to fix this.

Arantor

It isn't SMF looking for this, it's your host's misconfiguration of easyApache.
Holder of controversial views, all of which my own.


L2Scarlet

Then how can you explain that it's working good on PHP 7.0 and NOT working on PHP 7.1+
I think it's related to PHP versions and SMF compatibility and nothing about easyApache... what you think about this? :)

Illori

most likely on php 7.0 your host has configured it CORRECTLY and in php 7.1+ they configured it INCORRECTLY. either way your host has to fix the issue.

shadav

no offense but.... i use 7.1, heck i was using 7.2 without issues until i looked at my error logs.... so na, it's something to do with the configuration on your hosts end
if it were a smf issue, then it would be more widespread

but
Unable to load dynamic library '/opt/cpanel
has nothing to do with smf that is hosting issues.....
contact your host and give them this error and ask them to check the settings for 7.1 and 7.2

L2Scarlet

Lainaus käyttäjältä: Illori - lokakuu 02, 2019, 11:35:58 AP
most likely on php 7.0 your host has configured it CORRECTLY and in php 7.1+ they configured it INCORRECTLY. either way your host has to fix the issue.

True, I thought that too.
Thanks for info.

Arantor

Lainaus käyttäjältä: L2Scarlet - lokakuu 02, 2019, 11:32:13 AP
Then how can you explain that it's working good on PHP 7.0 and NOT working on PHP 7.1+
I think it's related to PHP versions and SMF compatibility and nothing about easyApache... what you think about this? :)

I think since it's the easyApache configuration file asking for it and not being able to find it, that it's a problem for your host.

But sure, let's ignore the guy who is a former dev for SMF and who is a senior developer/systems admin for systems that require fleets of servers to run (think systems that handle millions of hits per day all across the world) in favour of your detailed experience, as you clearly know more than I do.
Holder of controversial views, all of which my own.


L2Scarlet

#10
Ok ma sysadmins ;)
Look, I got the answer from my web hosting "experts" lol :) and they said like this:
"In newer versions of PHP, you need to add both the apc.so and apcu.so extensions in your PHP.ini file because it's only included for backward compatibility of some functions that haven't been moved to core PHP.

A lot of the functionality of APC module is included in the newer versions of PHP.
Given that your site is based on a custom PHP framework, do you know which files you're including are requesting it and what functions from apc it's using?"

So what to tell them? Which function from apc it's using?
Please help. Thanks in advance (You're unbelieveable and extraordinary sysadmins and programmers out there) :)

I think it was very simple to add some module in php.ini? :P Just asking..

* These days if you want to configure a CMS based web app (SMF forum, Wordpress or any related CMS sh1t) probably you'll end up in an infinite loop by changing "things" in PHP, Apache, .htaccess and files.. week after week :)



Arantor

Oh so they're using the compat build, ok. (They're right, parts of APC were moved to core, which is why APCu was created, but it's done a bit differently, and I suppose that's the approach they've taken. Personally I wouldn't bother with APC since Redis does it better anyway but it's not core in 2.0.)

The functions it uses are apc_fetch, apc_store, apc_delete, apc_clear_cache. The files that use it in 2.0... I think it's actually just Load.php, which is called every page.
Holder of controversial views, all of which my own.


L2Scarlet

It is working with PHP 7.1 now.
Thanks for help and have a great day! ;)  8)

Advertisement: