I can not connect to the Zabbix data source - Could not connect to given url

We use LDAP authentication in Apache for access to https:///zabbix, and I am in doubt if it is because of LDAP that I am not able to configure the data source for Zabbix.

When I set the form down, the message: Could not connect to given url

URL: https: // webserver /zabbix/api_jsonrpc.php
Access: Browser

Also tried:

URL: https: // web-server-ip /zabbix/api_jsonrpc.php
Access: Browser

And when I configure it as below, the message: Connection failed: Basic auth failed.

URL: https: // webserver /zabbix/api_jsonrpc.php
Access: Server (Default)
Basic Auth: unmarked

Also tried:

URL: https: // webserver /zabbix/api_jsonrpc.php
Access: Server (Default)

Basic Auth: marked
User: my-ldap-user
Password: my-ldap-password

For the two cases I also filled in:

Zabbix API details

Username: Admin
Password: password
Trends: Marked

I managed to make it work! I enabled LDAP in conf / custom.ini, and put the same Apache credentials in ldap.toml. I restarted the grafana-server.

Glad you got iot working. I was going to suggest looking at your DNS entry as well

I don’t remember how I managed to solve it haha. But today, on another Ubuntu Server 20.04 LTS and Apache 2.4 server, with Grafana configured with LDAP authentication, I can only access the Zabbix API file leaving, in the .htacces, like this:

<Files “api_jsonrpc.php”>
Require ip <zabbix_server_ip>
<//Files>

Because, even leaving Basic Auth or/and With Credentials, when clicking Save, it returns Unauthorized.