FreeBSD Admin: Difference between revisions

From Jan's Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 4: Line 4:
'''Ports'''
'''Ports'''
* Update outdated installed ports
* Update outdated installed ports
   portmaster -a
   portmaster -b -a
* List outdated ports
* List outdated ports
   pkg_version -vIL=
   pkg_version -vIL=

Revision as of 14:55, 20 December 2016

EZJail

  • Update ports:
  ezjail-admin update -P

Ports

  • Update outdated installed ports
  portmaster -b -a
  • List outdated ports
  pkg_version -vIL=
  • Uninstall all unused pkgs
pkg_cutleaves


Mail

  • sendmail from Jail

Sendmail im Jail mit Smarthost

Im Jail rennt nur ein 1 Sendmail, falls der Smarthost nicht erreichbar ist.

/etc/rc.conf

sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="YES"

/etc/mail/freebsd.submit.mc

dnl FEATURE(`msp')dnl
FEATURE(`msp',`[172.16.3.6]')dnl

submit.cf bauen und starten:

cd /etc/mail
make
make install
make start

Der Smarthost muss den Hostnamen des Jails kennen, z.B. in /etc/mail/local-host-names [1]

Fail2ban PF um IP Adressen zu blockieren - diese werden in Tabelle fail2ban eingetragen. Action pf-jan.conf entsprechend [2] anpassen.