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

Vladimir Ozerov commented on IGNITE-1493:
-----------------------------------------

Nicholas, 

Looks like we have two places where discussion happens: here and on SO 
(http://stackoverflow.com/questions/32510157/apache-ignite-bus-adraln-error-during-installation-of-cache),
 where I asked for several debug steps to help us understand the issue. To 
avoid miscommunication, lets continue discussion here.

Crash occurs inside OptimizedMarshaller. The easiest workaround which comes to 
my mind is to replace it with another one, e.g. JdkMarshaller which relies on 
standard Java serialization mechanism and is more resource consuming. Insert 
the following code snippet inside "IgniteConfiguration" bean in your XML 
configuration:
{code}
<property name="marshaller">
    <bean class="org.apache.ignite.marshaller.jdk.JdkMarshaller" />
</property>
{code}

To provide a fix for OptimizedMarshaller we need to better understand what is 
going on. Could you please provide the following additional information if 
possible:
 1) "GridUnsafeDataOutput.bytes" array length at the moment of crash. From the 
crash report I see that there is some array of length 4096 on the stack. Most 
probably this is GridUnsafeDataOutput.bytes, but we need to be 100% sure.
2) Run the following program on affected machine and provide the output. This 
way we will know some important runtime parameters of your JVM.
{code}
public static void main(String[] args) {
    sun.misc.Unsafe unsafe = 
org.apache.ignite.internal.util.GridUnsafe.unsafe();

    System.out.println(unsafe.arrayBaseOffset(byte[].class));
    System.out.println(unsafe.arrayIndexScale(byte[].class));
}
{code}

> Fatal exception is thrown during queue instantiation when using Ignite with 
> an HP-UX machine.
> ---------------------------------------------------------------------------------------------
>
>                 Key: IGNITE-1493
>                 URL: https://issues.apache.org/jira/browse/IGNITE-1493
>             Project: Ignite
>          Issue Type: Bug
>          Components: data structures
>         Environment: * HP-UX B.11.31 IA64W machine
> * JRE version: Java(TM) SE Runtime Environment (7.0) (build 
> 1.7.0.14-jinteg_2015_08_07_03_06-b00)
> * Java VM: Java HotSpot(TM) Server VM (24.85-b05-jre1.7.0.14-rc1 mixed mode 
> hp-ux-ia64 )
>            Reporter: Nicholas Dzwill
>            Priority: Blocker
>         Attachments: ErrorLog.txt, server.log
>
>
> A fatal exception is thrown during queue instantiation when using an HP-UX 
> B.11.31 IA64W machine.
> The environment is as follows:
> * JRE version: Java(TM) SE Runtime Environment (7.0) (build 
> 1.7.0.14-jinteg_2015_08_07_03_06-b00)
> * Java VM: Java HotSpot(TM) Server VM (24.85-b05-jre1.7.0.14-rc1 mixed mode 
> hp-ux-ia64 )
> The error logged is as follows:
> * Current thread (01ab2800):  JavaThread "main" [_thread_in_vm, id=23, 
> lwp_id=3525570, stack(4e501000,4e601000)]
>  * siginfo:si_signo=SIGBUS: si_errno=0, si_code=1 (BUS_ADRALN), 
> si_addr=5e038d15
>                    
> The exception above means there is an "invalid address alignment" (writing to 
> an odd memory location) when calling the following method:
> * Class: org.apache.ignite.marshaller.optimized.OptimizedObjectOutputStream
> * Method:
> {code:borderStyle=solid}
>        /** {@inheritDoc} */
>         @Override public void writeInt(int v) throws IOException {
>             requestFreeSize(4);
>             UNSAFE.putInt(bytes, byteArrOff + off, v); // byteArrOff + off = 
> 17 when this exception is thrown
>             onWrite(4);
>         }
> {code}
>         
> Basic setup - Ignite is configured with spring and pushed to the constructor 
> of a class.  That class uses this instance of Ignite to instantiate an 
> IgniteQueue as follows: 
> {code:borderStyle=solid}
>     CollectionConfiguration configuration = new CollectionConfiguration();
>     configuration.setCollocated(true); 
>     IgniteQueue<String> queue = ignite.queue("queue", 0, configuration);
> {code}
>               
> Partial stack:
> * Instantiating the queue calls:      
> ** 
> org.apache.ignite.internal.processors.datastructures.DataStructuresProcessor.compatibleConfiguration()
>  
> * Which in turn calls:
> ** org.apache.ignite.internal.processors.cache.GridCacheAdapter.invoke()
> * Leading to the fatal error when calling:
> ** 
> org.apache.ignite.marshaller.optimized.OptimizedObjectOutputStream.writeInt()
> The error log has been attached with the stack trace of the error.  The 
> server log is also attached.  We are running Ignite in a variety of 
> environments and this issue only appears to exist in this specific 
> environment and is consistently hit in the same place with no apparent 
> work-around.            



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

Reply via email to