Diferencias
Muestra las diferencias entre dos versiones de la página.
| Próxima revisión | Revisión previa | ||
|
instalacion_y_configuracion_de_zabbix [2016/05/12 11:20] 10.12.12.129 creado |
instalacion_y_configuracion_de_zabbix [2017/03/27 17:44] (actual) |
||
|---|---|---|---|
| Línea 14: | Línea 14: | ||
| ===== Configuracion ===== | ===== Configuracion ===== | ||
| + | |||
| + | Para acceder a la máquina, el usuario por defecto es: | ||
| + | |||
| + | appliance :: zabbix | ||
| + | |||
| + | Para acceder con el usuario root: | ||
| + | |||
| + | sudo su | ||
| ==== Añadiendo repositorios Zabbix ==== | ==== Añadiendo repositorios Zabbix ==== | ||
| Línea 23: | Línea 31: | ||
| deb-src http://repo.zabbix.com/zabbix/3.0/ubuntu trusty main | deb-src http://repo.zabbix.com/zabbix/3.0/ubuntu trusty main | ||
| + | ==== Firewall ==== | ||
| + | |||
| + | El appliance está preparado para aceptar tráfico sobre: | ||
| + | |||
| + | The appliance uses iptables firewall with predefined rules: | ||
| + | |||
| + | Opened SSH port (22 TCP); | ||
| + | Opened Zabbix agent (10050 TCP) and Zabbix trapper (10051 TCP) ports; | ||
| + | Opened HTTP (80 TCP) and HTTPS (443 TCP) ports; | ||
| + | Opened SNMP trap port (162 UDP); | ||
| + | Opened outgoing connections to NTP port (53 UDP); | ||
| + | ICMP pakets limited to 5 packets per second; | ||
| + | All other incoming connections are dropped. | ||
| + | |||
| + | En caso de necesitar modificar algo: | ||
| + | |||
| + | /etc/iptables/rules.v4 | ||
| + | /etc/iptables/rules.v6 | ||
| + | | ||
| + | Recargar reglas: | ||
| + | |||
| + | service iptables-persistent reload | ||
| + | | ||
| + | Arrancar y parar firewall: | ||
| + | |||
| + | service iptables-persistent restart | ||
| + | | ||
| + | ==== Modificar configuración de red ==== | ||
| + | |||
| + | Por defecto, el appliance viene configurado para actuar en modo DHCP. Si deseamos asignar una IP manualmente este es el procedimiento: | ||
| + | |||
| + | sudo su | ||
| + | vim /etc/network/interfaces | ||
| + | iface eth0 inet dhcp → iface eth0 inet static | ||
| + | | ||
| + | Añadir las siguientes lineas: | ||
| + | |||
| + | address <IP address of the appliance> | ||
| + | netmask <network mask> | ||
| + | gateway <your gateway address> | ||
| + | |||
| + | Tumbamos y levantamos la interfaz: | ||
| + | |||
| + | ifdown eth0 && sudo ifup eth0 | ||
| + | | ||
| + | Ahora que tenemos IP fija, podemos añadirla a nuestra zona DNS. | ||
| + | Accedemos a gorgoroth y modificamos bind: | ||
| + | |||
| + | cd /etc/bind | ||
| + | vim db.merkatu | ||
| + | |||
| + | Añadimos la linea | ||
| + | zabbix IN A 10.12.13.X | ||
| + | |||
| + | Reiniciamos bind | ||
| + | /etc/init.d/bind9 restart | ||
| + | | ||
| + | ==== Cambiamos Zona horaria ==== | ||
| + | |||
| + | cp /usr/share/zoneinfo/Europe/Madrid /etc/localtime | ||
| + | | ||
| + | ==== Localización de ficheros ==== | ||
| + | |||
| + | Configuration files are placed in /etc/zabbix. | ||
| + | |||
| + | Zabbix server, proxy and agent logfiles are placed in /var/log/zabbix. | ||
| + | |||
| + | Zabbix frontend is placed in /usr/share/zabbix. | ||
| + | |||
| + | Home directory for user zabbix is /var/lib/zabbix. | ||
| + | |||
| + | ==== Accediendo al FrontEnd ==== | ||
| + | |||
| + | Configuramos Apache: | ||
| + | |||
| + | vim /etc/apache2/conf-available/zabbix.conf | ||
| + | |||
| + | Reiniciamos apache: | ||
| + | service apache2 restart | ||
| + | | ||
| + | Accedemos al Front con un navegador: | ||
| + | http://IP/zabbix | ||
| + | |||
| + | En nuestro caso: | ||
| + | [[http://zabbix.merkatu.info/zabbix]] | ||
| + | | ||
| + | Para el acceso desde el exterior se ha creado una regla en gorgoroth redireccionando el purto 8888 a nuestro servidor Zabbix. Recuerda que hay que añadirlo como puerto de escucha de apache en ports.conf. De esta forma, desde fuera podemos acceder en la siguiente URL: | ||
| + | [[http://zabbix.merkatu.info:8888/zabbix]] | ||
| + | |||
| + | |||
| + | | ||
| + | ==== Actualizar paquetes Zabbix ==== | ||
| + | |||
| + | sudo apt-get --only-upgrade install zabbix* | ||