[ 
https://issues.apache.org/jira/browse/CASSANDRA-8122?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Marcus Olsson updated CASSANDRA-8122:
-------------------------------------
    Attachment: CASSANDRA-8122.patch

Added patch that checks if the server is starting before using MBeans.

> Undeclare throwable exception while executing 'nodetool netstats localhost'
> ---------------------------------------------------------------------------
>
>                 Key: CASSANDRA-8122
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8122
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Tools
>         Environment: Cassandra: 2.0.9
>            Reporter: Vishal Mehta
>            Priority: Minor
>         Attachments: CASSANDRA-8122.patch
>
>
> *Steps*
> # Stop cassandra service
> # Check netstats of nodetool using 'nodetool netstats localhost'
> # Start cassandra service
> # Again check netstats of nodetool using 'nodetool netstats localhost'
> *Expected output*
> Mode: STARTING
> Not sending any streams. (End of output - no further exceptions)
> *Observed output*
> {noformat}
>  nodetool netstats localhost
> Mode: STARTING
> Not sending any streams.
> Exception in thread "main" java.lang.reflect.UndeclaredThrowableException
>       at com.sun.proxy.$Proxy6.getReadRepairAttempted(Unknown Source)
>       at 
> org.apache.cassandra.tools.NodeProbe.getReadRepairAttempted(NodeProbe.java:897)
>       at 
> org.apache.cassandra.tools.NodeCmd.printNetworkStats(NodeCmd.java:726)
>       at org.apache.cassandra.tools.NodeCmd.main(NodeCmd.java:1281)
> Caused by: javax.management.InstanceNotFoundException: 
> org.apache.cassandra.db:type=StorageProxy
>       at 
> com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getMBean(DefaultMBeanServerInterceptor.java:1095)
>       at 
> com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getAttribute(DefaultMBeanServerInterceptor.java:643)
>       at 
> com.sun.jmx.mbeanserver.JmxMBeanServer.getAttribute(JmxMBeanServer.java:678)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1464)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:97)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1328)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1420)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl.getAttribute(RMIConnectionImpl.java:657)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>       at java.lang.reflect.Method.invoke(Method.java:606)
>       at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:322)
>       at sun.rmi.transport.Transport$1.run(Transport.java:177)
>       at sun.rmi.transport.Transport$1.run(Transport.java:174)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at sun.rmi.transport.Transport.serviceCall(Transport.java:173)
>       at 
> sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:553)
>       at 
> sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:808)
>       at 
> sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:667)
>       at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>       at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>       at java.lang.Thread.run(Thread.java:724)
>       at 
> sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:273)
>       at 
> sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:251)
>       at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:160)
>       at com.sun.jmx.remote.internal.PRef.invoke(Unknown Source)
>       at 
> javax.management.remote.rmi.RMIConnectionImpl_Stub.getAttribute(Unknown 
> Source)
>       at 
> javax.management.remote.rmi.RMIConnector$RemoteMBeanServerConnection.getAttribute(RMIConnector.java:902)
>       at 
> javax.management.MBeanServerInvocationHandler.invoke(MBeanServerInvocationHandler.java:267)
>       ... 4 more
> {noformat}



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

Reply via email to