Skip to main content

Fixing "COMMAND_FAILED: 'python-nftables' failed: netlink: Error: Could not process rule: No buffer space available" Error

··2 mins·
Firewalld Troubleshooting Error Networking Linux
Makoto Morinaga
Author
Makoto Morinaga
A personal notebook for tech notes, coding, and system experiments.
Table of Contents

Introduction
#

I recently ran into a baffling error while configuring firewalld on my system: COMMAND_FAILED: 'python-nftables' failed: netlink: Error: Could not process rule: No buffer space available. Here’s how I diagnosed and resolved the issue.

When Did I Encounter This Error?
#

This annoying message popped up when I was Configuring firewalld.

Diagnosis
#

After some digging, I found that the issue was likely related to the net.core.rmem_max and possibly net.core.rmem_default system parameters.

I checked the current settings with these commands(Since I was using LXC, I also had to check these settings on the host system):

Terminal
sysctl -n net.core.rmem_max
sysctl -n net.core.rmem_default

How I Solved It
#

Increasing the Buffer Sizes
#

I temporarily increased the buffer sizes this way:

Terminal
sysctl -w net.core.rmem_max=new_value_max
sysctl -w net.core.rmem_default=new_value_default

Testing
#

After making these changes, I tried configuring firewalld again and this time, it worked.

Making the Changes Permanent
#

Because this solved my problem, I made the changes permanent by adding them to a sysctl config file.

I added the settings to /etc/sysctl.d/network_buffer.conf like so:

Terminal
echo "net.core.rmem_max = new_value_max" >> /etc/sysctl.d/network_buffer.conf
echo "net.core.rmem_default = new_value_default" >> /etc/sysctl.d/network_buffer.conf

Conclusion
#

For me, tweaking the net.core.rmem_max and net.core.rmem_default parameters cleared up the “No buffer space available” error. If you’re facing a similar issue, especially while configuring firewalld, you might want to try this out. But as always, make sure to test extensively after making any changes like this.

Related

Sticky Shift with libskk
··2 mins
Linux Skk
Setting Up an Incremental Backup System with Borg
··3 mins
Backup Linux Borg
iptables Configuration
··4 mins
Linux Firewall Iptables