[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510765#comment-15510765
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user clebertsuconic commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79900532
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

if ./create can't find libaio, the configuration will be set to NIO and aio 
won't be used.


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510763#comment-15510763
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user clebertsuconic commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79900443
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

Actually no, the ./artemis create will use the libaio to determine the 
journal type (if it can't load libaio, it won't use it).. and it will also 
perform a sync on the system to calculate the timed-buffer values.


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510754#comment-15510754
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user jbertram commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79899679
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

We only need to set the library path for the actual broker instance, right? 
 We don't need to set it for the other CLI commands.


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510746#comment-15510746
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user jbertram commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79899253
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

If the user is on a Linux system then I would expect `uname -a` to return 
`x86_64` or `i686`.  My thought here was to avoid setting the library path for 
systems where `uname -a` returned something other than what we support 
out-of-the-box.


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510726#comment-15510726
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user clebertsuconic commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79898185
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

There are two artemis I think.. one for the distribution, one for the 
instance.


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510724#comment-15510724
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


Github user clebertsuconic commented on a diff in the pull request:

https://github.com/apache/activemq-artemis/pull/788#discussion_r79898051
  
--- Diff: 
artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis
 ---
@@ -105,6 +105,16 @@ if [ -z "$LOG_MANAGER" ] ; then
   LOG_MANAGER="$ARTEMIS_HOME/lib/${logmanager}"
 fi
 
+# determine which native library version to load
+LIBRARY_PATH="-Djava.library.path=\"$ARTEMIS_HOME/bin/lib"
+if [ "$(uname -m)" = "x86_64" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-x86_64\""
+elif [ "$(uname -m)" = "i686" ]; then
+  LIBRARY_PATH="$LIBRARY_PATH/linux-i686\""
+else
+  LIBRARY_PATH=""
--- End diff --

We need something here in case of else.

Say you are on a Linux for a new System, and the user compiled the library 
himself. on that case you need something on the LD_LIBRARY_PATH to work.

Maybe we could have the x86_64 here?


> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15510630#comment-15510630
 ] 

ASF GitHub Bot commented on ARTEMIS-732:


GitHub user jbertram opened a pull request:

https://github.com/apache/activemq-artemis/pull/788

ARTEMIS-732 loading wrong arch lib



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/jbertram/activemq-artemis ARTEMIS-732

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/activemq-artemis/pull/788.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #788


commit 1f4a768b1bf58c1e5fd1b9e1df85ac94ae533037
Author: jbertram 
Date:   2016-09-21T17:41:22Z

ARTEMIS-732 loading wrong arch lib




> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Assignee: Justin Bertram
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ARTEMIS-732) Spurious message while loading native libraries in certain envs.

2016-09-16 Thread Jim Gomes (JIRA)

[ 
https://issues.apache.org/jira/browse/ARTEMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15496516#comment-15496516
 ] 

Jim Gomes commented on ARTEMIS-732:
---

Yes, changing the script so the 32-bit libraries don't get loaded into the 
64-bit runtime makes this error message go away.

> Spurious message while loading native libraries in certain envs.
> 
>
> Key: ARTEMIS-732
> URL: https://issues.apache.org/jira/browse/ARTEMIS-732
> Project: ActiveMQ Artemis
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 1.4.0
> Environment: Debian Linux 64-bit (Stretch), OpenJDK 1.8.0.102
>Reporter: Jim Gomes
>Priority: Blocker
>  Labels: easyfix
> Fix For: 1.5.0
>
> Attachments: artemis, artemis64
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Some systems will throw the following message when loading the wrong bit 
> alignment:
> {noformat}
> OpenJDK 64-Bit Server VM warning: You have loaded library
> /home/username/apache-artemis-1.4.0/bin/lib/linux-i686/libartemis-native-32.so
> which might have disabled stack guard. The VM will try to fix the stack guard 
> now.
> It's highly recommended that you fix the library with 'execstack -c 
> ', or link it with '-z noexecstack'
> {noformat}
> The problem is with the {{exec}} command-line, specifically the 
> {{-Djava.library.path}} parameter. It combines both the 32-bit library path 
> and the 64-bit library path, but it doesn't actually work.  The script should 
> deal with it accordingly to only have the proper  32-bit or 64-bit. All that 
> is necessary is to modify the library path to be platform specific, and the 
> error condition is resolved. I have attached modified script files 
> (*{{artemis}}* and *{{artemis64}}*) that can be used depending on the 
> run-time environment. Here are the key differences between the two scripts:
> {code:title=32-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-i686" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"}}
> {code}
> {code:title=64-bit version}
> exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \
> -classpath "$CLASSPATH" \
> -Dartemis.home="$ARTEMIS_HOME" \
> -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-x86_64" \
> $DEBUG_ARGS \
> org.apache.activemq.artemis.boot.Artemis "$@"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)