You are not logged in.

#1 2016-09-26 20:52:46

oneleaf
Member
Registered: 2016-03-29
Posts: 26

Openbox and Dmenu conflict?

I am wondering if anyone uses Openbox and Dmenu together? I am trying to build up a minimal desktop for Ubuntu 16.04, and running into a weird issue. All I have is a very basic Ubuntu install, where I manually installed xorg, openbox, and dmenu, and a few other things.

The only things in my openbox autostart is compton and policykit-1-gnome. I did a keybind in my rc.xml file for executing dmenu_run using Alt-D. Everything works for graphical applications.

Now, I am aware that dmenu will not launch terminal apps in a terminal, and I am fine with that. However, in previous experience with dmenu (using it on MATE as well as an i3 desktop), launching terminal apps simply would not work. But on my fresh Ubuntu install, I am getting a weird issue where after trying to launch a terminal app (like mc or mocp), my openbox becomes unuseable such that I cannot click or type anything (right-click menu doesn't work and I can't grab or do anything with existing windows). The cursor still moves and I can ssh into the machine, so nothing has crashed. But the openbox session simply is not working, and is expecting input from another means or something. At this point, I just ssh into it and reboot it from there.

Is there something I am missing in regards to getting dmenu and openbox to work together such that launching terminal apps simply doesn't do anything but doesn't make my openbox stop working? Thanks!

Last edited by oneleaf (2016-09-26 20:53:24)

Offline

#2 2016-09-27 06:45:26

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

oneleaf wrote:

I am wondering if anyone uses Openbox and Dmenu together?

The BunsenLabs desktop includes dmenu, bound to <Alt>+F3 smile

I am aware that dmenu will not launch terminal apps in a terminal

It will if you use a wrapper script to open a terminal with the application running in it.

See https://forums.bunsenlabs.org/viewtopic.php?id=2767 for more on this.

on my fresh Ubuntu install, I am getting a weird issue where after trying to launch a terminal app (like mc or mocp), my openbox becomes unuseable such that I cannot click or type anything (right-click menu doesn't work and I can't grab or do anything with existing windows). The cursor still moves and I can ssh into the machine, so nothing has crashed. But the openbox session simply is not working, and is expecting input from another means or something. At this point, I just ssh into it and reboot it from there.

So Ubuntu will launch terminal programs directly from dmenu?

Have you tried pressing <Escape> when the desktop is unresponsive?

It sounds like perhaps dmenu has grabbed the keyboard & mouse input.

Offline

#3 2016-09-27 07:35:18

oneleaf
Member
Registered: 2016-03-29
Posts: 26

Re: Openbox and Dmenu conflict?

Actually no, it doesn't launch terminal programs, which is what I expected. But the part where it locks up X is what is undesirable behavior.

But I just realized something. All of the terminal programs I tested were ncurses programs... and they all not only failed to launch (as expected) but also froze up X. But launching other terminal commands does not lock up X. I wonder if this is just an issue with dmenu and ncurses? Anyone try to launch midnight commander from dmenu?

Offline

#4 2016-09-27 17:22:25

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

oneleaf wrote:

Anyone try to launch midnight commander from dmenu?

Works for me (in Arch) if I use `st -e mc` in dmenu (my terminal is `st`), from which terminal do you launch the ncurses programs?

What is the exact string that is typed into dmenu?

Offline

#5 2016-09-27 17:34:43

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

oneleaf wrote:

they all not only failed to launch (as expected) but also froze up X.

this just happened to me, too, trying to launch mocp from dmenu_run!
right now i don't know if dmenu is the culprit, or something in the dmenu_run script (it's just a shell script).

and a weird sort of lock up. i can open new windows and use them, but already open windows freeze complete, just show 1 color. tint2 is nonresponive.
openbox seems to work ok; i can change workspaces, menu works... for the frozen windows it gives me the "application not responding" dialog and i can kill them off one by one, but i can't exit the session.
i'm totally baffled.

simple openbox env on archlinux.

openbox 3.6.1
dmenu-4.6
Xorg 1.18.4-1

Offline

#6 2016-09-27 18:34:53

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

ohnonot wrote:

trying to launch mocp from dmenu_run!

How are you trying to launch "mocp"?

Are you just opening up dmenu and typing in "mocp"?

I can do that with `mc` to no effect whatsoever in my Arch [testing] dwm desktop.

EDIT: Correction: when I log out of the graphical desktop, mc is running on the console screen.

OTOH, `st -e mc` in dmenu_run will launch it normally.

Last edited by Head_on_a_Stick (2016-09-27 18:44:20)

Offline

#7 2016-09-27 21:02:58

oneleaf
Member
Registered: 2016-03-29
Posts: 26

Re: Openbox and Dmenu conflict?

Head_on_a_Stick wrote:
oneleaf wrote:

Anyone try to launch midnight commander from dmenu?

Works for me (in Arch) if I use `st -e mc` in dmenu (my terminal is `st`), from which terminal do you launch the ncurses programs?

What is the exact string that is typed into dmenu?

I actually am just typing in "mc", which I expect not to work. I am just trying to avoid the part where it locks up X. I am aware that typing in "mc" should not work, but since it is something I might do by accident, I would prefer it to just do nothing, rather than lock up my session.

On the other hand, gmrun works just fine... I can type in mc, and it launches in urxvt. I might just change to using gmrun since it does do everything I need... I just like the interface for dmenu better with the top bar.

