Linux and Graphics

Message boards : BOINC Manager : Linux and Graphics
Message board moderation

To post messages, you must log in.

AuthorMessage
AtesComp

Send message
Joined: 11 May 07
Posts: 2
United States
Message 10187 - Posted: 11 May 2007, 7:12:26 UTC

It seems that many users have trouble with the "show graphics" button in the manager when running under Linux.

This is a copy of my post under Seti@Home:
==================================================
I have continually had the same kind of problem with BOINC. I'm now on 5.8.15 and still have problems. I think the problem revolves around the way "boinc" and "boincmgr" are run and interact. I only run SETI, so the discussion should be clear.

1. Run "boinc" and "boincmgr" as a regular user:
----------
Select a running task in the task tab and press "show graphics".
This lets me use the "show graphics" button once. When I close the screen (use the x button) and press "show graphics", nothing happens. I have to reboot to get a new graphics screen.

2. Run "boinc" as a daemon during system boot and "boincmgr" as a regular user:
----------
The daemon is setup with service script in my OpenSuSE 10.0 system (this is not well documented).
Need to use the command "xhost +local:" in a terminal before starting "boincmgr" (this is not well documented).
Select a running task in the task tab and press "show graphics".
This used to work, sometimes. Now it doesn't work at all.

I would think that most people would prefer (2) as it runs always as long as the system is on and in my case at runlevel 5.

This second example brings to light the problem with running the graphics under BOINC--the client program is actually doing the graphics, not the manager. Would it not be cleaner, and possibly more flexible, if the manager ran the graphics instead of just sending a command to the client? The manager could connect to the client (RPC, UDP/TCP port, etc) to get the display data and display it locally. This would make creating a screen saver a snap by having it connect to a client and auto-selecting a running task! It also offloads the graphics from the client--all it needs to do is report data in a separate thread.

I see the problem is that each project has its own graphics system. Fix it by having the client send the graphics code for the project to the manager and store it for later use, and update as needed on each reconnect. The servers do this kind of thing for the clients to process the work units so why not have the clients do the same for the managers graphics display.

A possible further problem to this is platform compatibility. Java anyone?

UPDATE: To get a new graphics screen, the client needs to be stopped and restarted after closing the graphics screen. I can recreate this at will using either method 1 or 2. It seems like the client's graphics screen is not closing properly or the client "thinks" the graphics screen is still open. A stop/restart of the client obviously resets this.

UPDATE 2: This has been discussed before in other threads and was referred to as a "graphics hook" not being released. It apparently happens with all the different project graphics. It is true that the computing power is the primary purpose for running this software, but it gives non-techies a reason to buy into this program--graphics adds a "cool" factor--and results in an overall increase in computing power. The frustration continues...
==================================================

This may be a naive understanding of how the graphics system works in BOINC, but the client running as a daemon makes it difficult to open a display screen window on the current user's screen (the xhost problem). Having the manager open the display window eliminates this problem. Any comments?
ID: 10187 · Report as offensive
AtesComp

Send message
Joined: 11 May 07
Posts: 2
United States
Message 10189 - Posted: 11 May 2007, 7:38:59 UTC

Here's the init.d script I'm using in OpenSuSE 10.2:
==================================================
#!/bin/sh
#
### BEGIN INIT INFO
# Provides: boinc
# Required-Start: $network
# Required-Stop: $network
# Default-Start: 3 5
# Default-Stop: 0 1 2 6
# Short-Description: BOINC client as a daemon.
# Description: This script starts the local BOINC client as a daemon.
# For more information about BOINC (the Berkeley Open Infrastructure
# for Network Computing) see http://boinc.berkeley.edu
### END INIT INFO
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

# See also the boinc homepage at:
# http://boinc.berkeley.edu

# Change BOINC_DIR to your installation directory.

BOINC_DIR=/opt/BOINC
BOINC_EXE=$BOINC_DIR/boinc

test -x $BOINC_EXE || {
echo "$BOINC_EXE not installed!";
if [ "$1" = "stop" ]; then
exit 0;
else
exit 5;
fi;
}

# Source function library.
. /etc/rc.status

start() {
echo -n $"Starting up BOINC: "

cd $BOINC_DIR
startproc -v $BOINC_EXE -daemon -redirectio -dir $BOINC_DIR

# Remember status and be verbose
rc_status -v
}

stop() {
echo -n $"Shutting down BOINC: "

killproc -TERM $BOINC_EXE

rc_status -v
}

dostatus() {
echo -n "Checking for service BOINC: "
## Check status with checkproc(8), if process is running
## checkproc will return with exit status 0.

# Return value is slightly different for the status command:
# 0 - service up and running
# 1 - service dead, but pid file exists
# 2 - service dead, but lock file exists
# 3 - service not running (unused)
# 4 - service status unknown :-(
# 5--199 reserved (5--99 LSB, 100--149 distro, 150--199 appl.)

# NOTE: checkproc returns LSB compliant status values.
checkproc $BOINC_EXE
# NOTE: rc_status knows that we called this init script with
# "status" option and adapts its messages accordingly.
rc_status -v
}

restart() {
stop
start
rc_status
}

condrestart() {
status
if test $? = 0; then
restart
else
rc_reset # Not running is not a failure.
fi
}

# Reset status of this service
rc_reset

# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
status)
dostatus
;;
restart|reload)
restart
;;
try-restart)
condrestart
;;
*)
echo "Usage: boinc {start|stop|status|restart|reload|try-restart}"
exit 1
esac

rc_exit

#EOF#
==================================================
ID: 10189 · Report as offensive

Message boards : BOINC Manager : Linux and Graphics

Copyright © 2024 University of California.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.