LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 11-07-2012, 01:43 AM   #1
alexbrui
LQ Newbie
 
Registered: Nov 2009
Location: Ukraine
Distribution: Slackware 13.37
Posts: 27

Rep: Reputation: 0
Problem with starting OpenBox in Slackware 14.0


I want to use OpenBox on my Slackware 14.0. So I download SlackBuild and sources from SBo, compile and install package. Then I run xwmconfig as root and select openbox-session as default WM. But... When OpenBox started from XDM it fails and in ~/.xsession-errors I get
Quote:
XDM authorization key matches an existing client!Openbox-Message: Cannot open display from DISPLAY variable
If I boot with run-level 3 and login I get message
Quote:
cannot open display "default display"
In same time I can start FluxBox both from console and XDM without any errors. Any ideas what is wrong and how to fix this?

P.S. I found thread with similar problem, but it didn't helps.
 
Old 11-07-2012, 07:05 AM   #2
GazL
Senior Member
 
Registered: May 2008
Posts: 3,440

Rep: Reputation: 958Reputation: 958Reputation: 958Reputation: 958Reputation: 958Reputation: 958Reputation: 958Reputation: 958
Yes, this issue caused a lot of problems with the included window-managers when 14.0 was being finalised.
Here's part of a mail I sent to Pat where I describe what I think is going on:
Quote:
The recent dbus-launch change to xinitrc.blackbox appears to break under XDM with the following error:
XDM authorization key matches an existing client!bt:isplay: failed to open display ''


My best guess at what is going on is that dbus-launch connects to the Xserver for whatever nefarious reasons it has but doesn't disconnect before calling exec() on the command specified in it's arguments. When the exec'd window manager later tries to connect to the Xserver it goes "Hang On! I've already got a connection from that process!" and throws a hissy-fit.

The result appears to be that any window manager that is started by a script appears to work when passed as an argument to dbus-launch, but those that are simple executables, such as blackbox and dwm cause the above error and the session terminates. (interestingly, fvwm doesn't appear to suffer this despite being a direct executable - I have no idea why)
That other thread you link to was some of my early attempts at working around the issue, but we quickly found that it worked for some window-managers, but not all.
The following is the approach I use now, which has proven reliable (here at any rate). I don't have openbox installed, but dwm suffered the same issue, and this is how I now resolve it.

xinitrc.dwm:
Code:
#!/bin/sh
#  xinitrc.dwm v1.4

startwm='/usr/bin/startdwm --with-dbus'

########################################################################
##  Merge in defaults and keymaps                                     ##
########################################################################

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap

[ -f $sysresources ] && /usr/bin/xrdb -merge $sysresources
[ -f $sysmodmap ] && /usr/bin/xmodmap $sysmodmap
[ -f $userresources ] && /usr/bin/xrdb -merge $userresources
[ -f $usermodmap ] && /usr/bin/xmodmap $usermodmap


########################################################################
##  Set background / wallpaper                                        ##
########################################################################

xsetroot -solid grey12 


########################################################################
##  Start Window Manager                                              ##
########################################################################

if [ -z "$DESKTOP_SESSION" -a -x /usr/bin/ck-launch-session ]; then
    exec ck-launch-session $startwm
else
    exec $startwm
fi


########################################################################
And then the window manager startup script looks something like this and starts dbus (if requested)
Code:
#!/bin/sh
#  startdwm v1.1

########################################################################
##  Start DBUS session bus                                            ##
########################################################################

if [ "$1" = '--with-dbus' ]; then
   if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
      eval `dbus-launch --sh-syntax --exit-with-session`
   fi
fi


########################################################################
##  Start dwm Window Manager                                          ##
########################################################################

xsetroot -name "$USER ($DISPLAY)"

exec /usr/bin/dwm


########################################################################
Perhaps you can try the same approach with Openbox.

Last edited by GazL; 11-07-2012 at 07:08 AM.
 
1 members found this post helpful.
Old 11-07-2012, 08:23 AM   #3
ml4711
Member
 
Registered: Aug 2012
Location: Ryomgård, Danmark
Distribution: Slackware64
Posts: 84

Rep: Reputation: 39
I had this error with xmonad:

XDM authorization key matches an existing client!xmonad-x86_64-linux: user error (openDisplay)

An easy solution is to add one line to /etc/X11/xdm/xdm-config

Code:
DisplayManager*authorize: true
DisplayManager*authName: MIT-MAGIC-COOKIE-1   <-- add this line
 
Old 11-07-2012, 03:56 PM   #4
D1ver
Member
 
Registered: Jan 2010
Distribution: Slackware 13.37
Posts: 527
Blog Entries: 3

Rep: Reputation: 126Reputation: 126
Interesting.. I installed Openbox using the 14.0 Slackbuilds on a fresh install of 14.0 and have had no issues..
 
Old 11-08-2012, 01:26 AM   #5
alexbrui
LQ Newbie
 
Registered: Nov 2009
Location: Ukraine
Distribution: Slackware 13.37
Posts: 27

Original Poster
Rep: Reputation: 0
Just tried to add
Code:
DisplayManager*authName: MIT-MAGIC-COOKIE-1
to my xdm-config and this solves issue with starting OpenBox from XDM. But message
Quote:
cannot open display "default display"
on run-level 3 still here.

D1ver, maybe different package sets? I didn't install all, e.g. skipped KDE, KDEI, XFCE and Y series. Also skipped some packeges from all other series.
 
Old 11-09-2012, 09:44 AM   #6
alexbrui
LQ Newbie
 
Registered: Nov 2009
Location: Ukraine
Distribution: Slackware 13.37
Posts: 27

Original Poster
Rep: Reputation: 0
Also tried with full Slackware install and issue persist.

Finally I solve it as GazL suggested, but instead creating separate script I add dbus-launch to Openbox startup script.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Starting openbox from GDM2? is it even possible? SSDnoob Linux - Software 1 11-18-2011 02:09 PM
Starting programs maximized in OpenBox mjjzf Linux - Software 0 01-27-2008 05:11 AM
Starting Openbox with Kicker stick to all desktops? frenchn00b Linux - Desktop 1 07-08-2007 12:08 PM
openbox+gdm: session not starting Uruclef Linux - Desktop 1 03-11-2007 07:57 PM
problem starting slackware Nocker Linux - Newbie 3 06-05-2006 11:07 PM


All times are GMT -5. The time now is 01:32 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration