Bug 1035178

Summary: [Doc Feature] Add guide how to Uninstall the JBoss EAP 6 service from Red Hat Enterprise Linux
Product: [JBoss] JBoss Enterprise Application Platform 6 Reporter: Petr Kremensky <pkremens>
Component: DocumentationAssignee: David Michael <dmichael>
Status: CLOSED CURRENTRELEASE QA Contact: Russell Dickenson <rdickens>
Severity: high Docs Contact: David Michael <dmichael>
Priority: unspecified    
Version: 6.2.0CC: dmichael, nziakova, twells
Target Milestone: ER6Keywords: Documentation, FutureFeature
Target Release: EAP 6.3.0   
Hardware: Unspecified   
OS: Unspecified   
URL: http://documentation-devel.engineering.redhat.com/docs/en-US/JBoss_Enterprise_Application_Platform/6.2/html/Installation_Guide/Install_JBoss_Enterprise_Application_Platform_6_Red_Hat_Enterprise_Linux_Service.html
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Build Name: 14873, Installation Guide-6.2-1 Build Date: 07-11-2013 09:21:49 Topic ID: 3758-548483 [Specified]
Last Closed: 2014-06-28 15:25:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Petr Kremensky 2013-11-27 09:02:02 UTC
Title: Configure JBoss EAP 6 as a Service in Red Hat Enterprise Linux (Zip, Installer)

Describe the issue:
 We should add "uninstall procedure" similar to one in next chapter (EAP as service on windows) http://documentation-devel.engineering.redhat.com/docs/en-US/JBoss_Enterprise_Application_Platform/6.2/html/Installation_Guide/Install_JBoss_Enterprise_Application_Platform_6_Microsoft_Windows_Service.html

Suggestions for improvement:
stop the running service: 
> sudo service jboss-as-standalone.sh stop
remove the EAP from the list of services:
> sudo chkconfig --del jboss-as-standalone.sh
remove any files added during installation:
> sudo rm -rf /etc/jboss-as/ (add some warning for user not to use this command if there are some files other than jboss-as.conf in /etc/jboss-as)
> sudo rm -rf /etc/init.d/jboss-as-standalone.sh

Comment 1 Petr Kremensky 2014-02-26 11:21:13 UTC
*** Bug 1070070 has been marked as a duplicate of this bug. ***

Comment 4 Petr Kremensky 2014-05-30 09:45:21 UTC
Hi David, 
I have a few suggestions here.

1) -------------
Update the "Result" text.
Currently, there is a text:

Result
JBoss EAP 6 starts automatically when the Red Hat Enterprise Linux reaches its default run-level, and stops automatically when the operating system goes through its shutdown routine. 

right after the "Procedure 4.15. Uninstall the JBoss EAP 6 service from Red Hat Enterprise Linux". This "Result" should be moved right after the "Procedure 4.14. Set Up the Service" and we should add one more "Result" at the end of Procedure 4.15 (see "4.8.3. Configure JBoss EAP 6 as a Service in Microsoft Windows Server (Zip, Installer)" which have two "Result" sections)

2) -------------
Stop command differ for RHEL7 (see BZ1094338). We should add some note about it.

3) -------------
Following the steps, user won't remove all created files.
User is encouraged to create three files and one directory during service installation procedure. 
- /etc/jboss-as 
- /etc/jboss-as/jboss-as.conf
- /etc/init.d/jboss-as-standalone.sh
- /etc/init.d/jboss-as-domain.sh

/etc/init.d is standard system directory so user have to delete only listed files
- /etc/init.d/jboss-as-standalone.sh
- /etc/init.d/jboss-as-domain.sh

/etc/jboss-as is not a standard direcory, so if there is no file apart jboss-as.conf you can use 'sudo rm -rf /etc/jboss-as' to delete it, however it's possible that user is using this directory for other tasks (there are also other files), in this case he should use 'sudo rm /etc/jboss-as/jboss-as.conf'.

If you have any questions feel free to ask.
Thanks,
Petr

Comment 7 Petr Kremensky 2014-06-03 10:33:36 UTC
Hi David,
can you please fix also these:

1) ------------- change:
In a terminal, remove the /etc/init.d/jboss-as-standalone.sh and /etc/init.d/jboss-as-domain.sh files added during installation: 
-->>
In a terminal, remove the service starting script /etc/init.d/jboss-as-standalone.sh (/etc/init.d/jboss-as-domain.sh for domain): 

2) ------------- remove the following redundant part:
Otherwise, use the following command:

sudo rm -rf /etc/init.d/jboss-as-standalone.sh

Comment 10 Petr Kremensky 2014-06-10 08:20:36 UTC
I noticed 'there are' is used twice in warning box (...only if there are there are no files...): 
'/etc/jboss-as is not a standard direcory, use this command only if there are there are no files apart from jboss-as.conf in /etc/jboss-as'