Discussion:
[Fluxbox-users] BScreen::BScreen: error, unable to use fluxbox.
Sharon Kimble
2013-05-19 16:57:38 UTC
Permalink
I am totally unable to run fluxbox for the last two days and I get this
error message in the logs -
##############################
BScreen::BScreen: an error occured while querying the X server.
another window manager already running on display:0.0
Error: Couldn't find screens to manage.
Make sure you don't have another window manager running.
##############################
there is nothing that seems to clear it, it even comes up after a
reboot or a shutdown. I've looked on the wiki and not being able to
find anything relating to it, so I'm hoping you gurus can come up with
a solution for me so that I can go back to my beloved fluxbox again.

There is no other Windows Manager running, I've checked in 'pstree' and
its happened to a new user that I created after yesterdays attempts.

Hopefully thanks
Sharon.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
Frank Lienhard
2013-05-19 20:20:17 UTC
Permalink
I'm not a guru at all.
But most programs set some sort of lock files. Guessing in this case it could be /tmp/.X0-lock.
Sometimes in -in case of unclean shutdown- the lock file isn't removed, and stay in place.

Do you have a command line after the X-Serverstart fails?
If so you can do a cat on that file (in my running fluxbox session listing the processes give me:
"cat .X0-lock
3222
ps -ef|grep 3222
root 3222 3219 0 10:23 tty7 00:01:56 /usr/bin/X11/X -nolisten tcp -auth /var/run/slim.auth vt07"

so maybe deleting the .X0-lock from CLI and reboot could do the trick.
Post by Sharon Kimble
I am totally unable to run fluxbox for the last two days and I get this
error message in the logs -
##############################
BScreen::BScreen: an error occured while querying the X server.
another window manager already running on display:0.0
Error: Couldn't find screens to manage.
Make sure you don't have another window manager running.
##############################
there is nothing that seems to clear it, it even comes up after a
reboot or a shutdown. I've looked on the wiki and not being able to
find anything relating to it, so I'm hoping you gurus can come up with
a solution for me so that I can go back to my beloved fluxbox again.
There is no other Windows Manager running, I've checked in 'pstree' and
its happened to a new user that I created after yesterdays attempts.
Hopefully thanks
Sharon.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d
_______________________________________________
Fluxbox-users mailing list
https://lists.sourceforge.net/lists/listinfo/fluxbox-users
--
Frank Lienhard <***@mclien.de>
Sharon Kimble
2013-05-20 00:03:41 UTC
Permalink
On Sun, 19 May 2013 22:20:17 +0200
Post by Frank Lienhard
I'm not a guru at all.
But most programs set some sort of lock files. Guessing in this case
it could be /tmp/.X0-lock. Sometimes in -in case of unclean shutdown-
the lock file isn't removed, and stay in place.
Thanks Frank, you are a guru you know :). I had a look for .Xo-lock
in /tmp, found it and thought it looked odd so had a look at its
permissions. All owned by root! chowned it, logged off lxde and logged
straight into fluxbox! Brilliant, thanks!

Sharon.
Post by Frank Lienhard
Do you have a command line after the X-Serverstart fails?
If so you can do a cat on that file (in my running fluxbox session
listing the processes give me: "cat .X0-lock
3222
ps -ef|grep 3222
root 3222 3219 0 10:23 tty7 00:01:56 /usr/bin/X11/X
-nolisten tcp -auth /var/run/slim.auth vt07"
so maybe deleting the .X0-lock from CLI and reboot could do the trick.
Post by Sharon Kimble
I am totally unable to run fluxbox for the last two days and I get
this error message in the logs -
##############################
BScreen::BScreen: an error occured while querying the X server.
another window manager already running on display:0.0
Error: Couldn't find screens to manage.
Make sure you don't have another window manager running.
##############################
there is nothing that seems to clear it, it even comes up after a
reboot or a shutdown. I've looked on the wiki and not being able to
find anything relating to it, so I'm hoping you gurus can come up
with a solution for me so that I can go back to my beloved fluxbox
again.
There is no other Windows Manager running, I've checked in 'pstree'
and its happened to a new user that I created after yesterdays
attempts.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
andrew
2013-05-20 00:19:22 UTC
Permalink
Post by Sharon Kimble
Thanks Frank, you are a guru you know :). I had a look for .Xo-lock
in /tmp, found it and thought it looked odd so had a look at its
permissions. All owned by root! chowned it, logged off lxde and logged
straight into fluxbox! Brilliant, thanks!
Might be worthwhile setting a script to clear /tmp at shutdown?

