Mise à jour de 'services/minetest.libre-service.eu.md'
This commit is contained in:
parent
7a481f20dc
commit
1134fd66ca
1 changed files with 19 additions and 10 deletions
|
@ -77,29 +77,40 @@ systemctl start minetest-server@fooland.service
|
|||
```
|
||||
Tester le nouveau monde en se connectant avec un client Minetest.
|
||||
|
||||
Créer un compte Postgreql :
|
||||
## Migration dans Posgreql
|
||||
Créer un compte dédié (si pas déjà fait) :
|
||||
```
|
||||
su - postgres 'psql -c "CREATE DATABASE minetestdb-fooland OWNER minetestdba; GRANT ALL PRIVILEGES ON DATABASE minetestdb-fooland TO minetestdba;"'
|
||||
su - postgres -c "psql -c \"create user minetestdba with password 'XXXXXXXX'; \" "
|
||||
```
|
||||
|
||||
Optimiser Postgresql :
|
||||
- en modifiant `/etc/postgresql/13/main/postgresql.conf` :
|
||||
Créer une base de données :
|
||||
```
|
||||
su - postgres -c "psql -c \"CREATE DATABASE minetestdb_fooland OWNER minetestdba; \""
|
||||
```
|
||||
|
||||
Associer le compte dédié avec la base fraîchement créée :
|
||||
```
|
||||
su - postgres -c "psql -c \"GRANT ALL PRIVILEGES ON DATABASE minetestdb_fooland TO minetestdba; \""
|
||||
```
|
||||
|
||||
Optimiser la configuration de Postgresql :
|
||||
- avoir au moins 512MB de mémoire disponible pour Minetest hors Postgresql ;
|
||||
- modifier `/etc/postgresql/13/main/postgresql.conf` :
|
||||
```
|
||||
-shared_buffers = 128MB # min 128kB
|
||||
+shared_buffers = 512MB # min 128kB
|
||||
```
|
||||
- avoir au moins 512MB de mémoire disponible pour Minetest hors Postgresql.
|
||||
|
||||
Définir la base de données dans `/srv/minetest.libre-service.eu/worlds/fooland/world.mt` :
|
||||
```
|
||||
backend = postgresql
|
||||
pgsql_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXX dbname=minetestdb-fooland
|
||||
pgsql_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXX dbname=minetestdb_fooland
|
||||
|
||||
auth_backend = postgresql
|
||||
pgsql_auth_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXXX dbname=minetestdb-fooland
|
||||
pgsql_auth_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXXX dbname=minetestdb_fooland
|
||||
|
||||
player_backend = postgresql
|
||||
pgsql_player_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXXX dbname=minetestdb-fooland
|
||||
pgsql_player_connection = host=127.0.0.1 port=5432 user=minetestdba password=XXXXXX dbname=minetestdb_fooland
|
||||
```
|
||||
|
||||
Migrer le nouveau monde vers le backend Postgres :
|
||||
|
@ -111,8 +122,6 @@ minetestserver --migrate-players postgresql --world /srv/minetest.libre-service.
|
|||
systemctl start minetest-server@fooland.service
|
||||
```
|
||||
|
||||
|
||||
|
||||
## Jouer
|
||||
Liens utiles :
|
||||
- Mineclon2 : https://wiki.minetest.net/Games/MineClone_2/Differences_from_Minetest_Game
|
||||
|
|
Loading…
Reference in a new issue