Hi Jinmei,

Actually we are trying to have some control over this and have opportunity to 
stopManager if needed.

Anyways, this is not so principal at the moment and I followed your hint, 
removed starManager calling and passed “jmx-manager-start=true” to both 
gemfire.locator.properties and Cache creation routine. Afterwards I observe 
that any call like managementService.getDistributedSystemMXBean() returns null, 
as MBeanJMXAdapter. localGemFireMBean is again empty.

So with in Geode MBeanJMXAdapter. localGemFireMBean somehow is not getting 
filled after cache creation… And actually this was the cause of 
NullPointerException in startManager as well. From Geode code I see that only 
items are put into this Map only from MBeanJMXAdapter.registerMBean() method. 
But I guess this flow should be executed after cache creation while Regions are 
created, nodes connected, etc., is not it?
Or should I take care of this separately?

Thanks,
Vahram

From: Jinmei Liao [mailto:[email protected]]
Sent: Wednesday, February 22, 2017 12:58 PM
To: [email protected]
Subject: Re: NullPointerException during SystemManagementService.startManager

Can you let us know the use case where you need to configure the locator with 
.set("jmx-manager-start", "false") and then call ManagementService.startManager 
manually?

On Wed, Feb 22, 2017 at 9:51 AM, Vahram Aharonyan 
<[email protected]<mailto:[email protected]>> wrote:
Hi Anthony,

Currently I’m using Geode 1.1.0 released last week, but actually saw this 
problem previously with geode-1.0.0-incubating.M3 as well.
BTW, I have not hit this issue with gemfire 8.2.0.6 used before that.

Thanks,
Vahram.

From: Anthony Baker [mailto:[email protected]<mailto:[email protected]>]
Sent: Wednesday, February 22, 2017 8:41 AM
To: [email protected]<mailto:[email protected]>
Subject: Re: NullPointerException during SystemManagementService.startManager

What version of Geode are you using?

On Feb 22, 2017, at 12:09 AM, Vahram Aharonyan 
<[email protected]<mailto:[email protected]>> wrote:

Hi All,

We are getting java.lang.NullPointerException while trying to start JMX Manager 
Node by invoking ManagementService.startManager:

org.apache.geode.management.ManagementException: java.lang.NullPointerException
        at 
org.apache.geode.management.internal.FederatingManager.startManager(FederatingManager.java:139)
        at 
org.apache.geode.management.internal.SystemManagementService.startManager(SystemManagementService.java:467)
Caused by: java.lang.NullPointerException
        at 
org.apache.geode.management.internal.MemberMessenger.broadcastManagerInfo(MemberMessenger.java:64)
        at 
org.apache.geode.management.internal.FederatingManager.startManager(FederatingManager.java:132)
        ... 45 more

This seems to be due to MBeanJMXAdapter. localGemFireMBean being empty by that 
point.

Please note that before startManager call from Java code gemfire locator was 
successfully started, cache was created, necessary Regions were created using 
this configuration:

                        .set("jmx-manager", "true")
                        .set("jmx-manager-start", "false")

Could you please let us know whether we miss something in configuration or 
anything else need to be performed before starting JMX manager Node dynamically?

Thanks,
Vahram.




--
Cheers

Jinmei

Reply via email to