Unser Raspberry hat folgenden funktionalen Aufbau:
Das System ist ein Linux mit
alfred@monitoring:~$ uname -a
Linux monitoring.slainte.at 5.4.0-1026-raspi #29-Ubuntu SMP PREEMPT Mon Dec 14 17:01:16 UTC 2020 aarch64 aarch64 aarch64 GNU/Linux
Das Trägerssystem Ubuntu ist ein
alfred@monitoring:~$ cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.1 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.1 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal
Die Standardkomponenten sind
Webserver Apache mit Konfiguration in /etc/apache2
Im Webserver ist SVN mit WebDav aktiviert.
Datenbank mariadb mit Konfiuguration in /etc/mysql
Als Individualsoftware sind derzeit die folgenden Skripten aktiv:
# m h dom mon dow command
0 0 * * 0 certbot renew > /dev/null 2>&1
0 1 * * * /root/backup_mariadb.sh > /var/log/cron/backup_mariadb.cron 2>&1
0 3 * * * /root/cron_apt_get.sh > /var/log/cron/cron_apt_get.cron 2>&1
0 4 * * * /root/rsync_root_monitoring.sh /mnt/rasp/backup > /var/log/cron/rsync_root_monitoring.cron 2>&1
0 5 * * * /root/rsync_remote_host.sh Diese E-Mail-Adresse ist vor Spambots geschützt! Zur Anzeige muss JavaScript eingeschaltet sein!:/opt/backup /mnt/rasp/slainte > /var/log/cron/rsync_remote_host_slainte.at.cron 2>&1
Root hat einen ssh-copy-id auf Diese E-Mail-Adresse ist vor Spambots geschützt! Zur Anzeige muss JavaScript eingeschaltet sein!.
Die Plattenkonfiguration ist
root@monitoring:~# df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.8G 0 3.8G 0% /dev
tmpfs 782M 4.1M 778M 1% /run
/dev/mmcblk0p2 117G 8.7G 104G 8% /
tmpfs 3.9G 0 3.9G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/loop0 49M 49M 0 100% /snap/core18/1883
/dev/loop1 49M 49M 0 100% /snap/core18/1949
/dev/loop2 60M 60M 0 100% /snap/lxd/18152
/dev/loop4 27M 27M 0 100% /snap/snapd/10494
/dev/loop5 27M 27M 0 100% /snap/snapd/10709
/dev/mmcblk0p1 253M 96M 157M 38% /boot/firmware
/dev/mapper/Toshiba 916G 16G 854G 2% /mnt/rasp
/dev/loop6 62M 62M 0 100% /snap/lxd/19040
tmpfs 782M 0 782M 0% /run/user/1001
/dev/mmcblk0p2
ist die Systemplatte.
Zusätzlich habe ich mit /dev/mapper/Toshiba
noch eine 1TB-Platte als Backup drangehängt. Diese Backupplatte dient auch als NAS-Storage in meinem Intranet zu Hause. In der Regel wird diese Platte dann als ssh-mount eingebunden (und lokale Backups wie z.b. DejaDup https://de.wikipedia.org/wiki/Duplicity_(Software) werden direkt auf diese Platte geschrieben).
Auch Backups des slainte-Servers landen dort (z.b. Datenbank-backups).
Die Firewallkonfiguration ist wie folgt:
root@monitoring:~# ufw status verbose
Status: active
Logging: on (low)
Default: deny (incoming), allow (outgoing), disabled (routed)
New profiles: skip
To Action From
-- ------ ----
22/tcp (OpenSSH) ALLOW IN Anywhere
80,443/tcp (Apache Full) ALLOW IN Anywhere
5665/tcp (Icinga) ALLOW IN Anywhere
22/tcp (OpenSSH (v6)) ALLOW IN Anywhere (v6)
80,443/tcp (Apache Full (v6)) ALLOW IN Anywhere (v6)
5665 (v6) ALLOW IN Anywhere (v6)
5665/tcp (Icinga (v6)) ALLOW IN Anywhere (v6)
Von aussen erreichbar ist dennoch nur port 80/443 und 5665. Denn davor gibt es noch meinen Router mit Firewallfunktionalität, der wie folgt eingestellt ist:
Service Port | IP Adress | Internal Port | Protocol | Status |
80 | 192.168.0.113 | 80 | TCP or UDP | Enabled |
443 | 192.168.0.113 | 443 | TCP or UDP | Enabled |
5665 | 192.168.0.113 | 5665 | TCP or UDP | Enabled |
Somit sind manche Services (z.b. ssh) nur von intern erreichbar.
Im Apache sind aber auch svn, PhpAdmin usw. nur intern sichtbar.
Von aussen sichtbar ist https://monitoring.slainte.at und https://monitoring.slainte.at/icingaweb2/