[X2Go-Commits] x2goserver.git - build-baikal (branch) updated: 3.1.0.1-25-gd285cbe

X2Go dev team git-admin at x2go.org
Wed Dec 4 06:22:05 CET 2013


The branch, build-baikal has been updated
       via  d285cbef38ba3d3346c7aaf09b1d06ff9e592fbb (commit)
      from  f1c987d5219aabd1253b9f7d20ad2a98cddd313d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 debian/changelog                  |    7 +++++--
 x2goserver/bin/x2goresume-session |   30 +++++++++++++++++-------------
 2 files changed, 22 insertions(+), 15 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index cb2e3c8..aa632c6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -11,8 +11,11 @@ x2goserver (3.1.1.0-0~x2go1) UNRELEASED; urgency=low
       by X2Go client applications to retrieve a list of server-side
       supported X2Go features.
     - Update date and version number in man pages.
-    - Add syslogging to SQLite3 session DB backend for occuring
-      DB failures.
+    - Fix race condition between session.log of x2goagent and
+      x2gocleansessions. If x2goagent is now fast enough with appending
+      the new session state to the session.log file, the x2gocleansessions
+      script will mark the session as suspended during the session
+      resuming process.
     - Add X2Go server script x2gogetstatus.
   * Remove /etc/x2go/applications on package removal if it is a
     symlink, keep it, if it is a directory. Remove /etc/x2go
diff --git a/x2goserver/bin/x2goresume-session b/x2goserver/bin/x2goresume-session
index baf639a..04d2eea 100755
--- a/x2goserver/bin/x2goresume-session
+++ b/x2goserver/bin/x2goresume-session
@@ -149,25 +149,28 @@ fi
 
 echo "$NEWOPTIONS" >"${SESSION_DIR}/options"
 
-# we really have to make sure the session database got this write operation
-# this may just be an SQLite issue so...
-# FIXME: probably migrate this piece of code to the SQLite db backend...
-while True; do 
-	$X2GO_LIB_PATH/x2goresume  "$X2GO_CLIENT" "$SESSION_NAME"  "$GR_PORT" "$SOUND_PORT" "$FS_PORT" > /dev/null
-	if [ $($X2GO_LIB_PATH/x2gogetstatus "$SESSION_NAME") == "R" ]; then
-		break;
-	else
-		$X2GO_LIB_PATH/x2gosyslog "$0" "warning" "failed to write to X2Go db, will try again..."
-		sleep 1;
-	fi
-done
-
 # run x2goserver-extensions for pre-resume
 x2gofeature X2GO_RUN_EXTENSIONS &>/dev/null && x2goserver-run-extensions "$SESSION_NAME" pre-resume || true
 
 kill -HUP $X2GO_AGENT_PID &>/dev/null && {
 	$X2GO_LIB_PATH/x2gosyslog "$0" "notice" "client $X2GO_CLIENT has successfully resumed session with ID $SESSION_NAME"
 
+	# FIXME: the below code may not be necessary as we fixed a race condition between x2gocleansessions and x2goagent
+
+	# we really have to make sure the session database gets this write operation
+	# this may just be an SQLite issue so...
+	# FIXME: probably migrate this piece of code to the SQLite db backend...
+	#while true; do
+	#	$X2GO_LIB_PATH/x2goresume  "$X2GO_CLIENT" "$SESSION_NAME"  "$GR_PORT" "$SOUND_PORT" "$FS_PORT" > /dev/null
+	#	if [ $($X2GO_LIB_PATH/x2gogetstatus "$SESSION_NAME") == "R" ]; then
+	#		break;
+	#	else
+	#		$X2GO_LIB_PATH/x2gosyslog "$0" "warning" "failed to write to X2Go db, will try again..."
+	#		sleep 1;
+	#	fi
+	#done
+	$X2GO_LIB_PATH/x2goresume  "$X2GO_CLIENT" "$SESSION_NAME"  "$GR_PORT" "$SOUND_PORT" "$FS_PORT" > /dev/null
+
 	# resume x2godesktopsharing, if it has been in use before the session got suspended
 	x2gofeature X2GO_DESKTOPSHARING &>/dev/null && x2goresume-desktopsharing "$SESSION_NAME" || true
 
@@ -191,3 +194,4 @@ kill -HUP $X2GO_AGENT_PID &>/dev/null && {
 echo "gr_port=$GR_PORT"
 echo "sound_port=$SOUND_PORT"
 echo "fs_port=$FS_PORT"
+


hooks/post-receive
-- 
x2goserver.git (X2Go Server)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "x2goserver.git" (X2Go Server).




More information about the x2go-commits mailing list