CentOS 8: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
| Zeile 87: | Zeile 87: | ||
systemctl restart fail2ban | systemctl restart fail2ban | ||
systemctl restart sshd | systemctl restart sshd | ||
| + | </pre> | ||
| + | |||
| + | *Statusabfrage* | ||
| + | <pre> | ||
| + | fail2ban-client status | ||
| + | Status | ||
| + | |- Number of jail: 1 | ||
| + | `- Jail list: sshd | ||
</pre> | </pre> | ||
Version vom 11. Oktober 2020, 07:57 Uhr
chrony
# chrony tracking Reference ID : BC44355C (tor-relais2.link38.eu) Stratum : 3 Ref time (UTC) : Fri Oct 04 10:01:42 2019 System time : 0.000004382 seconds fast of NTP time Last offset : -0.004034238 seconds RMS offset : 0.004034238 seconds Frequency : 1.807 ppm fast Residual freq : -681.512 ppm Skew : 11.315 ppm Root delay : 0.036042333 seconds Root dispersion : 0.034783933 seconds Update interval : 1.8 seconds Leap status : Normal
# chronyc sources 210 Number of sources = 3 MS Name/IP address Stratum Poll Reach LastRx Last sample =============================================================================== ^+ tor-relais2.link38.eu 2 6 377 25 -23us[ +745us] +/- 21ms ^* v35005.php-friends.de 2 6 377 24 +922us[+1691us] +/- 13ms ^+ stratum2-3.NTP.TechFak.N> 2 6 377 24 -874us[ -105us] +/- 19ms
PowerTools Repository
yum install epel-release yum config-manager --set-enabled PowerTools
cockpit
# dny -y install cockpit # systemctl enable --now cockpit.socket # firewall-cmd --add-service=cockpit --permanent # firewall-cmd --reload
rename interface devices
Siehe systemd.link Manpage
Verzeichnis /etc/systemd/network anlegen
mkdir /etc/systemd/network
und dort eine Datei 10-net0.link mit folgenden Inhalt anlegen
vi /etc/systemd/network/10-net9.link [Match] MACAddress=00:a0:de:63:7a:e6 [Link] Name=net0
secure sshd with fail2ban
zuerst wird fail2ban installiert
dnf install fail2ban
anschließend eine lokale Konfigurationsdatei erzeugt.
vi /etc/fail2ban/jail.local [DEFAULT] bantime = 1d findtime = 300 maxretry = 3 banaction = iptables-multiport backend = systemd [sshd] enabled = true
und danach fail2ban und sshd restartet.
systemctl restart fail2ban systemctl restart sshd
- Statusabfrage*
fail2ban-client status Status |- Number of jail: 1 `- Jail list: sshd