Offline

#8 2016-09-28 06:01:13

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

Head_on_a_Stick wrote:

Are you just opening up dmenu and typing in "mocp"?

yes.
since it totally freezes up my desktop, i am a little reluctant to test this further, but i will once i've logged out here.

and as oneleaf said, i'm alarmed about the freezes and not about the fact that this simply doesn't work.

Offline

#9 2016-09-28 06:16:32

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

I can confirm this issue on my Arch system if I use Openbox.

On my box, the system does not freeze but any already open windows become unresponsive, new windows can be opened and behave normally.

I recommend switching to dwm  8o

As I mentioned above, the programs were running on the console after I logged out (no DM) so they must be backgrounded (is that a word?) somehow.

@{OP,ohnonot} -- do you use a display manager?

Offline

#10 2016-09-28 07:03:07

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

more troubleshooting.

i'll try to characterize the symptoms better:

not a freeze.
already opened windows become opaque and unusable, including tint2 and conky, but not openbox itself!
i can continue to use the system normally, switch desktops, open windows, kill openbox - but i cannot log out of the Xsession!
i do NOT use a display manger.

i can reproduce this behavior 100% with:

mocp, started from dmenu_run
mc, started from dmenu_run
mocp, started from gmrun (!)
but NOT mc started from gmrun!

i have not completely finished troubleshooting yet; it's very cumbersome since i have to reboot after every lockup.
anyway to get out of this without rebooting?

application versions:
openbox 3.6.1
dmenu-4.6
Xorg 1.18.4-1
mocp 2.5.1
mc 4.8.17
gmrun 0.9.2-6


edit:
HoaS, are you saying that this does NOT happen with dwm under otherwise identical conditions???

Last edited by ohnonot (2016-09-28 07:05:23)

Offline

#11 2016-09-28 07:06:46

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

ohnonot wrote:

anyway to get out of this without rebooting?

Try this to log out:

# systemctl isolate multi-user.target

Offline

#12 2016-09-28 07:08:06

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

ohnonot wrote:

HoaS, are you saying that this does NOT happen with dwm under otherwise identical conditions???

That is correct, dwm behaves nicely but when I log out of the desktop the last launched ncurses program (`mc` in my case) can be seen running in the TTY hmm

Offline

#13 2016-09-28 07:10:27

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

could you also try with mocp please?

Offline

#14 2016-09-28 07:12:20

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

I will try tonight, off to $DAY_JOB now...

Also, https://www.archlinux.org/packages/?q=mocp?

Offline

#15 2016-09-28 07:17:44

oneleaf
Member
Registered: 2016-03-29
Posts: 26

Re: Openbox and Dmenu conflict?

Head_on_a_Stick wrote:

I can confirm this issue on my Arch system if I use Openbox.

On my box, the system does not freeze but any already open windows become unresponsive, new windows can be opened and behave normally.

I recommend switching to dwm  8o

As I mentioned above, the programs were running on the console after I logged out (no DM) so they must be backgrounded (is that a word?) somehow.

@{OP,ohnonot} -- do you use a display manager?

No display manager for me. Just login in the console, and use startx to get in. My lockup seems more severe than ohnonot, so I end up having to reboot the machine over ssh, or hit the reset.

Offline

#16 2016-09-28 07:21:36

oneleaf
Member
Registered: 2016-03-29
Posts: 26

Re: Openbox and Dmenu conflict?

ohnonot, weird that you get a crash with mocp using gmrun. I just tried mine, and nothing happens (as expected). However, if I do mocp with ctrl-Enter, it opens moc player in my default terminal as expected.

The weird thing is that I can type in mc in gmrun and enter (without ctrl-Enter) and it opens in terminal, which is unexpected, but nice. Any idea why mc is able to be run with the ctrl modifier, but mocp isn't?

Offline

#17 2016-09-28 14:36:14

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

oneleaf wrote:

The weird thing is that I can type in mc in gmrun and enter (without ctrl-Enter) and it opens in terminal, which is unexpected, but nice. Any idea why mc is able to be run with the ctrl modifier, but mocp isn't?

ah! that's interesting.
have to try more than 2 different ncurses apps i guess.

again, i'm off to troubleshoot after logging off the forums.

HoaS: It's moc, not mocp.

Offline

#18 2016-09-28 18:47:58

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Openbox and Dmenu conflict?

I can confirm that `mocp` freezes up OpenBox even in Alpine Linux.

In Alpine, `pkill openbox` or `openbox --exit` restores normality upon re-login (this box is systemd-free).

With my usual dwm desktop, everything works normally after `mocp` is entered in dmenu but `mocp` can be seen running in `htop` but not attached to any parent process apart from PID1, upon logout `mocp` can be seen running on the console screen just before it terminates.

EDIT: Package versions:

openbox-3.6.1-r0
xorg-server-1.18.4-r1
moc-2.5.1-r0
dmenu-4.6-r1

Last edited by Head_on_a_Stick (2016-09-28 21:31:54)

Offline

#19 2016-09-29 05:12:40

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Openbox and Dmenu conflict?

i have not posted back yesterday since i had nothing new to report.

this seems to be, well if not an openbox bug, at least openbox related.

i will bring it to the attention of the openbox mailing list at http://icculus.org/mailman/listinfo/openbox

Last edited by ohnonot (2016-09-29 05:13:17)

Offline

Board footer

Powered by FluxBB