This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Eigenes OpenSim Server Hosting mit Ubuntu 20.04.3 LTS Teil 3
#1
Eigenes OpenSim Server Hosting mit Ubuntu 20.04.3 LTS Teil 3

Im letzten Beitrag wurden diese Themen angesprochen:

Einen Benutzer unter Linux anlegen (wird für das Setup von OpenSim benötigt)
Einen Sudo-fähigen Benutzer unter Linux anlegen
Einen Ordner erstellen
Eine Datei erstellen
Eine Datei umbenennen
Eine Datei mit nano anzeigen und editieren
Eine Datei downloaden und extrahieren
Navigieren im Terminal


Heute:

Der nächste Schritt auf Ubuntu 20.04.3 LTS

Aktivierung der Firewall
SSH Port auf 31444 ändern
PermitRootLogin verbieten
Setup von MySQL und absichern
Datenbanken anlegen
Mono installieren


Aktivierung der Firewall auf Ubuntu 20.04.3 LTS:

sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw allow ssh
sudo ufw allow 31444
sudo ufw enable
sudo reboot

ssh Port (Konfiguration) ändern:

sudo nano /etc/ssh/sshd_config

Port 31444
X11Forwarding no
AllowTcpForwarding no
PermitRootLogin no

sudo reboot

Jetzt Neu mit Portangabe einloggen:

ssh salatbieger@LAN-IP-Adresse -p31444

UFW Abfrage:

sudo ufw status verbose

To                        Action      From
--                        ------      ----
22/tcp                    ALLOW IN    Anywhere                 
31444                      ALLOW IN    Anywhere                 
22/tcp (v6)                ALLOW IN    Anywhere (v6)           
31444 (v6)                ALLOW IN    Anywhere (v6)           

Auflisten:

sudo ufw status numbered

[ 1] 22/tcp                    ALLOW IN    Anywhere                 
[ 2] 31444                      ALLOW IN    Anywhere                 
[ 3] 22/tcp (v6)                ALLOW IN    Anywhere (v6)           
[ 4] 31444 (v6)                ALLOW IN    Anywhere (v6)

salatbieger@kiste:~$ sudo ufw delete 1
Deleting:
allow 22/tcp
Proceed with operation (y|n)? y
Rule deleted
salatbieger@kiste:~$ sudo ufw status numbered
Status: active

    To                        Action      From
    --                        ------      ----
[ 1] 31444                      ALLOW IN    Anywhere                 
[ 2] 22/tcp (v6)                ALLOW IN    Anywhere (v6)           
[ 3] 31444 (v6)                ALLOW IN    Anywhere (v6)           

salatbieger@kiste:~$ sudo ufw delete 2
Deleting:
allow 22/tcp
Proceed with operation (y|n)? y
Rule deleted (v6)
salatbieger@kiste:~$ sudo ufw status numbered
Status: active

    To                        Action      From
    --                        ------      ----
[ 1] 31444                      ALLOW IN    Anywhere                 
[ 2] 31444 (v6)                ALLOW IN    Anywhere (v6)           

salatbieger@kiste:~$ sudo ufw reload

Firewall reloaded

salatbieger@kiste:~$

Setup MySQL:

sudo apt update

sudo apt install mysql-server

sudo mysql_secure_installation

new passwort vergessen

ALTER USER 'root'@'localhost' IDENTIFIED WITH caching_sha2_password BY 'bienemaja';

CREATE USER 'opsops'@'localhost' IDENTIFIED WITH mysql_native_password BY 'wiewardasnoch';

GRANT ALL PRIVILEGES ON *.* TO 'opsops'@'localhost' WITH GRANT OPTION;

FLUSH PRIVILEGES;

Für OpenSim geht nur das mysql_native_password Authentifizierungsverfahren!

Authentifizierungsverfahren prüfen:

SELECT user,authentication_string,plugin,host FROM mysql.user;

Datenbanken anlegen:

mysql> create database sumsum1;
Query OK, 1 row affected (0,34 sec)

mysql> create database sumsum2;
Query OK, 1 row affected (0,21 sec)

mysql> create database sumsum3;
Query OK, 1 row affected (0,18 sec)

mysql> create database sumsum4;
Query OK, 1 row affected (0,10 sec)

mysql> create database sumsum5;
Query OK, 1 row affected (0,12 sec)


Neue Anmeldung bei mysql nun wie folgt:

mysql -u root -p

exit

sudo nano /etc/mysql/mysql.conf.d/mysqld.cnf

Hinzufügen:

ssl=0
skip_ssl
default-authentication-plugin=mysql_native_password

salatbieger@kiste:~$ sudo reboot

Neu einloggen:

ssh salatbieger@LAN-IP-Adresse -p31444

sudo apt update

sudo apt upgrade

Ubuntu 20.04 Mono installieren:

sudo apt install gnupg ca-certificates
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb https://download.mono-project.com/repo/ubuntu stable-focal main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list
sudo apt update

sudo apt install mono-complete

Nach dieser Operation werden 466 MB Plattenplatz zusätzlich benutzt.

mono --version

Mono JIT compiler version 6.12.0.122 (tarball Mon Feb 22 17:33:28 UTC 2021)
Copyright © 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
TLS:          __thread
SIGSEGV:      altstack
Notifications: epoll
Architecture:  amd64
Disabled:      none
Misc:          softdebug
Interpreter:  yes
LLVM:          yes(610)
Suspend:      hybrid
GC:            sgen (concurrent by default)


sudo reboot

... wird fortgesetzt
All done!
Zitieren


Gehe zu:


Benutzer, die gerade dieses Thema anschauen: 1 Gast/Gäste