diff -Naur nxnode/NX/scripts/setup/nxnode nxnode-magellan/NX/scripts/setup/nxnode --- nxnode/NX/scripts/setup/nxnode 2010-12-21 11:08:55.000000000 +0100 +++ nxnode-magellan/NX/scripts/setup/nxnode 2010-12-23 19:03:56.000000000 +0100 @@ -98,6 +98,12 @@ return 0 fi + if [ -f /etc/mageversion ]; + then + system=magellan + return 0 + fi + return 1 } @@ -1957,6 +1963,9 @@ elif [ "$system" = "mandrake" ]; then detectedSystem="Mandriva" + elif [ "$system" = "magellan" ]; + then + detectedSystem="Magellan-Linux" fi printMsg "Autodetected system: $detectedSystem" @@ -2171,6 +2180,7 @@ echo " Xandros Desktop 4.1/Xandros Server 2.0 etc." echo " solaris Sun Solaris 10.0 etc." echo " fedora Fedora 10/11/12/13 etc." + echo " magellan Magellan-linux 0.8.x/0.9.x/0.10.x etc." echo "$errMsg" @@ -2309,6 +2319,7 @@ "debian" ) ;; "solaris" ) ;; "macosx" ) ;; + "magellan" ) ;; "" ) ARGS=-1 && errMsg="$PREFIX $ERROR ERROR: Unable to autodetect the operating system type, please specify it" ;; * ) ARGS=-1 && errMsg="$PREFIX $ERROR ERROR: Unsupported operating system '$system'" ;; esac @@ -2447,6 +2458,7 @@ /etc/debian_release /etc/fedora-release /etc/gentoo-release +/etc/mageversion /etc/immunix-release knoppix_version /etc/lfs-release @@ -3826,6 +3838,12 @@ removeNXinit () { + # do nothing on magellan + if [ "$system" = "magellan" ]; + then + return + fi + if [ "$system" = "fedora" ] || [ "$system" = "redhat" ] || [ "$system" = "suse" ]; then if [ -f "/sbin/chkconfig" ]; @@ -4030,6 +4048,11 @@ addNXinit () { + # do nothing on magellan + if [ "$system" = "magellan" ] ; then + return; + fi + if [ "$system" = "macosx" ]; then return @@ -5277,18 +5300,6 @@ printOperationInfo "install" - result=`id nx 2>&1` - if [ $? = 0 ]; - then - printMsg "Cannot add user: nx" "error" - printMsg "User: nx already exists" "error" - printMsgNoDot "To fix the problem, you may try to completely uninstall NX" - printMsgNoDot "Node and install it from scratch. If this is not enough," - printMsgNoDot "please delete the nx user by using the system commands and" - printMsg "proceed with a new installation of NX Node" - exit 1 - fi - checkETCDirectory makeNXConfig @@ -5964,6 +5975,13 @@ # addNXUserLinux () { + + # simply abort if the user exist. on magellan this user is already created. + if id nx > /dev/null 2>&1 + then + return + fi + if [ "x$system" != "xdebian" ] then sysuser=`$USERADDCOMMAND --help 2>&1|grep "\-r"`;