Andrew
--
You think that's air you're breathing now?
Sharon Kimble
2013-05-20 14:03:53 UTC
Permalink
On Mon, 20 May 2013 10:19:22 +1000
Post by andrew
Post by Sharon Kimble
Thanks Frank, you are a guru you know :). I had a look for .Xo-lock
in /tmp, found it and thought it looked odd so had a look at its
permissions. All owned by root! chowned it, logged off lxde and
logged straight into fluxbox! Brilliant, thanks!
Might be worthwhile setting a script to clear /tmp at shutdown?
Andrew.
I already use this script to clear /tmp twice a week, called from cron,
I don’t know if it will help or get someone started on it?
###########################
:
## sudo ./cleartmp.sh -d 7 /tmp
##########################################################################
# Title : cleartmp - remove temporary files/directories
# Author : Heiner Steven <***@odn.de>
# Date : 1992
# Category : System Administration
# Requires : xargs
# SCCS-Id. : @(#) cleartmp 1.2 03/12/19
##########################################################################
# Description
# Delete files older than a specified number of days.
##########################################################################

PN=`basename "$0"` # Program name
VER='1.2'

Days=7 # remove files older than
7 days

usage () {
echo "$PN - remove temporary files/directories, $VER (stv '92)
usage: $PN [-d days] directory [directory ...]

All files and subdirectories older than the specified number of days
(default $Days) are deleted." >&2
exit 1
}

msg () {
for i
do echo "$PN: $i" >&2
done
}

fatal () { msg "$@"; exit 1; }

set -- `getopt hd: "$@"` || usage
while [ $# -gt 0 ]
do
case "$1" in
-d) case "$2" in
[0-9]*) Days="$2"; shift;;
*) fatal "illegal number of days:
$2";; esac;;
--) shift; break;;
-h) usage;;
-*) usage;;
*) break;; # First file name
esac
shift
done

[ $# -lt 1 ] && usage

for i
do
if [ ! -d "$i" ]
then msg "no directory: $i"
elif [ ! -r "$i" -o ! -w "$i" ]
then msg "access denied (need read- and write access): $i"
else
# Find files, links, FIFOs or sockets
find "$i" ! -type d -mtime +$Days -print | xargs rm -f
Post by andrew
/dev/null 2>&1
# remove all empty subdirectories
[ -d "$i" ] || continue
(cd $i || continue
for d in *
do
[ -d "$d" ] || continue
find . -depth -type d -mtime +$Days -print |
xargs rmdir > /dev/null 2>&1
done
)
fi
done

echo "Script run, and /tmp cleared of cruft" 1>&2; exit 1;

exit 0
####################################################

Hope this helps?

Thanks
Sharon.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
Andrej
2013-05-20 20:59:47 UTC
Permalink
I'd say this is potentially dangerous to run. I have pipes sitting in
/tmp from long-running
processes with a last modified timestamp of more than a week old.
Culling those via
cron may have undesirable effects :)

Of course, if your machine gets shut-down daily the risk is small.

I'd suggest a script that runs early in init (e.g. after mounting of
tmp but before daemons
are making use of it) and deletes files. Or using a script that
checks whether files it's
about to delete aren't listed in 'lsof" output.


My 2 cents.


