Bug 1091015 - Unable to delete the remote agent in RHQ server, if we remove (rm -rf rhq-agent/) agent files manually on remote machine
Summary: Unable to delete the remote agent in RHQ server, if we remove (rm -rf rhq-age...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Core UI
Version: 4.11
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: GA
: RHQ 4.11
Assignee: John Mazzitelli
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: JON3-30, PRODMGT-542
TreeView+ depends on / blocked
 
Reported: 2014-04-24 15:30 UTC by Jeeva Kandasamy
Modified: 2014-07-21 10:13 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-07-21 10:13:43 UTC
Embargoed:


Attachments (Terms of Use)
Unable to delete remote agent (75.14 KB, image/jpeg)
2014-04-24 15:30 UTC, Jeeva Kandasamy
no flags Details

Description Jeeva Kandasamy 2014-04-24 15:30:19 UTC
Created attachment 889327 [details]
Unable to delete remote agent

Description of problem:
Unable to delete the remote agent in RHQ server, if we remove (rm -rf rhq-agent/) agent files manually on remote machine. Throws,

---------------snap---------------------
Message : Failed to uninstall agent.
Severity : Error
Time :	Thursday, April 24, 2014 8:27:33 PM UTC+5:30
Root Cause : java.lang.IllegalArgumentException:There does not appear to be an agent installed here: /tmp/tmp/tmp/rhq-agent
Detail : java.lang.RuntimeException:[1398329734471] javax.ejb.EJBException:java.lang.IllegalArgumentException: There does not appear to be an agent installed here: /tmp/tmp/tmp/rhq-agent -> java.lang.IllegalArgumentException:There does not appear to be an agent installed here: /tmp/tmp/tmp/rhq-agent
--- STACK TRACE FOLLOWS ---
[1398329734471] javax.ejb.EJBException:java.lang.IllegalArgumentException: There does not appear to be an agent installed here: /tmp/tmp/tmp/rhq-agent -> java.lang.IllegalArgumentException:There does not appear to be an agent installed here: /tmp/tmp/tmp/rhq-agent
   at Unknown.RuntimeException_0(Unknown Source)
   at Unknown.instantiate_32(Unknown Source)
   at Unknown.$instantiate_0(Unknown Source)
   at Unknown.$instantiate(Unknown Source)
   at Unknown.$readObject(Unknown Source)
   at Unknown.$onResponseReceived(Unknown Source)
   at Unknown.onResponseReceived_4(Unknown Source)
   at Unknown.$fireOnResponseReceived(Unknown Source)
   at Unknown.onReadyStateChange_0(Unknown Source)
   at Unknown.$setOnReadyStateChange/this$static.onreadystatechange<(Unknown Source)
   at Unknown.apply(Unknown Source)
   at Unknown.entry0(Unknown Source)
   at Unknown.entry_0/<(Unknown Source)
   at Unknown.anonymous(Unknown Source)
---------------snap---------------------


Version-Release number of selected component (if applicable):
Version : 4.11.0-SNAPSHOT
Build Number : 1bc9904
GWT Version : 2.5.0
SmartGWT Version : 3.0

Browser: Firefox 28

How reproducible:
always

Steps to Reproduce:
1. Navigate to "Administration-->Agents-->New"
2. Enter remote box details (Agent should not be installed), give some location, example: /tmp/
3. Click on "install Agent", will be installed successfully
4. Do ssh to remote box and stop and delete the agent files manually(rm -rf rha-agent/)
5. Navigate to "Administration-->Agents"
6. Select the agent(which is installed in Step #2) and click "Delete"
7. Unable to delete, throws exception

Actual results:
Unable to delete, throws exception

Expected results:
Might indicate agent not available on the specified location, however should remove entry from RHQ server

Additional info: Screen shot is attached

Comment 1 John Mazzitelli 2014-04-24 19:52:52 UTC
Did this ask you to delete the agent on the remote machine? I thought there should have been a dialog that pops up and asks "Do you want to remove the agent from the remote machine?" If you already removed it, and you say "Yes" and I would suspect this would happen.

Does this happen if you select "No" to the question?

I suppose it should pass even if you say "Yes" - if its already deleted, it should just go. But can you confirm this is when you selected "Yes" from the dialog box, or did it not ask you at all?

Comment 2 John Mazzitelli 2014-04-24 20:04:41 UTC
I just tried this. Yes, it fails if you ask it to remove the agent and it is already deleted.

Workaround: Just don't tell it to delete the agent from the remote box - when it asks "Do you want to delete it from the remote machine", say "No"

Comment 3 John Mazzitelli 2014-04-25 20:09:47 UTC
git commit to master: 1b240136f97cfa677e080c6007a868209543646a

Comment 4 Heiko W. Rupp 2014-07-21 10:13:43 UTC
Bulk closing of RHQ 4.11 issues, now that RHQ 4.12 is out.

If you find an issue with those, please open a new BZ, linking to the old one.


Note You need to log in before you can comment on or make changes to this bug.