Fix firewalld issue causing holdup in plasma setting

Are you suffering from following ?

  • firewall-applet not working

  • firewall-cmd returning dbus errors something like:-

ERROR:dbus.proxies:Introspect error on :1.6:/org/fedoraproject/FirewallD1: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NoReply: Did not receive a reply. 
Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
  • KDE Network Management setting(kcm_networkmanagement) taking too long to start up

Remove /var/lib/ebtables/lock

Since few days KDE Network Management settings started to take ages to load up. I couldn’t find why it wasn’t working. I tried everything, deleted configs, re-installed services. tested on different machine which was running OpenSuse (My main laptop is arch btw) etc but it didn’t worked. Finally I cloned plasma-nm from KDE’s gitlab instance compiled it with debug symbols like this:-

git clone git@invent.kde.org:plasma/plasma-nm.git
cd plasma-nm && mkdir build
cmake .. -GNinja -DCMAKE_INSTALL_PREFIX=$(pwd)/installation
ninja install

then I set environment variables in qt creator according to prefix.sh generated by CMake in build directory and found out that this code was causing the holdup

QDBusMessage msg = QDBusMessage::createMethodCall("org.fedoraproject.FirewallD1", 
                        "/org/fedoraproject/FirewallD1",
                         "org.fedoraproject.FirewallD1.zone", 
                         "getZones");                         
QDBusPendingReply<QStringList> reply = QDBusConnection::systemBus().asyncCall(msg);
reply.waitForFinished();

So I tried firewall-cmd --get-zones command and It gave me some dbus error after ~30 seconds and wasn’t even quitting with Ctrl+C. I had to manually kill firewall-cmd. turns out that firewall-applet was also not working. So after knowing this, I knew what to search for and I was able to find solution on arch forum which suggested to remove /var/lib/ebtables/lock

I’m not sure what this file does and would love to hear from experts.