Skip to header Skip to main navigation Skip to main content Skip to footer

Search form

Site branding

Home
What's up, home?

Main navigation

  • Home
  • Story mode
  • About
  • Features
  • Hardware list
  • Videos
  • GitHub (opens in new tab)
  • Daily AI generated stories (opens in new tab)

Part 28: Have a nice flight

Breadcrumbs

Breadcrumb

  • Home
  • Part 28: Have a nice flight

Main page content

By whatsuphome | 11:18 AM EET, Mon November 21, 2022

TL;DR

I pointed Zabbix at FlightGear's built-in HTTP server and harvested latitude, longitude, altitude and speed into two master items. The resulting graphs then show whether my shaky virtual flying actually stays in the air.
Flight Gear screenshot

Can you monitor FlightGear flight simulator with Zabbix? Of course you can! By day, I am a monitoring tech lead in a global cyber security company. By night, I monitor my home with Zabbix & Grafana and do some weird experiments with them. Welcome to my blog about this project.

FlightGear is an awesome free, open-source flight simulator. I am not a pilot, not even a good virtual pilot, in fact, probably the virtual cabin crew would be chanting "BRACE! BRACE! BRACE! HEAD DOWN! STAY DOWN!" to my virtual passengers. Anyway, learning to fly would be awesome.

But what good would be virtual flying without any monitoring? For most people, they wouldn't care about monitoring. For me, that's about everything I care with this experiment.

FlightGear Properties

FlightGear can expose all kinds of flight related data over many different ways; XML logging and via its built-in HTTP server, for example. This time I used its HTTP server, and cherry-picked only few values (aircraft latitude, longitude, altitude and speed), as the completely property list is LONG, and I do not understand the most of it.

Anyway, you get the FlightGear HTTP server up and running by launching it like

fgfs --httpd=5480

... where 5480 is the port number where HTTP server will be listening on.

You will then have a property browser available on http://localhost:5480/json/ which is from where I found the values I wanted to harvest for my little experiment to see if this thing would fly.

No alt text provided for this image

Adding items to Zabbix

To get these values monitored, I added two new master items to Zabbix: one for velocities and one for position. Then, dependent items are using those master items.

No alt text provided for this image

No alt text provided for this image

My latitude/longitude items also do populate the Zabbix inventory latitude/longitude fields for my aircraft.

No alt text provided for this image

Does it fly?

Yes it does. I can now have data about my virtual flight.

No alt text provided for this image

And thanks to inventory fields, I can show the location of my virtual aircraft on Zabbix geomap.

No alt text provided for this image

If you are a flight simulator enthusiast, feel free to use this technique and possibly gather all the values from FlightGear property browser by using low-level discovery. For my little test, I did not bother.

I have been working at Forcepoint since 2014 and have learnt that proper monitoring makes sure your projects do takeoff without too much pain.

whatsuphome
zabbix
flightgear
simulation
httpagent
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id>
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
I pointed Zabbix at FlightGear's built-in HTTP server and harvested latitude, longitude, altitude and speed into two master items. The resulting graphs then show whether my shaky virtual flying actually stays in the air.

Search

Who am I?

  • Janne Pikkarainen from Finland 🇫🇮
  • Began with computers in 1986 with C64
  • Doing IT for living since 1999
  • Principal Site Reliability Engineer at Forcepoint
  • A Zabbix Summit speaker every year since 2022
  • Walking, talking Zabbix commercial

Support my project

Buy me a coffee 

Footer menu

  • Contact

What's up, home? | Janne Pikkarainen | contact(at)whatsuphome.fi | 2022 - 2026

Developed and Designed by Janne Pikkarainen