Zabbix Web Monitoring without interfaces - monitoring

I want to send HTTP request to a website where I can't deploy a Zabbix agent. I can only access the website via HTTP / HTTPS.
I created a host, but I had to setup a false interface (I wrote Zabbix Agent / the website DNS and port 10050). Consequently, the status is "Red" as Zabbix Server cannot connect to the agent.
How can I set up an agent without any interfaces, or more precisely, without triggering a "Red" status on the host ? In my situation, is there any way to get a "Green" status on the host ?
Zabbix version : 3.2.11

At least one interface is mandatory. Using 127.0.0.1 the status is Enabled, green. I'm using Zabbix 4 here.

Hosts in Zabbix must have at least one interface. That interface does not have to be used.
If you see the red "Z" and an error about contacting the agent, this means that you have created Zabbix agent items on that host (directly or via linking some template).
As those items do not work, it would be best to remove them.
See http://www.zabbixbook.com/2016/11/22/can-i-have-a-host-without-interfaces/ for more information.

Related

edited how to make nginx pont to my mosquitto broker in docker [duplicate]

I have a server and I am using Ubuntu 20.04, nginx , mosquitto and node-red and docker , let's call the website http://mywebsite.com. The problem that I am facing that I have created a client lets call it client1 in docker so the URL will be http://mywebsite.com/client1
and I want to establish an MQTT connection via mosquitto and I'm sending the data on topic test
The problem that on node red node of MQTT when I write the IP address of my mosquitto container it works
But if I change the IP address 192.144.0.5 with mywebsite.com/client1 I can't connect to mosquitto and I can't send or receive any form of data
any idea on how to solve this problem
OK, you are going to have several problems here.
You can not do path based proxying with MQTT. If you want to have multiple MQTT brokers (1 per client) bound to a single public facing domain/IP address then they are all going to have to run on separate ports (other than the default 1883).
Nginx can do MQTT protocol proxying (e.g. like this), so you can use this to expose the different ports and forward them to the separate instances of mosquitto, but even if you had a different hostname (all pointing at the same IP address) nginx has no way to know which host name was used because there is no equivalent to the HOST HTTP header to direct it. If you were to use MQTT with TLS then you may be able to get it to work with SNI, but I've never seen anybody do that yet (possible docs for SNI based routing here) It works, explanation about how to do it here.
If you use MQTT over Websockets then you should be able to use hostname based routing.
Path based proxying for Node-RED currently doesn't work properly if you enable admin authentication, because the admin auth tokens are currently stored in browser local storage and only scoped to the hostname, not the hostname + path. This will mean that a client will only ever be able to log into one instance at a time.
You can work round this by using host based proxying, e.g. http://client1.mywebsite.com
A fix for this is on the backlog for Node-RED, probably (no promises) to be looked at after version 1.2.0 ships

Active zabbix agents are becoming unavailable due to DHCP IP change

I am using active Zabbix agents that auto-register themselves to the Zabbix server.
Everything goes well until the DHCP changes the host IP, the host then becomes unavailable in Zabbix... Looking at the host under the hosts list in Zabbix frontend, I can see that it had the old IP.
Is there any way to solve this?
This means that you are actually not using active items. I'd suggest cloning your current template and changing items, LLD rules and LLD prototypes to "Zabbix agent (active)" - then agent IP address changes will not be a concern.

Issues with Jenkins 1.67 URL set up

I am trying to set a new Jenkins instance (version 1.67) on to a Windows Server 2012 r2.
I am trying to configure a custom URL instead of using
localhost:8080
etc..
I have set Jenkins URL as
NewServer.domainname.com
But I cannot access it via that url, I get presented with a message "Remote Web Access is turned off" it only allows me to connect when I follow the URL with the port number;
NewServer.domainname.com:8080
I am sure that Remote web access is completely different from what my goal is.
By default, Jenkins launches its own built-in webserver, listening on port 8080.
Changing the URL in the Jenkins configuration does not change the port that the running webserver listens on, but rather the URL that is shown within the UI, or in emails sent to users etc.
In order to access Jenkins at just NewServer.domainname.com (i.e. running on port 80), you would first have to disable Windows Remote Web Access, which is currently occupying port 80.
You would then need to stop Jenkins and start it again with the flag --httpPort=80; these options are documented on the Jenkins wiki.
If Jenkins was started as a Windows Service, you can edit the jenkins.xml file as shown in these answers.
Just wanted to say, after setting Jenkins.xml to run on port 80, and then via the Jenkins web interface using
'install as service'
I found that this process seemed to create a new jenkins.xml along with the default httpPort which is stored within the Jenkins.war.
I get around this I installed as a service, ensured that the service was not set to start on start up. Rebooted the machine
On start up I re-edited the jenkins.xml httpPort value back to 80. Started the service and now running very happy!

Received empty response from Zabbix Agent

I have zabbix installed on my wan ip and I'm able to add clients in that of same Wan Ip network, But when i'm trying to add a zabbix client of different Wan network range, i'm getting -
Received empty response from Zabbix Agent at [xx.xx.xx.xx]. Assuming
that agent dropped connection because of access permission.
There is no filtering at any end, and i have cross checked zabbix_agentd.conf file may times and found no errors. I can see ports listening at 10050 on client servers.
The Troubleshooting page on Zabbix.org is a classical reference for troubleshooting unreachable agents.
In this particular case, you might wish to start with checking that Zabbix server IP is listed in agent's Server configuration parameter.
I have solved the above problem. it was my router's wan ip that was collecting the data from zabbix agent and not the zabbix server's wan ip.
so i gave both the ips of my router as well as of zabbix server in zabbix_agentd.conf's Server and ServerActive . and now its working fine.
Thanks

Jenkins Server - Issues with setting URL

I am trying to set up an internal Jenkins server for our QA team and facing some issues with the server URL. This is inside a corporate network and all sort of firewall and proxy settings are in place, however we need to access the server only with in our internal network. This server runs from a Mac Mini. I was able to install and access the server without any issues using localhost:8080.
I tried to set a custom URL (something like testjenkins.local:8080)under the Manage Jenkins option and never was able to access the server. The only option worked for me is with the IP address (IP:8080). I was able to access the server from other machines in the network using this URL.
The real problem with the above setup is that the machine IP changes(I am not able to make it static), and hence wont be able to get an always working URL.
Highly appreciate if any one guide me in the wright direction.
Given you have a dynamic IP on your server, a good alternative would be using ngrok. Ngrok can expose the port 8080 of that server to the internet via secure tunnels, and you can access it via an URL, so changes in the IP won't affect it.
However, ngrok exposes the server to the whole Internet. To make it accessible only for your team you can add authentication in both ngrok tunnel and Jenkins server (would it work for you?).

Resources