incubator-cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rohit Yadav (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-84) Getting Null Pointer Excpetion while executing listRouters command after deleting a user project.
Date Mon, 17 Sep 2012 15:24:07 GMT

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

Rohit Yadav commented on CLOUDSTACK-84:
---------------------------------------

On UI the infrastructure page (listCapacity API) does not include no. of virtual routers that
are deployed with any project. But when routers are viewed two listRouter APIs are fired (one
with projectId=-1 to return all of the VRs with projects), bug probably?

The problem is checkAccess (DomainChecker) fails as caller (admin user) id is != virtualrouter's
account Id (which is the project account id), and the project is already removed.
                
> Getting Null Pointer Excpetion while executing listRouters command after deleting a user
project.
> -------------------------------------------------------------------------------------------------
>
>                 Key: CLOUDSTACK-84
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-84
>             Project: CloudStack
>          Issue Type: Bug
>          Components: Network Controller
>    Affects Versions: pre-4.0.0
>         Environment: Management sever : Rhel 6.3
> Setup : Advanced
> Host : XenServer 6.0.2
> Build Details :-
> Git Revision: 03df2fa9dd45c938f72cd1866044b09d1b0cc978
> Git URL: https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.git
>            Reporter: Abhinav Roy
>            Assignee: Rohit Yadav
>             Fix For: pre-4.0.0
>
>         Attachments: api-server.log, Cloudstack-84.jpg, management-server.log
>
>
> Steps to reproduce :
> -------------------------
> 1. Deploy a CS advanced networking setup.
> 2. create a sub-domain 'Domain1' under 'ROOT' domain.
> 3. Create 2 users - user1 and user2 under 'Domain1'.
> 4. login as user1 and create a project. Add user2 to the project.
> 5. Create 2 VMs , one as user1 and the other as user2.
> 6. Login as user1(project admin) and delete the project.
> Expected Behaviour :
> ------------------------------
> The project deletion along with deletion of all the resources associated with the project
should be successful and no error should be seen.
> Observed Behaviour :
> ------------------------------
> 1. Got this Exception during project deletion :
> 2012-09-12 17:22:30,545 DEBUG [network.router.VirtualNetworkApplianceManagerImpl] (Job-Executor-26:job-40)
Attempting to destroy router 82012-09-12 17:22:30,547 WARN  [cloud.network.NetworkManagerImpl]
(Job-Executor-26:job-40) Unable to complete destroy of the network due to element: VirtualRoutercom.cloud.exception.PermissionDeniedException:
Acct[6-user4] does not have permission to operate with resource VM[DomainRouter|r-8-VM]  
     at com.cloud.acl.DomainChecker.checkAccess(DomainChecker.java:128)        at com.cloud.user.AccountManagerImpl.checkAccess(AccountManagerImpl.java:353)
       at com.cloud.network.router.VirtualNetworkApplianceManagerImpl.destroyRouter(VirtualNetworkApplianceManagerImpl.java:381)
       at com.cloud.network.element.VirtualRouterElement.destroy(VirtualRouterElement.java:641)
       at com.cloud.network.NetworkManagerImpl.destroyNetwork(NetworkManagerImpl.java:3554)
       at com.cloud.utils.db.DatabaseCallback.intercept(DatabaseCallback.java:34)        at
com.cloud.user.AccountManagerImpl.cleanupAccount(AccountManagerImpl.java:587)        at com.cloud.user.AccountManagerImpl.deleteAccount(AccountManagerImpl.java:475)
       at com.cloud.projects.ProjectManagerImpl.cleanupProject(ProjectManagerImpl.java:305)
       at com.cloud.projects.ProjectManagerImpl.deleteProject(ProjectManagerImpl.java:286)
       at com.cloud.utils.db.DatabaseCallback.intercept(DatabaseCallback.java:34)        at
com.cloud.projects.ProjectManagerImpl.deleteProject(ProjectManagerImpl.java:265)        at
com.cloud.event.ActionEventCallback.intercept(ActionEventCallback.java:36)        at com.cloud.api.commands.DeleteProjectCmd.execute(DeleteProjectCmd.java:69)
       at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:138)        at com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:449)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)        at
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
       at java.lang.Thread.run(Thread.java:679)2012-09-12 17:22:30,548 WARN  [cloud.user.AccountManagerImpl]
(Job-Executor-26:job-40) Unable to destroy network Ntwk[206|Guest|8] as a part of account
id=8 cleanup.2012-09-12 17:22:30,548 DEBUG [cloud.user.AccountManagerImpl] (Job-Executor-26:job-40)
Deleting vpcs for account 8
> 2012-09-12 17:22:30,550 DEBUG [cloud.user.AccountManagerImpl] (Job-Executor-26:job-40)
Deleting site-to-site VPN customer gateways for account 8
> 2012-09-12 17:22:30,551 INFO  [cloud.user.AccountManagerImpl] (Job-Executor-26:job-40)
Cleanup for account 8 is needed.
> 2. After the deletion was done, when I tried to list the virtual routers, i got the following
Null pointer exception
> Exception while executing ListRoutersCmd:
> java.lang.NullPointerException
>         at com.cloud.api.ApiResponseHelper.populateOwner(ApiResponseHelper.java:3362)
>         at com.cloud.api.ApiResponseHelper.createDomainRouterResponse(ApiResponseHelper.java:1771)
>         at com.cloud.api.commands.ListRoutersCmd.execute(ListRoutersCmd.java:136)
>         at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:138)
>         at com.cloud.api.ApiServer.queueCommand(ApiServer.java:543)
>         at com.cloud.api.ApiServer.handleRequest(ApiServer.java:422)
>         at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:304)
>         at com.cloud.api.ApiServlet.doGet(ApiServlet.java:63)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
>         at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:889)
>         at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:721)
>         at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2268)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
>         at java.lang.Thread.run(Thread.java:679) 
> 3. In UI also we are not able to see the routers on the virtual routers page.
> 4. The issue persists even after restarting Management Server.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message