Grafana.ini not loading

I’m not sure /etc/grafana/grafana.ini is loading. I wanted to implement https for Grafana and made the what I think necessary changes (e.g. protocol, cert, keys) and when I restart the server (sudo service grafana-server restart) it looks like the server still listens to http.
So I did a test and changed the port to 3001 instead of 3000 and the Grafana instance still responded to port 3000.

How do I check with config file is used? Even though from the status output it looks like the file used that I’m updating it looks like in reality that’s not the case.

> ● grafana-server.service - Grafana instance
>      Loaded: loaded (/lib/systemd/system/grafana-server.service; enabled; vendor preset: enabled)
>      Active: active (running) since Thu 2020-06-04 23:13:22 UTC; 4min 38s ago
>        Docs: http://docs.grafana.org
>    Main PID: 25439 (grafana-server)
>       Tasks: 7 (limit: 1145)
>      Memory: 17.7M
>      CGroup: /system.slice/grafana-server.service
>              └─25439 /usr/sbin/grafana-server --config=/etc/grafana/grafana.ini --pidfile=/var/run/grafana/grafana-server.pid --packaging=deb cfg:default.paths.logs=/var/log/grafana cfg:default.paths.data=/var/lib/grafana cfg:>
> 
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Path Plugins" logger=settings path=/var/lib/grafana/plugins
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Path Provisioning" logger=settings path=/etc/grafana/provisioning
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="App mode production" logger=settings
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Writing PID file" logger=server path=/var/run/grafana/grafana-server.pid pid=25439
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Connecting to DB" logger=sqlstore dbtype=sqlite3
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Starting DB migration" logger=migrator
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Starting plugin search" logger=plugins
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Registering plugin" logger=plugins name="Direct Input"
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="Registering plugin" logger=plugins name=Histogram
> Jun 04 23:13:22 ip-172-31-14-87 grafana-server[25439]: t=2020-06-04T23:13:22+0000 lvl=info msg="HTTP Server Listen" logger=http.server address=[::]:3000 protocol=http subUrl= socket=

It would be helpful if you posted here the relevant section/s of your file, so
we can see whether the changes you made look reasonable.

For example, both ; and # indicate comment lines, so any modification you make
to a line starting with one of those symbols will have no effect. You need to
remove the symbol as well for Grafana to use the setting.

If that’s not the problem, then post the non-comment lines from any stanzas
you have adjusted so we can give you an opinion.

Regards,

Antony.