X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Fopensim%2Fopensim_utils.sh;h=d9f4e11cde1d605a6b323f8ea1a4a9454b9fb1ce;hb=3f15edb47241a3945f22f999209b733dc9f77d21;hp=0f60a174d3711dc441796e55a4ea3ef2a58abe0f;hpb=9cce7a74f4ca8b4b1c15aeb7e17ec68d4a4051a8;p=feisty_meow.git diff --git a/scripts/opensim/opensim_utils.sh b/scripts/opensim/opensim_utils.sh index 0f60a174..d9f4e11c 100644 --- a/scripts/opensim/opensim_utils.sh +++ b/scripts/opensim/opensim_utils.sh @@ -2,6 +2,8 @@ # this is a collection of scripts that assist in managing an opensim server. # it uses the "screen" utility to manage opensimulator instances. +source "$FEISTY_MEOW_SCRIPTS/core/functions.sh" + # set up some parameters that we believe (or have been told) are beneficial. export MONO_THREADS_PER_CPU=408 @@ -33,10 +35,11 @@ function launch_screen() { screen_name="$1"; shift app_name="$1"; shift - echo "$(mdate): starting $screen_name now..." - screen -L -S "$screen_name" -d -m nice -n $NICENESS_LEVEL mono --debug "$app_name" + echo "$(date_stringer): starting $screen_name now..." + screen -L -S "$screen_name" -d -m nice -n $NICENESS_LEVEL mono "$app_name" +##why? --debug #-console=basic - echo "$(mdate): $screen_name started." + echo "$(date_stringer): $screen_name started." sleep $SNOOZE_TIME } @@ -59,13 +62,13 @@ function close_application() { screen_name="$1"; shift process_name="$1"; shift - echo "$(mdate): stopping $screen_name now..." + echo "$(date_stringer): stopping $screen_name now..." screen -r -s "$screen_name" -X quit # we don't want to shut any other servers down until this process is really gone. find_opensim_process $process_name if [ ! -z "$OS_PROC_ID" ]; then - echo "$(mdate): waiting for $screen_name to really shut down..." + echo "$(date_stringer): waiting for $screen_name to really shut down..." sleep $SNOOZE_TIME # check again after the snooze. find_opensim_process $process_name @@ -73,7 +76,7 @@ function close_application() find_opensim_process $process_name #break out on timed basis. done - echo "$(mdate): $screen_name really is shut down now." + echo "$(date_stringer): $screen_name really is shut down now." #do this as last ditch, above in timeout find_opensim_process $process_name @@ -85,6 +88,6 @@ function close_application() fi - echo "$(mdate): $screen_name stopped." + echo "$(date_stringer): $screen_name stopped." }