Errors on ./validate.php for fping

Hello all,

I am trying to find out if anyone has a fix for “fping should have CAP_NET_RAW” errors in the ./validate.php. I am running ubuntu server 16.04 for the host with all the latest updates. I have tired the fix commands listed in the output but getting error “Failed to set capabilities on file `/usr/bin/fping’ (Invalid argument)
The value of the capability argument is not permitted for a file. Or the file is not a regular (non-symlink) file”.

Thank you all for this awesome software

What distro do you use?

Ubuntu Server 16.04

Maybe you dont have fping installed, try apt-get install fping

command -v fping will return the location of fping if is installed.

@Kevin_Krumm apt is better than apt-get - start using it in latest ubuntu versions :stuck_out_tongue:

@Gorian thank you, I didn’t know that :slight_smile: Learn something new every day.

Generally: apt for “interactive” and “apt-get” for script use.

Sorry for the delay, So I have fping installed at the time of posting this.

[email protected]:~# apt-get install fping
Reading package lists… Done
Building dependency tree
Reading state information… Done
fping is already the newest version (3.13-1).

[email protected]:~# command -v fping

I’ve found that’s often the case in LibreNMS, it’s just not in the same place per-distro, so you have to “find” and specify it’s location.

$config['fping'] = "/usr/bin/fping";

should be fine if you haven’t set this already.

/usr/bin/fping is the default, it’s only CentOS you need to change it for + derivatives.


Ah, good to know, thanks @laf :slight_smile:

I have the same issue, running Ubuntu 17.04, the only difference is I have LibreNMS installed to a lxc container.

[email protected]:/opt/librenms# ./validate.php 
Component | Version
--------- | -------
LibreNMS  | 1.31.03-48-g31607418e
DB Schema | 206
PHP       | 7.0.22-0ubuntu0.17.04.1
MySQL     | 10.1.25-MariaDB-
RRDTool   | 1.6.0
SNMP      | NET-SNMP 5.7.3

[OK]    Database connection successful
[OK]    Database schema correct
[WARN]  Your install is over 24 hours out of date, last update: Sat, 16 Sep 2017 09:13:03 +0000
[FAIL]  fping should have CAP_NET_RAW! [FIX] setcap cap_net_raw+ep /usr/bin/fping
[FAIL]  fping6 should have CAP_NET_RAW! [FIX] setcap cap_net_raw+ep /usr/bin/fping6
[email protected]:/opt/librenms# ls -la /usr/bin/fping
-rwxr-xr-x 1 root root 39232 Jan 12  2017 /usr/bin/fping
[email protected]:/opt/librenms# ls -la /usr/bin/fping6
-rwsr-xr-x 1 root root 39232 Jan 12  2017 /usr/bin/fping6

I’ve tried a chmod +s on the files, no difference

Hi, I am also dealing with the same issue, running Ubuntu 17.04 in a docker container.
Is someone found a solution ?

I’ve found a workaround, but not really a solution.

The issues I think is with Linux Containers, I have the issue using ext4 and btrfs as the container storage, hosting out of Ubuntu 17.04 on Hyper-V, VirtualBox, and directly on metal. Once the machine is in a container, the issue appears.

Anyway, in short; run setcap on the host VM against the file inside the container; roughly as follows:

[email protected]:~# lxc exec librenms -- /bin/bash

[email protected]:~# getcap /usr/bin/fping
[email protected]:~# setcap CAP_NET_RAW+ep /usr/bin/fping
Failed to set capabilities on file `/usr/bin/fping' (Invalid argument)
The value of the capability argument is not permitted for a file. Or the file is not a regular (non-symlink) file

[email protected]:~# exit

[email protected]:~# cd /var/lib/lxd/containers/librenms/rootfs/
[email protected]:/var/lib/lxd/containers/librenms/rootfs# setcap cap_net_raw+ep ./usr/bin/fping	
[email protected]:/var/lib/lxd/containers/librenms/rootfs# lxc exec librenms -- /bin/bash

[email protected]:~# getcap /usr/bin/fping
/usr/bin/fping = cap_net_raw+ep
1 Like


Having the same issue here, and I’m not using containers. Seems something is expecting fping6 to exist … but it doesn’t for Ubuntu?


Actually, based on this …
=> is this actually a bug / out of date information in LibreNMS?

running “apt install fping” gives me both fping & fping6 on my ubuntu installs

[email protected]:~# ls -la /usr/bin/fping*
-rwxr-xr-x 1 root root 39232 Jan 12  2017 /usr/bin/fping
-rwxr-xr-x 1 root root 39232 Jan 12  2017 /usr/bin/fping6
[email protected]:~# getcap /usr/bin/fping*
/usr/bin/fping = cap_net_raw+ep
/usr/bin/fping6 = cap_net_raw+ep

maybe use try a “apt-get update && apt remove fping && apt install fping” and check for error messages on install. my container-based installs all say they can’t run the “setcap” commands, but it still installs the binaries.

Very odd - but nope, I only get fping. Here is the output from ls -la /usr/bin/fping*
-rwxr-xr-x 1 root root 48000 Jun 18 16:28 /usr/bin/fping

I tried purge and reinstall, no joy. Thoughts?


FYI, it seems recent versions of Ubuntu have removed fping6 … :-(. Some links that I believe show this,

Up to zesty, fping6 noted and exists,

And artful, fping6 is gone … rather, a command line option exists now to replace it,




Is anyone else having this issue (or perhaps there is a simple workaround)? fping6 doesn’t exist in recent Ubuntu releases … :(.