Return-Path: X-Original-To: apmail-cloudstack-issues-archive@www.apache.org Delivered-To: apmail-cloudstack-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 79E1B17400 for ; Fri, 10 Apr 2015 17:18:12 +0000 (UTC) Received: (qmail 1332 invoked by uid 500); 10 Apr 2015 17:18:12 -0000 Delivered-To: apmail-cloudstack-issues-archive@cloudstack.apache.org Received: (qmail 1300 invoked by uid 500); 10 Apr 2015 17:18:12 -0000 Mailing-List: contact issues-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list issues@cloudstack.apache.org Received: (qmail 1290 invoked by uid 500); 10 Apr 2015 17:18:12 -0000 Delivered-To: apmail-incubator-cloudstack-issues@incubator.apache.org Received: (qmail 1287 invoked by uid 99); 10 Apr 2015 17:18:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Apr 2015 17:18:12 +0000 Date: Fri, 10 Apr 2015 17:18:12 +0000 (UTC) From: "Yiping Zhang (JIRA)" To: cloudstack-issues@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CLOUDSTACK-8376) ghost volumes in projects MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CLOUDSTACK-8376?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId= =3D14489952#comment-14489952 ]=20 Yiping Zhang commented on CLOUDSTACK-8376: ------------------------------------------ I don't know how I ended up with this, and I can't seem to be able to repro= duce it. So if any DB data are needed to help troubleshoot it further, please let me= know what you need, and preferrably give me necessary SQL query to run ag= ainst my DB > ghost volumes in projects > ------------------------- > > Key: CLOUDSTACK-8376 > URL: https://issues.apache.org/jira/browse/CLOUDSTACK-837= 6 > Project: CloudStack > Issue Type: Bug > Security Level: Public(Anyone can view this level - this is the defa= ult.)=20 > Components: Management Server > Affects Versions: 4.3.2 > Environment: RHEL 6.5 x86_64, XenServer 6.2 > Reporter: Yiping Zhang > > I first asked this in users mailing list, but got no answers other than s= omeone thinks it might be a bug. So here I am: > We always create VM instances in project context, so that all resources a= re assigned to project instead of individual accounts. I have a script to = call listProjects API to show project=E2=80=99s resource limits and current= usages. > Recently, I noticed that for a couple of projects, my script reports a di= fferent number of volumes from what I can see in web UI for these projects.= Poking around in mysql db, it looks like web UI only reports volumes in R= eady state, while listProjects API reports volumes in both Ready and Destro= y states. > Following is a project where UI says it has two volumes while listProject= s API says it has nine: > mysql> select v.id, v.name, v.state, v.removed, v.path from volumes v, pr= ojects p where v.account_id =3D p.project_account_id and p.name=3D'activity= service' and v.state !=3D 'Expunged'; > +------+-----------+---------+---------------------+---------------------= -----------------+ > | id | name | state | removed | path = | > +------+-----------+---------+---------------------+---------------------= -----------------+ > | 961 | ROOT-1053 | Destroy | 2015-03-02 21:36:09 | NULL = | > | 965 | ROOT-1061 | Destroy | 2015-03-03 00:25:17 | NULL = | > | 966 | ROOT-1063 | Destroy | 2015-03-03 00:28:16 | NULL = | > | 967 | ROOT-1066 | Destroy | 2015-03-03 00:41:48 | NULL = | > | 968 | ROOT-1067 | Destroy | 2015-03-03 00:49:11 | NULL = | > | 969 | ROOT-1069 | Destroy | 2015-03-03 00:53:08 | NULL = | > | 970 | ROOT-1070 | Destroy | 2015-03-03 00:53:52 | NULL = | > | 1000 | ROOT-1100 | Ready | NULL | 2c315f38-3a5f-4b2e-a= 765-332ddbe7a938 | > | 1217 | ROOT-1314 | Ready | NULL | 1d3f6716-d607-4d9d-b= 71c-93b7a88cd064 | > +------+-----------+---------+---------------------+---------------------= -----------------+ > 9 rows in set (0.00 sec) > mysql> > These ghost volumes are counted into project=E2=80=99s total usage of pri= mary storage, so I=E2=80=99d like to get rid of them to free up space for r= eal volumes. > How do I clean them up ? Is this a known issue ? -- This message was sent by Atlassian JIRA (v6.3.4#6332)