Hi Vivek, By the java inheritance, the 'DirectPodBasedNetworkGuru' class extends the 'DirectNetworkGuru' and executes the method that is failing.
The results you're listing are for networks which are deleted, I was referring to the zones with IDs between 1 and 7 if some of them were deleted: select id from data_center where removed is not null and id >= 1 and id <= 7; Regards, Nicolas Vazquez ________________________________ From: Vivek Kumar <vivek.ku...@indiqus.com.INVALID> Sent: Wednesday, October 28, 2020 3:09 AM To: users@cloudstack.apache.org <users@cloudstack.apache.org> Subject: Re: ListNetwork API giving "ERROR" Hello Nicolas, I can’t find any records by guru_name = ‘DirectNetworkGuru’ In networks table. So I have 2 active zones which is 5 (Advance) and 7 ( Basic ). So if I run query for all available network_guru, I can see removed entry in data_center 5, mysql> select guru_name,data_center_id,removed from networks; +---------------------------+----------------+---------------------+ | guru_name | data_center_id | removed | +---------------------------+----------------+---------------------+ | PublicNetworkGuru | 1 | NULL | | PodBasedNetworkGuru | 1 | NULL | | ControlNetworkGuru | 1 | NULL | | StorageNetworkGuru | 1 | NULL | | DirectPodBasedNetworkGuru | 1 | 2020-10-11 07:22:11 | | PublicNetworkGuru | 2 | NULL | | PodBasedNetworkGuru | 2 | NULL | | ControlNetworkGuru | 2 | NULL | | StorageNetworkGuru | 2 | NULL | | DirectPodBasedNetworkGuru | 2 | 2020-10-10 13:34:50 | | PublicNetworkGuru | 3 | NULL | | PodBasedNetworkGuru | 3 | NULL | | ControlNetworkGuru | 3 | NULL | | StorageNetworkGuru | 3 | NULL | | DirectPodBasedNetworkGuru | 3 | 2020-10-11 07:22:08 | | PublicNetworkGuru | 4 | NULL | | PodBasedNetworkGuru | 4 | NULL | | ControlNetworkGuru | 4 | NULL | | StorageNetworkGuru | 4 | NULL | | DirectPodBasedNetworkGuru | 4 | 2020-10-13 09:37:31 | | PublicNetworkGuru | 5 | NULL | | PodBasedNetworkGuru | 5 | NULL | | ControlNetworkGuru | 5 | NULL | | StorageNetworkGuru | 5 | NULL | | ExternalGuestNetworkGuru | 5 | 2020-10-27 06:17:08 | | ExternalGuestNetworkGuru | 5 | 2020-10-27 06:17:14 | | PublicNetworkGuru | 6 | NULL | | PodBasedNetworkGuru | 6 | NULL | | ControlNetworkGuru | 6 | NULL | | StorageNetworkGuru | 6 | NULL | | DirectPodBasedNetworkGuru | 6 | NULL | | PublicNetworkGuru | 7 | NULL | | PodBasedNetworkGuru | 7 | NULL | | ControlNetworkGuru | 7 | NULL | | StorageNetworkGuru | 7 | NULL | | DirectPodBasedNetworkGuru | 7 | NULL | +---------------------------+----------------+---------------------+ Vivek Kumar nicolas.vazq...@shapeblue.com www.shapeblue.com 3 London Bridge Street, 3rd floor, News Building, London SE1 9SGUK @shapeblue > On 28-Oct-2020, at 9:54 AM, Nicolas Vazquez <nicolas.vazq...@shapeblue.com> > wrote: > > Thanks Vivek, > > The data_center_id is being used to query for not removed datacenters/zones > by ID. Are any of those datacenters with IDs 1 to 7 removed? > > > Regards, > > Nicolas Vazquez > > ________________________________ > From: Vivek Kumar <vivek.ku...@indiqus.com.INVALID > <mailto:vivek.ku...@indiqus.com.INVALID>> > Sent: Tuesday, October 27, 2020 5:02 PM > To: users@cloudstack.apache.org <mailto:users@cloudstack.apache.org> > <users@cloudstack.apache.org <mailto:users@cloudstack.apache.org>> > Subject: Re: ListNetwork API giving "ERROR" > > Hello Nicolas, > > Thanks for the response, > > I have tried to run below query but it didn’t show me any records, Please > find the results from below other queries. > > mysql> select * from networks where guru_name = 'DirectNetworkGuru' and > data_center_id is null; > Empty set (0.00 sec) > > ## > mysql> select * from networks where guru_name = 'DirectNetworkGuru'; > Empty set (0.00 sec) > > mysql> > > ## > > > mysql> select guru_name,data_center_id,removed from networks; > +---------------------------+----------------+---------------------+ > | guru_name | data_center_id | removed | > +---------------------------+----------------+---------------------+ > | PublicNetworkGuru | 1 | NULL | > | PodBasedNetworkGuru | 1 | NULL | > | ControlNetworkGuru | 1 | NULL | > | StorageNetworkGuru | 1 | NULL | > | DirectPodBasedNetworkGuru | 1 | 2020-10-11 07:22:11 | > | PublicNetworkGuru | 2 | NULL | > | PodBasedNetworkGuru | 2 | NULL | > | ControlNetworkGuru | 2 | NULL | > | StorageNetworkGuru | 2 | NULL | > | DirectPodBasedNetworkGuru | 2 | 2020-10-10 13:34:50 | > | PublicNetworkGuru | 3 | NULL | > | PodBasedNetworkGuru | 3 | NULL | > | ControlNetworkGuru | 3 | NULL | > | StorageNetworkGuru | 3 | NULL | > | DirectPodBasedNetworkGuru | 3 | 2020-10-11 07:22:08 | > | PublicNetworkGuru | 4 | NULL | > | PodBasedNetworkGuru | 4 | NULL | > | ControlNetworkGuru | 4 | NULL | > | StorageNetworkGuru | 4 | NULL | > | DirectPodBasedNetworkGuru | 4 | 2020-10-13 09:37:31 | > | PublicNetworkGuru | 5 | NULL | > | PodBasedNetworkGuru | 5 | NULL | > | ControlNetworkGuru | 5 | NULL | > | StorageNetworkGuru | 5 | NULL | > | ExternalGuestNetworkGuru | 5 | 2020-10-27 06:17:08 | > | ExternalGuestNetworkGuru | 5 | 2020-10-27 06:17:14 | > | PublicNetworkGuru | 6 | NULL | > | PodBasedNetworkGuru | 6 | NULL | > | ControlNetworkGuru | 6 | NULL | > | StorageNetworkGuru | 6 | NULL | > | DirectPodBasedNetworkGuru | 6 | NULL | > | PublicNetworkGuru | 7 | NULL | > | PodBasedNetworkGuru | 7 | NULL | > | ControlNetworkGuru | 7 | NULL | > | StorageNetworkGuru | 7 | NULL | > | DirectPodBasedNetworkGuru | 7 | NULL | > > > Vivek Kumar > > > > nicolas.vazq...@shapeblue.com <mailto:nicolas.vazq...@shapeblue.com> > www.shapeblue.com<http://www.shapeblue.com> <http://www.shapeblue.com/> > 3 London Bridge Street, 3rd floor, News Building, London SE1 9SGUK > @shapeblue > > > >> On 27-Oct-2020, at 5:12 PM, Nicolas Vazquez <nicolas.vazq...@shapeblue.com> >> wrote: >> >> Hi Vivek, >> >> I took a quick look at the code based on the stack trace and it seems there >> is a network record (or can be multiple records) which does not contain an >> expected value for the data_center_id. >> >> Can you please query DB looking for these records? >> select * from networks where guru_name = 'DirectNetworkGuru' and >> data_center_id is null; >> >> Are you able to reproduce networks creation that produces the same records? >> >> >> Regards, >> >> Nicolas Vazquez >> >> ________________________________ >> From: Vivek Kumar <vivek.ku...@indiqus.com.INVALID> >> Sent: Tuesday, October 27, 2020 3:25 AM >> To: users@cloudstack.apache.org <users@cloudstack.apache.org> >> Subject: ListNetwork API giving "ERROR" >> >> Hello Folks, >> >> I am using 4.13.1 with a KVM (Advance Networking) and a XenServer( Basic >> Networking ) hypervisor. I am seeing a error when I click on network tab. I >> have gone through the logs and It simply says below - Can anyone have any >> any idea ? >> >> >> 2020-10-27 11:49:28,532 ERROR [c.c.a.ApiServer] >> (qtp909295153-19:ctx-92e9fcb9 ctx-bfc647e7) (logid:f752b482) unhandled >> exception executing api command: [Ljava.lang.String;@52d57813 >> java.lang.NullPointerException >> at >> com.cloud.network.guru.DirectNetworkGuru.updateNetworkProfile(DirectNetworkGuru.java:400) >> at >> org.apache.cloudstack.engine.orchestration.NetworkOrchestrator.convertNetworkToNetworkProfile(NetworkOrchestrator.java:3118) >> at com.cloud.api.ApiDBUtils.getNetworkProfile(ApiDBUtils.java:1262) >> at >> com.cloud.api.ApiResponseHelper.createNetworkResponse(ApiResponseHelper.java:2051) >> at >> org.apache.cloudstack.api.command.admin.network.ListNetworksCmdByAdmin.execute(ListNetworksCmdByAdmin.java:44) >> at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:156) >> at com.cloud.api.ApiServer.queueCommand(ApiServer.java:759) >> at com.cloud.api.ApiServer.handleRequest(ApiServer.java:583) >> at >> com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:310) >> at com.cloud.api.ApiServlet$1.run(ApiServlet.java:130) >> at >> org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56) >> at >> org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103) >> at >> org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53) >> at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:127) >> at com.cloud.api.ApiServlet.doGet(ApiServlet.java:89) >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:686) >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:791) >> at >> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:852) >> at >> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:535) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) >> at >> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548) >> at >> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:190) >> at >> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1595) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:188) >> at >> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1253) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:168) >> at >> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:473) >> at >> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1564) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:166) >> at >> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1155) >> at >> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) >> at >> org.eclipse.jetty.server.handler.gzip.GzipHandler.handle(GzipHandler.java:527) >> at >> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126) >> at >> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132) >> at org.eclipse.jetty.server.Server.handle(Server.java:530) >> at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:347) >> at >> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:256) >> at >> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:279) >> at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102) >> at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:124) >> at >> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:247) >> at >> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.produce(EatWhatYouKill.java:140) >> at >> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131) >> at >> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:382) >> at >> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:708) >> at >> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:626) >> at java.lang.Thread.run(Thread.java:748) >> 2020-10-27 11:49:28,540 DEBUG [c.c.a.ApiServlet] >> (qtp909295153-19:ctx-92e9fcb9 ctx-bfc647e7) (logid:f752b482) ===END=== >> 10.212.0.27 -- GET >> command=listNetworks&response=json&listAll=true&page=1&pagesize=20&_=1603779482163 >> >> >> Vivek Kumar >> >> >> >> nicolas.vazq...@shapeblue.com >> www.shapeblue.com<http://www.shapeblue.com> >> <http://www.shapeblue.com/><http://www.shapeblue.com >> <http://www.shapeblue.com/>> >> 3 London Bridge Street, 3rd floor, News Building, London SE1 9SGUK >> @shapeblue