<p>Could you help me with resolving issue with accessing grafana UI on Kubernetes baremetall.
I have one master node with two worker nodes:</p>
<pre><code>NAME          STATUS   ROLES           AGE     VERSION   INTERNAL-IP       EXTERNAL-IP   OS-IMAGE                KERNEL-VERSION           CONTAINER-RUNTIME
master-node   Ready    control-plane   6d17h   v1.25.2   212.112.123.114   &lt;none&gt;        CentOS Linux 7 (Core)   3.10.0-1160.el7.x86_64   containerd://1.6.8
w-node1       Ready    worker          6d17h   v1.25.2   212.112.123.115   &lt;none&gt;        CentOS Linux 7 (Core)   3.10.0-1160.el7.x86_64   containerd://1.6.8
w-node2       Ready    worker          6d17h   v1.25.2   212.112.123.117   &lt;none&gt;        CentOS Linux 7 (Core)   3.10.0-1160.el7.x86_64   containerd://1.6.8
</code></pre>
<p>I have 3 static IP addresses for Nodes : 212.112.123.114, 212.112.123.115, 212.112.123.117
I have installed metallB on Kubernetes and Nginx Ingress</p>
<p>I have installed prometheus + grafana:</p>
<pre><code>k get pods -n monitoring
NAME                                   READY   STATUS    RESTARTS   AGE
alertmanager-main-0                    2/2     Running   0          15h
alertmanager-main-1                    2/2     Running   0          15h
alertmanager-main-2                    2/2     Running   0          15h
blackbox-exporter-569d5d4bb7-wc8rv     3/3     Running   0          15h
grafana-7f9bdfd769-l7cvs               1/1     Running   0          15h
kube-state-metrics-5bd9d9bf68-dkm6f    3/3     Running   0          15h
node-exporter-lnjhv                    2/2     Running   0          15h
node-exporter-wcc5r                    2/2     Running   0          15h
node-exporter-xh2xn                    2/2     Running   0          15h
prometheus-adapter-867598997b-f94x5    1/1     Running   0          15h
prometheus-adapter-867598997b-pnq6x    1/1     Running   0          15h
prometheus-k8s-0                       2/2     Running   0          15h
prometheus-k8s-1                       2/2     Running   0          15h
prometheus-operator-7b64d465b9-pd6cj   2/2     Running   0          15h
</code></pre>
<pre><code>k get svc -n monitoring
NAME                    TYPE           CLUSTER-IP      EXTERNAL-IP    PORT(S)                         AGE
alertmanager-main       LoadBalancer   10.97.81.41     192.168.1.12   9093:31134/TCP,8080:31016/TCP   15h
alertmanager-operated   ClusterIP      None            &lt;none&gt;         9093/TCP,9094/TCP,9094/UDP      15h
blackbox-exporter       ClusterIP      10.110.121.18   &lt;none&gt;         9115/TCP,19115/TCP              15h
grafana                 LoadBalancer   10.103.36.246   192.168.1.13   3000:31657/TCP                  15h
kube-state-metrics      ClusterIP      None            &lt;none&gt;         8443/TCP,9443/TCP               15h
node-exporter           ClusterIP      None            &lt;none&gt;         9100/TCP                        15h
prometheus-adapter      ClusterIP      10.102.62.25    &lt;none&gt;         443/TCP                         15h
prometheus-k8s          LoadBalancer   10.100.34.90    192.168.1.11   9090:32619/TCP,8080:30045/TCP   15h
prometheus-operated     ClusterIP      None            &lt;none&gt;         9090/TCP                        15h
prometheus-operator     ClusterIP      None            &lt;none&gt;         8443/TCP                        15h
</code></pre>
<p>but when i tried to check grafana with nodeIP:LBPort it stuck,
also i tried to create nginx ingress but the same issue:</p>
<pre><code>apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  annotations:
    nginx.ingress.kubernetes.io/rewrite-target: /$2
  name: ingress-monitoring
  namespace: monitoring
spec:
  ingressClassName: nginx-monitoring
  rules:
  - http:
      paths:
      - backend:
          service:
            name: grafana
            port:
              number: 31657
        path: /monitoring(/|$)(.*)
        pathType: Prefix
</code></pre>
<p>it's always stuck,
but if i create any pod or deployment and then create nginx ingress for that it works successfully</p>

Akylson
<p>Try doing port forwarding to your local to confirm that your grafana is working and accepting traffic. You can use below command for port forwarding:</p>
<pre><code>kubectl -n monitoring port-forward pods/grafana-7f9bdfd769-l7cvs 3000:3000
</code></pre>
<p>In your local, open browser and go to <a href="http://127.0.0.1:3000" rel="nofollow noreferrer">http://127.0.0.1:3000</a></p>
<p>If grafana pod is working and ports are open, then you should see the grafana UI. If not, then you should start with confirming the port access. For that you can use netcat or any tools to check whether the port is blocked or not.</p>
<p>If its all good, you should check the ELB port mapping to your app.
For reference: <a href="https://community.grafana.com/t/cant-access-grafana-web-interface-trought-port-3000/16661" rel="nofollow noreferrer">https://community.grafana.com/t/cant-access-grafana-web-interface-trought-port-3000/16661</a></p>
<p>Regarding the ingress not working for grafana, change the port to 3000 as shown below</p>
<pre><code>- backend:
    service:
      name: grafana
      port:
        number: 3000
</code></pre>
<p>Hope it helps!</p>
