OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • English Forums »
  • Tutorials and FAQs »
  • [Tutorial] Munin-node OPNsense
« previous next »
  • Print
Pages: [1]

Author Topic: [Tutorial] Munin-node OPNsense  (Read 3935 times)

afan

  • Newbie
  • *
  • Posts: 26
  • Karma: 1
    • View Profile
[Tutorial] Munin-node OPNsense
« on: January 27, 2021, 10:02:59 am »
Since OPNsense 20.1, the plugin munin-node is available. No need to use the FreeBSD repo any longer.

The below is a mini-howto to install and configure munin-node on OPNsense 20.7.

Steps to take:
- Install the plugin "os-munin-node" through the GUI on System: Firmware: Plugins
- On the GUI, enable munin-node and set the proper server/network that may connect to munin: Services: Munin-Node: General
- Ensure your firewall rules allow access to munin-node (TCP port 4949)
- Enable SSH access to configure munin-node further
- Run "munin-node-configure --suggest" to get a suggestion on which plugins can be activated. NOTE: this command can take a *long* time to execute (4 minutes or so on my 4 CPU/6GB RAM system) without any output... Do " munin-node-configure --debug --suggest" to get more verbose output.
- Inspect what the suggestions are; if agreed run "munin-node-configure --debug --shell" to generate the shell commands. For me, these were:
Code: [Select]
ln -s '/usr/local/share/munin/plugins/cpu' '/usr/local/etc/munin/plugins/cpu'
ln -s '/usr/local/share/munin/plugins/df' '/usr/local/etc/munin/plugins/df'
ln -s '/usr/local/share/munin/plugins/df_inode' '/usr/local/etc/munin/plugins/df_inode'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_em0'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_pppoe2'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_pppoe3'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx0'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx1'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx2'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx3'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx4'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx5'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx6'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx7'
ln -s '/usr/local/share/munin/plugins/if_' '/usr/local/etc/munin/plugins/if_vmx8'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_em0'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_pppoe2'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_pppoe3'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx0'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx1'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx2'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx3'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx4'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx5'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx6'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx7'
ln -s '/usr/local/share/munin/plugins/if_errcoll_' '/usr/local/etc/munin/plugins/if_errcoll_vmx8'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_em0'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_pppoe2'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_pppoe3'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx0'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx1'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx2'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx3'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx4'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx5'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx6'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx7'
ln -s '/usr/local/share/munin/plugins/if_packets_' '/usr/local/etc/munin/plugins/if_packets_vmx8'
ln -s '/usr/local/share/munin/plugins/iostat' '/usr/local/etc/munin/plugins/iostat'
ln -s '/usr/local/share/munin/plugins/load' '/usr/local/etc/munin/plugins/load'
ln -s '/usr/local/share/munin/plugins/memory' '/usr/local/etc/munin/plugins/memory'
ln -s '/usr/local/share/munin/plugins/netstat' '/usr/local/etc/munin/plugins/netstat'
ln -s '/usr/local/share/munin/plugins/ntp_' '/usr/local/etc/munin/plugins/ntp_45.87.76.3'
ln -s '/usr/local/share/munin/plugins/ntp_kernel_err' '/usr/local/etc/munin/plugins/ntp_kernel_err'
ln -s '/usr/local/share/munin/plugins/ntp_kernel_pll_freq' '/usr/local/etc/munin/plugins/ntp_kernel_pll_freq'
ln -s '/usr/local/share/munin/plugins/ntp_kernel_pll_off' '/usr/local/etc/munin/plugins/ntp_kernel_pll_off'
ln -s '/usr/local/share/munin/plugins/ntp_offset' '/usr/local/etc/munin/plugins/ntp_offset'
ln -s '/usr/local/share/munin/plugins/ntp_states' '/usr/local/etc/munin/plugins/ntp_states'
ln -s '/usr/local/share/munin/plugins/open_files' '/usr/local/etc/munin/plugins/open_files'
ln -s '/usr/local/share/munin/plugins/swap' '/usr/local/etc/munin/plugins/swap'
ln -s '/usr/local/share/munin/plugins/systat' '/usr/local/etc/munin/plugins/systat'
ln -s '/usr/local/share/munin/plugins/uptime' '/usr/local/etc/munin/plugins/uptime'
ln -s '/usr/local/share/munin/plugins/users' '/usr/local/etc/munin/plugins/users'
- Paste the listed shell commands so they get executed
- Restart munin-node: # service munin-node restart
Code: [Select]
# service munin-node restart
Stopping munin_node.
Waiting for PIDS: 46787.
Starting munin_node.
- (Optional) Verify whether connectivity from the munin master to OPNsense is OK and whether all plugins are listed:
Code: [Select]
root@srv-8:~# nc 10.0.10.1 4949
# munin node at OPNsense-v1
list
cpu df df_inode if_em0 if_errcoll_em0 if_errcoll_pppoe2 if_errcoll_pppoe3 if_errcoll_vmx0 if_errcoll_vmx1 if_errcoll_vmx2 if_errcoll_vmx3 if_errcoll_vmx4 if_errcoll_vmx5 if_errcoll_vmx6 if_errcoll_vmx7 if_errcoll_vmx8 if_packets_em0 if_packets_pppoe2 if_packets_pppoe3 if_packets_vmx0 if_packets_vmx1 if_packets_vmx2 if_packets_vmx3 if_packets_vmx4 if_packets_vmx5 if_packets_vmx6 if_packets_vmx7 if_packets_vmx8 if_pppoe2 if_pppoe3 if_vmx0 if_vmx1 if_vmx2 if_vmx3 if_vmx4 if_vmx5 if_vmx6 if_vmx7 if_vmx8 iostat load memory netstat ntp_45.87.76.3 ntp_kernel_err ntp_kernel_pll_freq ntp_kernel_pll_off ntp_offset ntp_states open_files swap systat uptime users
- Configure the OPNsense host on the munin master:
Code: [Select]
[OPNsense.mydomain.local]
        address 10.0.10.1
        use_node_name yes
