Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

grafana-server.service not found #3

Closed
souvikhaldar opened this issue Feb 18, 2019 · 2 comments
Closed

grafana-server.service not found #3

souvikhaldar opened this issue Feb 18, 2019 · 2 comments

Comments

@souvikhaldar
Copy link

When I'm running the script to install grafana, I'm getting an error saying grafana-server.service not found.
Do we need to write the unit file explicitely or download from somewhere?

@souvikhaldar
Copy link
Author

Error:-

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  3102  100  3102    0     0  76972      0 --:--:-- --:--:-- --:--:-- 77550
OK
Hit:1 http://security.debian.org stretch/updates InRelease
Hit:2 http://ftp.debian.org/debian stretch-backports InRelease                                                                            
Ign:3 http://mirrors.digitalocean.com/debian stretch InRelease                                                 
Get:4 http://mirrors.digitalocean.com/debian stretch-updates InRelease [91.0 kB]
Hit:5 http://mirrors.digitalocean.com/debian stretch Release
Fetched 91.0 kB in 1s (58.8 kB/s)
Reading package lists... Done
E: The method driver /usr/lib/apt/methods/https could not be found.
N: Is the package apt-transport-https installed?
E: Failed to fetch https://packagecloud.io/grafana/stable/debian/dists/jessie/InRelease  
E: Some index files failed to download. They have been ignored, or old ones used instead.
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:34
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:34
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:34
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:34
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:35
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:35
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:35
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:35
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:36
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:36
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:36
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:33 and /etc/apt/sources.list:36
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package grafana
Failed to start grafana-server.service: Unit grafana-server.service not found.
Failed to enable unit: File grafana-server.service: No such file or directory
root@test-server-kartbites:~/prometheus-course/scripts#```

@souvikhaldar
Copy link
Author

When I manually ran the following commands it worked:-

apt install grafana
sudo /bin/systemctl daemon-reload
sudo /bin/systemctl enable grafana-server
sudo /bin/systemctl start grafana-server

Result-

root@test-server-kartbites:~/prometheus-course/scripts#  sudo /bin/systemctl start grafana-server
root@test-server-kartbites:~/prometheus-course/scripts# ps aux | grep grafana
grafana   4287  4.1  3.7 325280 38216 ?        Ssl  06:12   0:00 /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:default.paths.plugins=/var/lib/grafana/plugins cfg:default.paths.provisioning=/etc/grafana/provisioning
root      4299  0.0  0.0  12720   932 pts/0    S+   06:12   0:00 grep grafana
root@test-server-kartbites:~/prometheus-course/scripts# 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants