Nextcloud version (eg, 20.0.5): 27.1.2.1
Operating system and version (eg, Ubuntu 20.04): Arch Linux x86_64
Apache or nginx version (eg, Apache 2.4.25): Apache/2.4.56 (Unix
PHP version (eg, 7.4): 8.2.4
Hello. It’s my first post so if I opened this topic on the wrong category, please move it to correct place.
I just downloaded “setup-nextcloud.php” and tried to install it. everything done but when I wanna run it (http://localhost) I face this error:
Setting locale to en_US.UTF-8/fr_FR.UTF-8/es_ES.UTF-8/de_DE.UTF-8/ru_RU.UTF-8/pt_BR.UTF-8/it_IT.UTF-8/ja_JP.UTF-8/zh_CN.UTF-8 failed.
Please install one of these locales on your system and restart your web server.
I just debug the code and modified this file: nexctloud/lib/private/legacy/OC_Util.php to this:
if (!OC_Util::isSetLocaleWorking()) {
$errors[] = [
'error' => $l->t('Setting locale to %s failed.',
['en_US.UTF-8/fr_FR.UTF-8/es_ES.UTF-8/de_DE.UTF-8/ru_RU.UTF-8/'
. 'pt_BR.UTF-8/it_IT.UTF-8/ja_JP.UTF-8/zh_CN.UTF-8']),
'hint' => $l->t('Please install one of these locales on your system and restart your web server.')
];
echo locale_get_default(); // <-- this line
}
and after running localhost, the result is strange sometimes it gives me en_US_POSIX and sometimes it gives me en_US. Although when I running
locale
on my terminal it gives me:
LANG=en_US.utf8
LC_CTYPE="en_US.utf8"
LC_NUMERIC="en_US.utf8"
LC_TIME="en_US.utf8"
LC_COLLATE="en_US.utf8"
LC_MONETARY="en_US.utf8"
LC_MESSAGES="en_US.utf8"
LC_PAPER="en_US.utf8"
LC_NAME="en_US.utf8"
LC_ADDRESS="en_US.utf8"
LC_TELEPHONE="en_US.utf8"
LC_MEASUREMENT="en_US.utf8"
LC_IDENTIFICATION="en_US.utf8"
LC_ALL=
Is this the first time you’ve seen this error? (Y/N): Yes
Steps to replicate it:
- running localhost
The output of your Nextcloud log in Admin > Logging:
I can't access it but there is no log in this file: nextclout/data/nextcloud.log
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
here is nextcloud/config/config.php
<?php
$CONFIG = array (
'instanceid' => 'ocg7uekkqofu',
);