Issue Details (XML | Word | Printable)

Key: GLASSFISH-17940
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Byron Nevins
Reporter: easarina
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
glassfish

disallow running uninstall-node-dcom on DAS machine.

Created: 08/Dec/11 09:04 PM   Updated: 12/Dec/11 11:41 PM   Resolved: 12/Dec/11 11:41 PM
Component/s: distributed management
Affects Version/s: 3.1.2_b12
Fix Version/s: 3.1.2_b14, 4.0_b14

Time Tracking:
Not Specified

Tags:
Participants: Byron Nevins and easarina


 Description  « Hide

Win 2008, GF 3.1.2 build 12.

Executed uninstall-node-dcom on DAS machine against DAS machine. The uninstall process was started and then failed, but it removed bin directory and left all running processes. I believe that self-destructive uninstall should not try to remove the installation on DAS machine.



Byron Nevins added a comment - 08/Dec/11 11:52 PM

Not a common use case to say the least!!

Please give me the exact commands you ran.


Byron Nevins added a comment - 08/Dec/11 11:53 PM

->P4


easarina added a comment - 09/Dec/11 12:05 AM

C:\export>asadmin --user admin --passwordfile password.txt uninstall-node-dcom --installdir C:\export\glassfish3 bigapp-oblade-2
java.lang.NullPointerException
at com.sun.enterprise.admin.cli.cluster.NativeRemoteCommandsBase.removeT
railingSlash(NativeRemoteCommandsBase.java:360)
at com.sun.enterprise.admin.cli.cluster.NativeRemoteCommandsBase.checkIf
NodeExistsForHost(NativeRemoteCommandsBase.java:327)
at com.sun.enterprise.admin.cli.cluster.UninstallNodeBaseCommand.validat
e(UninstallNodeBaseCommand.java:75)
at com.sun.enterprise.admin.cli.CLICommand.execute(CLICommand.java:254)
at com.sun.enterprise.admin.cli.AsadminMain.executeCommand(AsadminMain.j
ava:306)
at com.sun.enterprise.admin.cli.AsadminMain.main(AsadminMain.java:238)
com.sun.enterprise.universal.process.WindowsException: The process cannot access
the file because it is being used by another process.
Command uninstall-node-dcom failed.
The system cannot find the path specified.
======================================
C:\export>cd glassfish3\glassfish

C:\export\glassfish3\glassfish>ls
domains legal lib modules osgi

C:\export\glassfish3\glassfish>
=====================================

Most error messages happened because of the bug:17944

But last messages belong to that command:
====================================================
com.sun.enterprise.universal.process.WindowsException: The process cannot access the file because it is being used by another process.
Command uninstall-node-dcom failed.
====================================================================
The command failed, but GF bin directory was removed. So the installation was corrupted. I don't think that it is a minor issue, because a user just by mistake can run such command and corrupt the installation.


easarina added a comment - 12/Dec/11 09:03 PM

At the comment to the bug 17944 Yamini wrote:

"I'll open a new issue to disallow running install-node-dcom on localhost."

I believe that also should not be allowed to run uninstall-node-dcom on the localhost.


Byron Nevins added a comment - 12/Dec/11 11:41 PM

Thanks for finding this Elena!

All done.

d:\gf\branches\3.1.2\cluster>svn commit d:\gf\trunk\main\nucleus\cluster d:\gf\branches\3.1.2\cluster
Sending D:\gf\branches\3.1.2\cluster\cli\src\main\java\com\sun\enterprise\admin\cli\cluster\UninstallNodeDcomCommand.java
Sending D:\gf\trunk\main\nucleus\cluster\cli\src\main\java\com\sun\enterprise\admin\cli\cluster\UninstallNodeDcomCommand.java
Transmitting file data ..
Committed revision 51506.