ISPConfig/Installation/Basis: Unterschied zwischen den Versionen

Aus Foxwiki
KKeine Bearbeitungszusammenfassung
KKeine Bearbeitungszusammenfassung
Zeile 95: Zeile 95:


[[Category:Linux:Server:ISPConfig]]
[[Category:Linux:Server:ISPConfig]]
[[Kategorie:Linux:Distribution:Debian]]

Version vom 14. Februar 2022, 12:53 Uhr

Debian server installation

  • with Apache2, BIND, Dovecot
  • install ISPConfig

The web hosting control panel ISPConfig allows you to configure the following services through a web browser: Apache or nginx web server, Postfix mail server, Courier or Dovecot IMAP/POP3 server, MySQL, BIND or MyDNS nameserver, PureFTPd, SpamAssassin, ClamAV, and many more.

This setup covers Apache (instead of nginx), BIND, and Dovecot.

Preliminary Note

In this tutorial, I will use the hostname server1.

  • example.com with the IP address 192.168.0.100 and the gateway 192.168.0.1.
  • These settings might differ for you, so you have to replace them where appropriate.
  • Before proceeding further you need to have a minimal installation of Debian 10.
  • This might be a Debian minimal image from your Hosting provider or you use the Minimal Debian Server tutorial to set up the base system.
  • All commands below are run as root user.
  • Either log in as root user directly or log in as your normal user and then use the command
$ su -

to become root user on your server before you proceed.

IMPORTANT: You must use 'su -' and not just 'su', otherwise your PATH variable is set wrong.

SSH server

If you did not install the OpenSSH server during the system installation, you can do it now:

# apt install ssh openssh-server

From now on you can use an SSH client such as PuTTY and connect from your workstation to your Debian 9 server and follow the remaining steps from this tutorial.

Text editor

# apt install vim

Configure the Hostname

The hostname of your server should be a subdomain like "server1.example.com". Do not use a domain name without subdomain part like "example.com" as hostname as this will cause problems later with your mail setup. First, you should check the hostname in /etc/hosts and change it when necessary. The line should be: "IP Address - space - full hostname incl. domain - space - subdomain part". For our hostname server1.example.com, the file shall look like this:

# vi /etc/hosts
127.0.0.1       localhost.localdomain   localhost
192.168.0.100   server1.example.com     server1

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

Then edit the /etc/hostname file:

# vi /etc/hostname

It shall contain only the subdomain part, in our case:

server1

Finally, reboot the server to apply the change:

# systemctl reboot

Log in again and check if the hostname is correct now with these commands:

# hostname
# hostname -f

The output shall be like this:

# root@server1:/tmp# hostname
server1
# root@server1:/tmp# hostname -f
server1.example.com

Update Installation

First, make sure that your /etc/apt/sources.list contains the buster/updates repository (this makes sure you always get the newest security updates), and that the contrib and non-free repositories are enabled as some required packages are not in the main repository.

# vi /etc/apt/sources.list
deb http://deb.debian.org/debian/ buster main contrib non-free
deb-src http://deb.debian.org/debian/ buster main contrib non-free
deb http://security.debian.org/debian-security buster/updates main contrib non-free
deb-src http://security.debian.org/debian-security buster/updates main contrib non-free

Run:

# apt update

To update the apt package database

# apt upgrade

and to install the latest updates (if there are any).

Change the Default Shell

/bin/sh is a symlink to /bin/dash, however we need /bin/bash, not /bin/dash. Therefore, we do this:

# dpkg-reconfigure dash
Use dash as the default system shell (/bin/sh)? <-- No

If you don't do this, the ISPConfig installation will fail.

Synchronize the System Clock

It is a good idea to synchronize the system clock with an NTP (network time protocol) server over the Internet. Simply run

# apt install ntp

and your system time will always be in sync.

Links

Intern

TODO

Extern

TODO