unwanted setlocale() interaction between mod_php and mod_perl2

Thomas Bartosik <[email protected]>
Newsgroups gmane.comp.apache.mod-perl
Message-ID <[email protected]>
Hi!

Up until Ubuntu 18.04 LTS or Debian 9, a perl service (eprints.org) and a PHP service (nextcloud) worked smoothly next to each other on Apache with mod_php and mod_perl2.

However, on Ubuntu 20.04 LTS, or Debian 10, as soon as I enable mod_perl2, setlocale() on nextcloud does not seem to work anymore.

The relevant versions are

Apache 2.4.29 and mod_perl2 2.0.10, mod_php7.2 7.2.24 vs.
Apache 2.4.41 and mod_perl2 2.0.11, mod_php7.4 7.4.3

This issue is already documented at least in two locations that I know of:

https://bugs.php.net/bug.php?id=81596
https://bugs.mageia.org/show_bug.cgi?id=25411

The first one states that setlocale() in PHP does not work anymore globally, so this does not seem to be a nextcloud specific issue, but some kind of general interaction problem, as it seems mod_perl2 somehow manipulates the process' locale in an unchangeable way.

I tried hard to find a bug tracker for mod_perl2 but have not been successful till now, so please excuse if there is one and this is already documented (and please give me a link)!

Any insight is appreciated.

Thanks in advance!
th
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.