Project

General

Profile

Actions

Enhancement #696

closed

New VM for sup/Zabbix

Added by Pierre-Louis Bonicoli almost 4 years ago. Updated almost 4 years ago.

Status:
Resolved
Priority:
Normal
Category:
Service :: Supervision
Start date:
2020-04-27
Due date:
% Done:

100%

Estimated time:
Patch Available:
Confirmed:
Yes
Branch:
add_new_host_zabbix-server
Entity:
DuckCorp
Security:
No
Help Needed:

Description

Zabbix service is currently hosted on Nicecity but this host doesn't provide the resources (mainly CPU, for example: load average: 8.64, 8.47, 8.08) required for Zabbix.

A solution would be to host Zabbix service on a dedicated virtual machine. This VM would be hosted on another server located at Condé.
Here is Orthos:
  • CPU: one core of the host (Intel i5-8600T) fully dedicated to this VM
  • memory: 2Go (can be extended to 4Go)
  • storage: 40Go
Branches:
  1. main repository
    1. add_new_host_zabbix-server: add Orthos to the inventory
    2. dependency_and_order: setup buster-backports before using it, install gpg binary
    3. mkcert_fix_RANDFILE_and_req_dn: fix name of section in template, unset RANDFILE
    4. TODO: Zabbix server: use Orthos
  2. ansible-role-fail2ban repository: buster_ignore_apt-listbugs: force installation of fail2ban package
Actions #1

Updated by Pierre-Louis Bonicoli almost 4 years ago

  • Description updated (diff)
  • Status changed from New to In Progress
Actions #2

Updated by Pierre-Louis Bonicoli almost 4 years ago

  • Description updated (diff)
Actions #3

Updated by Marc Dequènes almost 4 years ago

I reviewed add_new_host_zabbix-server and it's almost fine: data/duckcorp/interfaces/Orthos is missing, so if I reboot the machine to get the interface mapping created, then the network is going to be broken.

Actions #4

Updated by Marc Dequènes almost 4 years ago

I merged dependency_and_order, good catch.

Actions #5

Updated by Marc Dequènes almost 4 years ago

I merged mkcert_fix_RANDFILE_and_req_dn, thanks.

Actions #6

Updated by Marc Dequènes almost 4 years ago

merged buster_ignore_apt-listbugs; stumbled on it in #537 and totally forgot it, oops. Thanks you. Very elegant workaround only targeting this specific version, I really like it :-).

Actions #7

Updated by Pierre-Louis Bonicoli almost 4 years ago

Marc Dequènes wrote:

I reviewed add_new_host_zabbix-server and it's almost fine: data/duckcorp/interfaces/Orthos is missing, so if I reboot the machine to get the interface mapping created, then the network is going to be broken.

Updated: missing file has been added.

Actions #8

Updated by Pierre-Louis Bonicoli almost 4 years ago

Branch add_new_host_zabbix-server updated with another fix:

--- a/ansible/host_vars/Orthos/ssh.yml
+++ b/ansible/host_vars/Orthos/ssh.yml
@@ -1,4 +1,4 @@
 ---
 ssh:
-  port: 30001
+  port: 22  # NATED port
   listen_addresses:
Actions #9

Updated by Marc Dequènes almost 4 years ago

I see the interface has been added but DHCP is not acceptable for a server, we need a fixed IP and avoid dependencies on core services as much as possible to avoid loosing access.

As for the SSH fix, it has not been pushed. Anyway in this case this file is not necessary as it is the default config. If you wish to add a comment about the NAT then I would suggest to add it to connection.yml (but I think it's pretty obvious).

Actions #10

Updated by Pierre-Louis Bonicoli almost 4 years ago

  • % Done changed from 0 to 50

Marc Dequènes wrote:

I see the interface has been added but DHCP is not acceptable for a server, we need a fixed IP and avoid dependencies on core services as much as possible to avoid loosing access.

With the current setup, libvirt/dnsmasq will always return the same IP (192.168.100.2).

As for the SSH fix, it has not been pushed.

Indeed, pushed.

Anyway in this case this file is not necessary as it is the default config. If you wish to add a comment about the NAT then I would suggest to add it to connection.yml (but I think it's pretty obvious).

ansible/host_vars/Orthos/ssh.yml has been removed.

Actions #11

Updated by Pierre-Louis Bonicoli almost 4 years ago

Updated:

diff --git a/ansible/data/duckcorp/interfaces/Orthos/eth-lan b/ansible/data/duckcorp/interfaces/Orthos/eth-lan
index c927c65..def5f2b 100644
--- a/ansible/data/duckcorp/interfaces/Orthos/eth-lan
+++ b/ansible/data/duckcorp/interfaces/Orthos/eth-lan
@@ -1,3 +1,10 @@
 auto eth-lan
+
 allow-hotplug eth-lan
-iface eth-lan inet dhcp
+
+iface eth-lan inet static
+        address 192.168.100.2
+        netmask 255.255.255.248
+        network 192.168.100.0
+        broadcast 192.168.100.7
+        gateway 192.168.100.1

Actions #12

Updated by Marc Dequènes almost 4 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 50 to 100

It's fine, thanks. I just updated to use the CIDR to simplify (it calculates the other parameters automagically).

Actions

Also available in: Atom PDF