From 476f9ab8e97a7a87592a1b7b1bdb3940d3f9133c Mon Sep 17 00:00:00 2001 From: Alexander Schomburg Date: Thu, 4 Sep 2014 17:02:30 +0200 Subject: [PATCH] Differentiate between service and systemctl Some parts of the documentation still don't differentiate between RHEL7 and RHEL6/Debian/SUSE. fixes #7080 Signed-off-by: Gunnar Beutner --- doc/2-getting-started.md | 44 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/doc/2-getting-started.md b/doc/2-getting-started.md index 8eeffd4c0..3f3cf8f5a 100644 --- a/doc/2-getting-started.md +++ b/doc/2-getting-started.md @@ -32,6 +32,7 @@ You need to add the Icinga repository to your package management configuration. Below is a list with examples for the various distributions. Debian (debmon): + # wget -O - http://debmon.org/debmon/repo.key 2>/dev/null | apt-key add - # cat >/etc/apt/sources.list.d/debmon.list< Installing MySQL database server Debian/Ubuntu: + # apt-get install mysql-server mysql-client RHEL/CentOS 5/6: + # yum install mysql-server mysql # chkconfig mysqld on # service mysqld start RHEL/CentOS 7 and Fedora 20 prefer MariaDB over MySQL: + # yum install mariadb-server mariadb # systemctl enable mariadb.service # systemctl start mariadb.service SUSE: + # zypper install mysql mysql-client # chkconfig mysqld on # service mysqld start @@ -563,19 +576,23 @@ RHEL based distributions do not automatically set a secure root password. Do tha #### Installing PostgreSQL database server Debian/Ubuntu: + # apt-get install postgresql RHEL/CentOS 5/6: + # yum install postgresql-server postgresql # chkconfig postgresql on # service postgresql start RHEL/CentOS 7 and Fedora 20 use [systemd](#systemd-service): + # yum install postgresql-server postgresql # systemctl enable postgresql.service # systemctl start postgresql.service SUSE: + # zypper install postgresql postgresql-server # chkconfig postgresql on # service postgresql start @@ -636,8 +653,13 @@ You can enable the `ido-mysql` feature configuration file using `icinga2-enable- After enabling the ido-mysql feature you have to restart Icinga 2: +Debian/Ubuntu, RHEL/CentOS 6 and SUSE: + # service icinga2 restart +RHEL/CentOS 7 and Fedora 20: + + # systemctl restart icinga2.service ### Configuring DB IDO PostgreSQL @@ -717,8 +739,14 @@ You can enable the `ido-pgsql` feature configuration file using `icinga2-enable- After enabling the ido-pgsql feature you have to restart Icinga 2: +Debian/Ubuntu, RHEL/CentOS 6 and SUSE: + # service icinga2 restart +RHEL/CentOS 7 and Fedora 20: + + # systemctl restart icinga2.service + ### Setting Up External Command Pipe @@ -731,8 +759,14 @@ You can enable the External Command Pipe using icinga2-enable-feature: After that you will have to restart Icinga 2: +Debian/Ubuntu, RHEL/CentOS 6 and SUSE: + # service icinga2 restart +RHEL/CentOS 7 and Fedora 20: + + # systemctl restart icinga2.service + By default the command pipe file is owned by the group `icingacmd` with read/write permissions. Add your webserver's user to the group `icingacmd` to enable sending commands to Icinga 2 through your web interface: @@ -775,8 +809,14 @@ You can enable Livestatus using icinga2-enable-feature: After that you will have to restart Icinga 2: +Debian/Ubuntu, RHEL/CentOS 6 and SUSE: + # service icinga2 restart +RHEL/CentOS 7 and Fedora 20: + + # systemctl restart icinga2.service + By default the Livestatus socket is available in `/var/run/icinga2/cmd/livestatus`. In order for queries and commands to work you will need to add your query user @@ -829,22 +869,26 @@ as web server. Debian/Ubuntu packages will automatically fetch and install the required packages. RHEL/CentOS/Fedora: + # yum install httpd # chkconfig httpd on && service httpd start ## RHEL7 # systemctl enable httpd && systemctl start httpd SUSE: + # zypper install apache2 # chkconfig on && service apache2 start #### Firewall Rules Example: + # iptables -A INPUT -p tcp -m tcp --dport 80 -j ACCEPT # service iptables save RHEL/CentOS 7 specific: + # firewall-cmd --add-service=http # firewall-cmd --permanent --add-service=http -- 2.40.0