Cheers,
Andrej
Post by Sharon Kimble
On Mon, 20 May 2013 10:19:22 +1000
Post by andrew
Post by Sharon Kimble
Thanks Frank, you are a guru you know :). I had a look for .Xo-lock
in /tmp, found it and thought it looked odd so had a look at its
permissions. All owned by root! chowned it, logged off lxde and
logged straight into fluxbox! Brilliant, thanks!
Might be worthwhile setting a script to clear /tmp at shutdown?
Andrew.
I already use this script to clear /tmp twice a week, called from cron,
I don’t know if it will help or get someone started on it?
###########################
## sudo ./cleartmp.sh -d 7 /tmp
##########################################################################
# Title : cleartmp - remove temporary files/directories
# Date : 1992
# Category : System Administration
# Requires : xargs
##########################################################################
# Description
# Delete files older than a specified number of days.
##########################################################################
PN=`basename "$0"` # Program name
VER='1.2'
Days=7 # remove files older than
7 days
usage () {
echo "$PN - remove temporary files/directories, $VER (stv '92)
usage: $PN [-d days] directory [directory ...]
All files and subdirectories older than the specified number of days
(default $Days) are deleted." >&2
exit 1
}
msg () {
for i
do echo "$PN: $i" >&2
done
}
while [ $# -gt 0 ]
do
case "$1" in
-d) case "$2" in
[0-9]*) Days="$2"; shift;;
$2";; esac;;
--) shift; break;;
-h) usage;;
-*) usage;;
*) break;; # First file name
esac
shift
done
[ $# -lt 1 ] && usage
for i
do
if [ ! -d "$i" ]
then msg "no directory: $i"
elif [ ! -r "$i" -o ! -w "$i" ]
then msg "access denied (need read- and write access): $i"
else
# Find files, links, FIFOs or sockets
find "$i" ! -type d -mtime +$Days -print | xargs rm -f
Post by andrew
/dev/null 2>&1
# remove all empty subdirectories
[ -d "$i" ] || continue
(cd $i || continue
for d in *
do
[ -d "$d" ] || continue
find . -depth -type d -mtime +$Days -print |
xargs rmdir > /dev/null 2>&1
done
)
fi
done
echo "Script run, and /tmp cleared of cruft" 1>&2; exit 1;
exit 0
####################################################
Hope this helps?
Thanks
Sharon.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d
_______________________________________________
Fluxbox-users mailing list
https://lists.sourceforge.net/lists/listinfo/fluxbox-users
--
Please don't top post, and don't use HTML e-Mail :} Make your quotes concise.

http://www.georgedillon.com/web/html_email_is_evil.shtml
Frank Lienhard
2013-05-20 09:02:19 UTC
Permalink
Hi Sharon,

still strange. Mine is owned by root too, but has read permissions to everyone (444). Have you looked at the date stamp? (should be from the last boot, at least thats the case on my PC).
And have a look what permissions it has after next reboot.

Frank
Post by Sharon Kimble
On Sun, 19 May 2013 22:20:17 +0200
Post by Frank Lienhard
I'm not a guru at all.
But most programs set some sort of lock files. Guessing in this case
it could be /tmp/.X0-lock. Sometimes in -in case of unclean shutdown-
the lock file isn't removed, and stay in place.
Thanks Frank, you are a guru you know :). I had a look for .Xo-lock
in /tmp, found it and thought it looked odd so had a look at its
permissions. All owned by root! chowned it, logged off lxde and logged
straight into fluxbox! Brilliant, thanks!
Sharon.
Post by Frank Lienhard
Do you have a command line after the X-Serverstart fails?
If so you can do a cat on that file (in my running fluxbox session
listing the processes give me: "cat .X0-lock
3222
ps -ef|grep 3222
root 3222 3219 0 10:23 tty7 00:01:56 /usr/bin/X11/X
-nolisten tcp -auth /var/run/slim.auth vt07"
so maybe deleting the .X0-lock from CLI and reboot could do the trick.
Post by Sharon Kimble
I am totally unable to run fluxbox for the last two days and I get
this error message in the logs -
##############################
BScreen::BScreen: an error occured while querying the X server.
another window manager already running on display:0.0
Error: Couldn't find screens to manage.
Make sure you don't have another window manager running.
##############################
there is nothing that seems to clear it, it even comes up after a
reboot or a shutdown. I've looked on the wiki and not being able to
find anything relating to it, so I'm hoping you gurus can come up
with a solution for me so that I can go back to my beloved fluxbox
again.
There is no other Windows Manager running, I've checked in 'pstree'
and its happened to a new user that I created after yesterdays
attempts.
--
A taste of linux = http://www.sharons.org.uk/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 7.0, Fluxbox 1.3.5, LibreOffice 4.0.3.3,
Claws-Mail 3.9.0-182-g852877
Registered Linux user 334501
------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d
_______________________________________________
Fluxbox-users mailing list
https://lists.sourceforge.net/lists/listinfo/fluxbox-users
--
Frank Lienhard <***@mclien.de>
Loading...