- Restart munin on master:
Code: [Select]
# service munin restart
stop: Unknown instance:
munin stop/waiting
- Wait for your munin interval (default 5 mins) and enjoy initial OPNsense statistics generated on munin master
Logged

mimugmail

  • Hero Member
  • *****
  • Posts: 6292
  • Karma: 432
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #1 on: January 27, 2021, 12:06:52 pm »
Hi,

Thanks for the guide. Isn't this already done when installing and confguring the plugin only?
Logged
Twitter: mimu_muc
WWW: www.routerperformance.net
Support plans: https://www.max-it.de/en/it-services/opnsense/
Commercial Plugins (German): https://opnsense.max-it.de/

afan

  • Newbie
  • *
  • Posts: 26
  • Karma: 1
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #2 on: January 27, 2021, 01:21:25 pm »
At least for me, it wasn't. No munin plugins were enabled with the default install (tried by telnetting to opnsense and doing "list" - nothing showed up).
Logged

Luc3k

  • Newbie
  • *
  • Posts: 16
  • Karma: 2
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #3 on: February 13, 2021, 07:16:31 pm »
Where You configured this option?
Code: [Select]
[OPNsense.mydomain.local]
        address 10.0.10.1
        use_node_name yes
« Last Edit: February 13, 2021, 07:23:44 pm by Luc3k »
Logged

afan

  • Newbie
  • *
  • Posts: 26
  • Karma: 1
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #4 on: February 13, 2021, 07:58:25 pm »
On the munin master system, so it knows to reach out to the address of OPNsense and can start collecting.
Logged

Luc3k

  • Newbie
  • *
  • Posts: 16
  • Karma: 2
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #5 on: February 14, 2021, 07:02:01 am »
Hmm... I installed only os-munin-node plugin. Now I have to install munin deamon/master/collector?
I have described my setup here: https://forum.opnsense.org/index.php?topic=21500.msg101053#msg101053

Can you take a look?
Logged

afan

  • Newbie
  • *
  • Posts: 26
  • Karma: 1
    • View Profile
Re: [Tutorial] Munin-node OPNsense
« Reply #6 on: February 14, 2021, 09:33:29 am »
Done - main message is to try http://guide.munin-monitoring.org/en/latest/tutorial/troubleshooting.html/
Logged

  • Print
Pages: [1]
« previous next »
  • OPNsense Forum »
  • English Forums »
  • Tutorials and FAQs »
  • [Tutorial] Munin-node OPNsense
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2023 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2