Tutorial for Grafana
Steps on your server/local machine
Prometheus
- Head to Prometheus Download page https://prometheus.io/download/
- Download "prometheus" LTS version for your OS
- Unpack the folder
- Open the prometheus.yml with a text editor
- Add following lines to the end of your file:
- job_name: "altv"
static_configs:
- targets: ["localhost:7797"]
- Save the file
- Open a console (PowerShell whatever)
- Run prometheus (.exe) and keep it running
alt:V Server
- Head to your server.toml
- Open it with a text editor
- Add or edit following line:
[worldProfiler]
port = 7797
host = "0.0.0.0"
- Open a console (PowerShell whatever)
- Start the server and keep it running
Steps in browser
Grafana (Cloud):
- Create an account on Grafana: https://grafana.com/auth/sign-up/create-user?pg=login
- Setup your vanity URL (e.g. PROJECTNAME.grafana.net)
- On your vanity URL, click on the burger icon next to home
- Open the dropdown of "Connections"
- Click on Data sources
- Click on "Add new data source" at the top right
- Select Prometheus
- Give it a name
- Enter the IPv4 of the server (if local, your IPv4) [Google: "What's my IP"]
- Scroll down and click on "Save&Test"
- If successfully, click on "Build a dashboard" at the top right corner
- Click on "Import a dashboard"
- Enter 20241 in the input field and click on Load
- Select the data source you created just before
- Click on Import
Grafana (self-hosted):
- On your vanity URL, click on the burger icon next to home
- Open the dropdown of "Connections"
- Click on Data sources
- Click on "Add new data source" at the top right
- Select Prometheus
- Give it a name
- Enter the IPv4 of the server (if local, your IPv4) [Google: "What's my IP"]
- Scroll down and click on "Save&Test"
- If successfully, click on "Build a dashboard" at the top right corner
- Click on "Import a dashboard"
- Enter 20241 in the input field and click on Load
- Select the data source you created just before
- Click on Import
If you have a static server IPv4, you can add users to your Grafana dashboard to share data with your team.