Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Opensnicth GUI not working across reboots #434

Closed
molitona opened this issue Jun 11, 2021 · 13 comments
Closed

Opensnicth GUI not working across reboots #434

molitona opened this issue Jun 11, 2021 · 13 comments

Comments

@molitona
Copy link

molitona commented Jun 11, 2021

Hi, I've installed opensnitch. It worked fine, but whenever I restart my OS the filtering isn't working anymore. In fact, I verified with 'ps' command and found that only daemon still active across reboots (opensnitch GUI which is responsible for appearing pop-ups is not active).

My OS is arch with GNOME as DE.
Installed version is 1.3.6-3. (https://aur.archlinux.org/packages/opensnitch/) from AUR.

Also, I noticed that these 2 lines are added to log file whenever I close GUI app.

ERR Connection to the UI service lost.
ERR getting notifications: rpc error: code = Unavailable desc = transport is closing

@gustavo-iniguez-goya
Copy link
Collaborator

Hi @molitona ,

Could you execute: journalctl -ar | grep opensnitch-ui to see if there's any error after reboot?

Once you login to Gnome, open a terminal and type: opensnitch-ui and see if it fails or runs as expected. If it doesn't fail and the GUI appears, check if the opensnitch icon exists in the systray. If doesn't appear there, you'll need to install https://extensions.gnome.org/extension/615/appindicator-support/

By the way, have you tried it with another DE? xfce, kde, etc.

@molitona
Copy link
Author

molitona commented Jun 11, 2021

journalctl output

Jun 10 18:34:12 ... systemd-coredump[29764]: Process 29671 (opensnitch-ui) of user 1000 dumped core.
Jun 10 18:34:11 ... kernel: audit: type=1701 audit(1623346451.866:281): auid=1000 uid=1000 gid=1000 ses=4 pid=29671 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:34:11 ... audit[29671]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=4 pid=29671 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:25:59 ... systemd-coredump[28664]: Process 28513 (opensnitch-ui) of user 1000 dumped core.
Jun 10 18:25:58 ... kernel: audit: type=1701 audit(1623345958.336:272): auid=1000 uid=1000 gid=1000 ses=4 pid=28513 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:25:58 ... audit[28513]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=4 pid=28513 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1

opensnitch-ui output (works fine)

Loading translations: /usr/lib/python3.9/site-packages/opensnitch/i18n locale: en_US
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
found on last chance: /usr/share/icons/hicolor/48x48/apps/rygel.png
found on last chance: /usr/share/icons/hicolor/48x48/apps/rygel.png
new node connected, listening for client responses... /tmp/osui.sock
^C

Hint : In gnome 40 there is no more systray for apps, and I only have Gnome DE.

Edit : same think with that extension installed (GUI app doesn't start across reboots).

@gustavo-iniguez-goya
Copy link
Collaborator

woah, it's failing hard:

(...) exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:25:59 ... systemd-coredump[28664]: Process 28513 (opensnitch-ui) of user 1000 dumped core.

There must be more logs in the journal, if you could post the previous logs just after it crashes, it would be really helpful to debug this problem.

On the other hand, could you try installing the git version? https://aur.archlinux.org/packages/opensnitch-git/
It has many new fixes and changes, just in case this problem is already solved.

Uninstall completely previous version before installing opensnitch-git.

@molitona
Copy link
Author

Here is the log (reversed, follow down-top). I'll test git version right away.

Jun 10 18:26:18 Unknown gnome-shell[964]: Window manager warning: Invalid WM_TRANSIENT_FOR window 0x800008 specified for 0x800014.
Jun 10 18:26:15 Unknown systemd[897]: gnome-terminal-server.service: Deactivated successfully.
Jun 10 18:26:06 Unknown python[28737]: Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
Jun 10 18:26:06 Unknown systemd[897]: Started Application launched by gnome-shell.
Jun 10 18:26:05 Unknown nautilus[28683]: Connecting to org.freedesktop.Tracker3.Miner.Files
Jun 10 18:26:05 Unknown systemd[897]: Started GNOME Terminal Server.
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.Terminal'
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.Calculator.SearchProvider'
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.Nautilus'
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.Characters.BackgroundService'
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.clocks'
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.ControlCenter.SearchProvider'
Jun 10 18:26:05 Unknown systemd[897]: Starting GNOME Terminal Server...
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating via systemd: service name='org.gnome.Terminal' unit='gnome-terminal-server.service' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating service name='org.gnome.clocks' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating service name='org.gnome.Characters.BackgroundService' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating service name='org.gnome.Calculator.SearchProvider' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating service name='org.gnome.Nautilus' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:05 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating service name='org.gnome.ControlCenter.SearchProvider' requested by ':1.17' (uid=1000 pid=964 comm="/usr/bin/gnome-shell ")
Jun 10 18:26:02 Unknown systemd[897]: gnome-terminal-server.service: Deactivated successfully.
Jun 10 18:26:02 Unknown systemd[897]: vte-spawn-1bf9a722-72f4-4219-ade7-5dec44dcc137.scope: Deactivated successfully.
Jun 10 18:26:00 Unknown kernel: audit: type=1334 audit(1623345960.306:280): prog-id=91 op=UNLOAD
Jun 10 18:26:00 Unknown kernel: audit: type=1334 audit(1623345960.306:279): prog-id=92 op=UNLOAD
Jun 10 18:26:00 Unknown kernel: audit: type=1334 audit(1623345960.306:278): prog-id=93 op=UNLOAD
Jun 10 18:26:00 Unknown audit: BPF prog-id=91 op=UNLOAD
Jun 10 18:26:00 Unknown audit: BPF prog-id=92 op=UNLOAD
Jun 10 18:26:00 Unknown audit: BPF prog-id=93 op=UNLOAD
Jun 10 18:26:00 Unknown systemd[897]: app-gnome-opensnitch_ui-28513.scope: Consumed 46.365s CPU time.
Jun 10 18:26:00 Unknown systemd[897]: app-gnome-opensnitch_ui-28513.scope: Deactivated successfully.
Jun 10 18:25:59 Unknown systemd[1]: [email protected]: Deactivated successfully.
Jun 10 18:25:59 Unknown audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@1-28663-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 10 18:26:00 Unknown kernel: audit: type=1131 audit(1623345959.966:277): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@1-28663-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 10 18:25:59 Unknown systemd-coredump[28664]: Process 28513 (opensnitch-ui) of user 1000 dumped core.
Jun 10 18:25:58 Unknown systemd[1]: Started Process Core Dump (PID 28663/UID 0).
Jun 10 18:25:58 Unknown python[28513]: Traceback (most recent call last):
Jun 10 18:25:58 Unknown audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@1-28663-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 10 18:25:58 Unknown audit: BPF prog-id=93 op=LOAD
Jun 10 18:25:58 Unknown audit: BPF prog-id=92 op=LOAD
Jun 10 18:25:58 Unknown audit: BPF prog-id=91 op=LOAD
Jun 10 18:25:58 Unknown kernel: audit: type=1130 audit(1623345958.346:276): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@1-28663-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 10 18:25:58 Unknown kernel: audit: type=1334 audit(1623345958.346:275): prog-id=93 op=LOAD
Jun 10 18:25:58 Unknown kernel: audit: type=1334 audit(1623345958.346:274): prog-id=92 op=LOAD
Jun 10 18:25:58 Unknown kernel: audit: type=1334 audit(1623345958.346:273): prog-id=91 op=LOAD
Jun 10 18:25:58 Unknown kernel: audit: type=1701 audit(1623345958.336:272): auid=1000 uid=1000 gid=1000 ses=4 pid=28513 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:25:58 Unknown kernel: kauditd_printk_skb: 5 callbacks suppressed
Jun 10 18:25:58 Unknown audit[28513]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=4 pid=28513 comm="opensnitch-ui" exe="/usr/bin/python3.9" sig=6 res=1
Jun 10 18:23:54 Unknown systemd[897]: app-gnome-gnome\x2dterminal-28609.scope: Deactivated successfully.
Jun 10 18:23:54 Unknown systemd[897]: Started VTE child process 28640 launched by gnome-terminal-server process 28616.
Jun 10 18:23:54 Unknown gnome-terminal-[28616]: Theme directory 32/apps of theme Fantasy-blue has no size field
Jun 10 18:23:54 Unknown systemd[897]: Started GNOME Terminal Server.
Jun 10 18:23:54 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Successfully activated service 'org.gnome.Terminal'
Jun 10 18:23:54 Unknown systemd[897]: Starting GNOME Terminal Server...
Jun 10 18:23:54 Unknown dbus-daemon[913]: [session uid=1000 pid=913] Activating via systemd: service name='org.gnome.Terminal' unit='gnome-terminal-server.service' requested by ':1.255' (uid=1000 pid=28609 comm="gnome-terminal ")
Jun 10 18:23:54 Unknown systemd[897]: Started Application launched by gsd-media-keys.
Jun 10 18:23:22 Unknown gnome-shell[964]: The offending signal was stopped on ClutterPropertyTransition 0x563997582e70.
Jun 10 18:23:22 Unknown gnome-shell[964]: Attempting to call back into JSAPI during the sweeping phase of GC. This is most likely caused by not destroying a Clutter actor or Gtk+ widget with ::destroy signals connected, but can also be caused by using the destroy(), dispose(), or remove() vfuncs. Because it would crash the application, it has been blocked and the JS callback not invoked.
Jun 10 18:23:22 Unknown gnome-shell[964]: == Stack trace for context 0x563994ab7170 ==
Jun 10 18:23:22 Unknown gnome-shell[964]: == Stack trace for context 0x563994ab7170 ==
Jun 10 18:23:22 Unknown gnome-shell[964]: The offending signal was stopped on ClutterPropertyTransition 0x563997709690.
Jun 10 18:23:22 Unknown gnome-shell[964]: Attempting to call back into JSAPI during the sweeping phase of GC. This is most likely caused by not destroying a Clutter actor or Gtk+ widget with ::destroy signals connected, but can also be caused by using the destroy(), dispose(), or remove() vfuncs. Because it would crash the application, it has been blocked and the JS callback not invoked.
Jun 10 18:23:15 Unknown gnome-shell[964]: Timelines with detached actors are not supported
Jun 10 18:23:15 Unknown gnome-shell[964]: Timelines with detached actors are not supported
Jun 10 18:23:15 Unknown gnome-shell[964]: Timelines with detached actors are not supported
Jun 10 18:23:15 Unknown gnome-shell[964]: Timelines with detached actors are not supported

@molitona
Copy link
Author

The same problem reoccurred with git version.

@molitona
Copy link
Author

molitona commented Jun 11, 2021

I've found that on
https://www.funkyspacemonkey.com/opensnitch-application-firewall-for-linux

Screenshot from 2021-06-11 18-55-59
I saw it last night and forgot to inform you. I've searched how can I achieve that to no avail. Could you help ? Thanks.

@gustavo-iniguez-goya
Copy link
Collaborator

You should have this file under for autostart the GUI: /home/<YOUR_USER>/.config/autostart/opensnitch_ui.desktop.

By the way, could you edit it and change X-GNOME-Autostart-Delay=3 by X-GNOME-Autostart-Delay=30 and see if it makes any difference?

@molitona
Copy link
Author

There is no files under my autostart directory !

@molitona
Copy link
Author

I've added that file from https://github.com/evilsocket/opensnitch/blob/master/ui/resources/opensnitch_ui.desktop and the GUI app is launched on every reboot.
But, there is this annoying window appearing each time I open my OS. So, how can I have opensnitch-gui process working when I restart without having that window appear on each reboot like when I close it with "X" button (opensnitch-gui process still work).

@gustavo-iniguez-goya
Copy link
Collaborator

I've added that file from https://github.com/evilsocket/opensnitch/blob/master/ui/resources/opensnitch_ui.desktop and the GUI app is launched on every reboot.

great! I think the AUR maintainer should document somewhere how to autostart the GUI.

But, there is this annoying window appearing each time I open my OS

If you refer to the opensnitch GUI you need to install this extension:
https://extensions.gnome.org/extension/615/appindicator-support/

download version 40 and install it:
$ gnome-extensions install Downloads/appindicatorsupport .. -shell-extension.zip

Execute the gnome-extensions-app and enable the AppIndicator extension. After reboot or log out/in you'll have a new icon on the top-right side of the panel.

@molitona
Copy link
Author

molitona commented Jun 12, 2021 via email

@gustavo-iniguez-goya
Copy link
Collaborator

Thank you @molitona , I'll update the documentation with this info.

@sezanzeb
Copy link

sezanzeb commented Apr 7, 2023

I'll update the documentation with this info.

Hi, I couldn't find it in the documentation and had to search the issues to figure this out. Did you forget to do it by any chance? I would have expected to find this in https://github.com/evilsocket/opensnitch/wiki/Installation

Something like this maybe:


Arch

sudo pacman -S opensnitch
sudo systemctl enable --now opensnitch
wget https://raw.githubusercontent.com/evilsocket/opensnitch/master/ui/resources/opensnitch_ui.desktop -O \
    ~/.config/autostart/opensnitch_ui.desktop

edit: wget was wrong


Or even better, a checkbox in the settings that enables the service and adds the autostart file. Because that was the first place I was looking for this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants