Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 201989

Summary: RAStart.sh: [: 46: ==: unexpected operator
Product: z_Archived Reporter: MH <mhilpert>
Component: TPTPAssignee: Samson Wai <samwai>
Status: CLOSED FIXED QA Contact:
Severity: critical    
Priority: P1 CC: igor.alelekov, jkubasta, paulslau
Version: unspecifiedKeywords: plan
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard: closed460
Attachments:
Description Flags
Patch none

Description MH CLA 2007-09-01 20:10:56 EDT
Build ID: I20070625-1500

Steps To Reproduce:
1. Install Agent Controller for Linux (Ubuntu 7.04 64 Bit): unarchive agntctrl.linux_em64t-TPTP-4.4.0.2.zip + ./SetConfig.sh with default values.

2. Try to start agent controller via ./RAStart.sh and just get this:

eclipse_AgentController_4.4.0.2/bin$ ./RAStart.sh 
Starting Agent Controller.
The TEMP environment variable does not point to a valid directory.
Agent Controller will not start.
ACServer failed to start.

3. Try to set TEMP manually and try again:

>TEMP=/tmp
>./RAStart.sh

... with same result.


More information:
Comment 1 MH CLA 2007-09-01 20:26:20 EDT
Well, I forgot to tell, that the first time I started RAStart.sh, I got this:

-----------
Starting Agent Controller.
[: 46: ==: unexpected operator
The TEMP environment variable does not point to a valid directory.
Agent Controller will not start.
ACServer failed to start.
------------

so I commented out the block


---------
if [ x$TEMP == x ]; then
	export TEMP=/tmp
fi
---------


But when I just comment out the if and leave the export statement:

---------
#if [ x$TEMP == x ]; then
	export TEMP=/tmp
#fi
----------

it works:

---------------------
Starting Agent Controller.
ACServer started successfully.
----------------------

There seems to be a bug in this RAStart.sh script.
Comment 2 Samson Wai CLA 2007-09-10 10:47:24 EDT
Hello. I don't have ubuntu so would you mind trying the script below to see if the "[[" operator is supported? Thanks.

#!/bin/sh
if [[ -n $TEMP ]]; then
	if [[ -d $TEMP ]]; then
		echo "Exist"
	else
		echo "TEMP defined but not exist"
	fi
else
	echo "TEMP not defined"
fi
Comment 3 Samson Wai CLA 2007-09-12 12:46:05 EDT
Created attachment 78204 [details]
Patch
Comment 4 Samson Wai CLA 2007-09-13 11:29:18 EDT
Update sizing.
Comment 5 Igor Alelekov CLA 2007-09-13 11:44:08 EDT
Hi Samson,
The patch is good.
Regards
Comment 6 Samson Wai CLA 2007-09-18 12:10:19 EDT
Disapproved by PMC for 4.4.1. Retarget to 4.5.
Comment 7 Samson Wai CLA 2007-10-15 13:20:20 EDT
Fix checked into HEAD 2007/10/15 13:20 EDT.
Comment 8 Paul Slauenwhite CLA 2007-12-19 07:59:21 EST
Please change the target to the 4.5 iteration when this Bugzilla was resolved.
Comment 9 Paul Slauenwhite CLA 2009-06-30 12:09:03 EDT
As of TPTP 4.6.0, TPTP is in maintenance mode and focusing on improving quality by resolving relevant enhancements/defects and increasing test coverage through test creation, automation, Build Verification Tests (BVTs), and expanded run-time execution. As part of the TPTP Bugzilla housecleaning process (see http://wiki.eclipse.org/Bugzilla_Housecleaning_Processes), this enhancement/defect is verified/closed by the Project Lead since this enhancement/defect has been resolved and unverified for more than 1 year and considered to be fixed. If this enhancement/defect is still unresolved and reproducible in the latest TPTP release (http://www.eclipse.org/tptp/home/downloads/), please re-open.