...
The setup requires root access privileges. You need to open the command line and enter the listed commands. After each command press ENTER.
Set locale
Ensure that the system (and after installation apache too) is using a UTF8 capable locale. The current system locale is set either with the tool "update-locale" or directly in the file /etc/default/locale.
The available locales can be listed with "locale -a". For apache this may be configured separately in the apache config files. For Ubuntu in /etc/apache2/envvars.
For details see: https://www.thomas-krenn.com/de/wiki/Locales_unter_Ubuntu_konfigurieren.
Install Apache
sudo apt-get install apache2
...
In general you will find the mysql configuration in "/etc/mysql/mysql.conf.d/mysqld.cnf" or in "/etc/mysql/my.cnf" or a similar file.
Charset and Collation
The charset is set on creation of the concrete DB in the next step.
Full text index optimization
For proper functionality of the termportal search the minimum index token length must be set to 1:
innodb_ft_min_token_size=1
After changing this values the indexes must be rebuild:
Rebuild the index if you just changed some of the above settings:
Code Block | ||
---|---|---|
| ||
set GLOBAL innodb_optimize_fulltext_only=ON;
OPTIMIZE TABLE terms_term; |
On MySQL 5.7 the innodb_optimize_fulltext_only flag should be kept disabled, since there the rebuild of the index does not properly work!
Timezone
Ensure that the timezone of MySQL is the same as the timezone configured in apache php and CLI php.
To get the MySQLs timezone call:
Code Block |
---|
SELECT @@global.time_zone, @@session.time_zone;
-- or more easier to read:
SELECT TIME_FORMAT(TIMEDIFF(utc_timestamp(), NOW()), '%H:%i') gmtshift; |
Not allowed SQL Modes
The following SQL Mode must not be set: ONLY_FULL_GROUP_BY, NO_ZERO_IN_DATE, NO_ZERO_DATE, STRICT_TRANS_TABLES
...
sql_mode = "ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
For MySQL 8 this would be:
sql_mode = "ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION"
See http://dev.mysql.com/doc/refman/5.7/en/sql-mode.html for further information.
...
Solution is here:
- edit /etc/my.cnf
- add / change the line
innodb_buffer_pool_size=64MB512MB # the suitable value depends on several points, see here. - Restart the MySQL server
See also : here and https://stackoverflow.com/questions/6901108/the-total-number-of-locks-exceeds-the-lock-table-size
...
/etc/init.d/mysql restart
Install PHP
...
8.
...
0 core
Please refresh your package list, the package names may be different, but it must be at least PHP 8.0.X at the moment.
sudo apt-get update
and install php 78.30
sudo apt-get install php7php8.30
Check if you have the correct version of php installed
...
sudo apt-get install libapache2-mod-php7php8.30
php7php8.30-mysql
php7php8.30-gd php7php8.30-dom php7php8.30-mbstring php7php8.30-zip php7php8.30-curl php7php8.30-intl php7php8.30-json
- dom
- fileinfo
- gd with Freetype-Support
- iconv
- mbstring
- pdo_mysql
- zip
- curl
- xml
- intl
- json
- opcache
- soap
- sqlite3
...
sudo apt install openjdk-8-jdk
Install unzip
sudo apt-get install unzip