[ 
https://issues.apache.org/jira/browse/KARAF-5768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16491506#comment-16491506
 ] 

ASF GitHub Bot commented on KARAF-5768:
---------------------------------------

jbonofre closed pull request #517: [KARAF-5768] Add AIX platform detection when 
installing karaf as a sy…
URL: https://github.com/apache/karaf/pull/517
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/wrapper/src/main/java/org/apache/karaf/wrapper/commands/Install.java 
b/wrapper/src/main/java/org/apache/karaf/wrapper/commands/Install.java
index 3870bd41b2..8216bda2b7 100644
--- a/wrapper/src/main/java/org/apache/karaf/wrapper/commands/Install.java
+++ b/wrapper/src/main/java/org/apache/karaf/wrapper/commands/Install.java
@@ -157,7 +157,7 @@ public Object execute() throws Exception {
                 System.out.println("    $ rm /etc/init.d/" + 
serviceFile.getName());
             } else {
                                System.out.println("");
-                System.out.println(INTENSITY_BOLD + "On Redhat/Fedora/CentOS 
Systems (SystemV):" + INTENSITY_NORMAL);
+                                System.out.println(INTENSITY_BOLD + "On 
Redhat/Fedora/CentOS Systems (SystemV):" + INTENSITY_NORMAL);
                                System.out.println("  To install the service:");
                                System.out.println("    $ ln -s 
"+serviceFile.getPath()+" /etc/init.d/");
                                System.out.println("    $ chkconfig 
"+serviceFile.getName()+" --add");
@@ -179,7 +179,7 @@ public Object execute() throws Exception {
                                System.out.println("    $ rm 
/etc/init.d/"+serviceFile.getName());
 
                                System.out.println("");
-                System.out.println(INTENSITY_BOLD + "On Ubuntu/Debian Systems 
(SystemV):" + INTENSITY_NORMAL);
+                                System.out.println(INTENSITY_BOLD + "On 
Ubuntu/Debian Systems (SystemV):" + INTENSITY_NORMAL);
                                System.out.println("  To install the service:");
                                System.out.println("    $ ln -s 
"+serviceFile.getPath()+" /etc/init.d/");
                                System.out.println("");
@@ -222,7 +222,9 @@ public Object execute() throws Exception {
             }
 
         } else if (os.startsWith("Solaris") || os.startsWith("SunOS")) {
-            System.out.println("  To install the service:");
+            System.out.println("");
+            System.out.println(INTENSITY_BOLD + "Solaris/SunOS system detected 
:" + INTENSITY_NORMAL);
+            System.out.println("  To install the service (and enable at system 
boot):");
             System.out.println("    $ ln -s " + serviceFile.getPath() + " 
/etc/init.d/");
             System.out.println("");
             System.out.println("  To start the service when the machine is 
rebooted for all multi-user run levels");
@@ -247,8 +249,34 @@ public Object execute() throws Exception {
             System.out.println("    $ rm /etc/init.d/" + 
serviceFile.getName());
             System.out.println("    $ rm /etc/rc0.d/K20" + 
serviceFile.getName());
             System.out.println("    $ rm /etc/rc1.d/K20" + 
serviceFile.getName());
+            System.out.println("    $ rm /etc/rc2.d/S20" + 
serviceFile.getName());
+            System.out.println("    $ rm /etc/rc3.d/S20" + 
serviceFile.getName());
+        } else if (os.startsWith("AIX")) {
+            System.out.println("");
+            System.out.println(INTENSITY_BOLD + "AIX system detected :" + 
INTENSITY_NORMAL);
+            System.out.println("  To install the service (and enable at system 
boot):");
+            System.out.println("    $ ln -s " + serviceFile.getPath() + " 
/etc/rc.d/init.d/");
+            System.out.println("");
+            System.out.println("  To start the service when the machine is 
rebooted for all multi-user run levels");
+            System.out.println("  and stopped for the halt, single-user and 
reboot runlevels:");
+            System.out.println("    $ ln -s /etc/rc.d/init.d/" + 
serviceFile.getName() + " /etc/rc2.d/K20" + serviceFile.getName());
+            System.out.println("    $ ln -s /etc/rc.d/init.d/" + 
serviceFile.getName() + " /etc/rc2.d/S20" + serviceFile.getName());
+            System.out.println("");
+            System.out.println("    If your application makes use of other 
services, then you will need to make");
+            System.out.println("    sure that your application is started 
after, and then shutdown before. This");
+            System.out.println("    is done by controlling the 
startup/shutdown order by setting the right order");
+            System.out.println("    value, which in this example it set to 
20."); 
+            System.out.println("");
+            System.out.println("  To start the service:");
+            System.out.println("    $ /etc/rc.d/init.d/" + 
serviceFile.getName() + " start");
+            System.out.println("");
+            System.out.println("  To stop the service:");
+            System.out.println("    $ /etc/rc.d/init.d/" + 
serviceFile.getName() + " stop");
+            System.out.println("");
+            System.out.println("  To uninstall the service :");
+            System.out.println("    $ rm /etc/rc.d/init.d/" + 
serviceFile.getName());
             System.out.println("    $ rm /etc/rc2.d/K20" + 
serviceFile.getName());
-            System.out.println("    $ rm /etc/rc3.d/K20" + 
serviceFile.getName());
+            System.out.println("    $ rm /etc/rc2.d/S20" + 
serviceFile.getName());
         } else if (os.startsWith("HP-UX")) {
             System.out.println("");
             System.out.println(INTENSITY_BOLD + "HP-UX system detected :" + 
INTENSITY_NORMAL);


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> karaf-service script not working on AIX platforms
> -------------------------------------------------
>
>                 Key: KARAF-5768
>                 URL: https://issues.apache.org/jira/browse/KARAF-5768
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-os-integration
>    Affects Versions: 4.2.0
>         Environment: AIX 
>            Reporter: Baptiste DA ROIT
>            Assignee: Jean-Baptiste Onofré
>            Priority: Major
>
> (x) The karaf-service script generated by the _*wrapper:install*_ command is 
> not working on AIX due to [#KARAF-5729].
> (!) Moreover, the *_wrapper:install_* command does not detect AIX platform 
> and thus does not provide information about how to install an AIX standard 
> compliant service, as described 
> [here|http://www-01.ibm.com/support/docview.wss?uid=isg3T1000661].
>  
>  
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to