Return-Path: X-Original-To: apmail-cloudstack-users-archive@www.apache.org Delivered-To: apmail-cloudstack-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5776C10ADE for ; Sun, 9 Feb 2014 12:25:29 +0000 (UTC) Received: (qmail 97661 invoked by uid 500); 9 Feb 2014 12:25:27 -0000 Delivered-To: apmail-cloudstack-users-archive@cloudstack.apache.org Received: (qmail 96891 invoked by uid 500); 9 Feb 2014 12:25:26 -0000 Mailing-List: contact users-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cloudstack.apache.org Delivered-To: mailing list users@cloudstack.apache.org Received: (qmail 96872 invoked by uid 99); 9 Feb 2014 12:25:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 09 Feb 2014 12:25:25 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of rafaelweingartner@gmail.com designates 209.85.216.47 as permitted sender) Received: from [209.85.216.47] (HELO mail-qa0-f47.google.com) (209.85.216.47) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 09 Feb 2014 12:25:21 +0000 Received: by mail-qa0-f47.google.com with SMTP id j5so7879272qaq.6 for ; Sun, 09 Feb 2014 04:25:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=S493QNQ5eb/0Uv5YVMepCD26upE5U4BRiDTLGoeeNEA=; b=iM2z8o5JqQ8h8kaXeSTFtZQYK0sdvu7LjS9aJGy/s9RpWt7aBXEaeEcNioHRQvyHbl HEPmbIvYdc2up/bVaKcMi09/fpZrqDzeeIapjnGQloQ7usuxGnPcoj/yOYNLhMvU4vAd GCGk4SMON8Z8dmNxFrOtoWgQliP5TaNdzsgUNnc5jDjCIhYmvGF7Q/WS7VHxanaIvp7Y 4+GGLFyLm91rWnQYE4SPr1uTSPtK13CnF160S5C8eQy5CSykaa/Cn2NXpLg1RoU0WIPj fdoEuV+hrq05nT+zQQGHp4W6YIYCberj0h2e3b5o5Kg8TRiPBd8Mfh4/72szYneMx+qS fG9A== MIME-Version: 1.0 X-Received: by 10.140.44.6 with SMTP id f6mr36319589qga.10.1391948700175; Sun, 09 Feb 2014 04:25:00 -0800 (PST) Received: by 10.140.102.146 with HTTP; Sun, 9 Feb 2014 04:25:00 -0800 (PST) In-Reply-To: References: <484E2F78-CD38-4D34-836B-5CCFFDFD9855@shapeblue.com> Date: Sun, 9 Feb 2014 10:25:00 -0200 Message-ID: Subject: Re: Move running vm to project From: Rafael Weingartner To: "users@cloudstack.apache.org" , dev@cloudstack.apache.org Content-Type: multipart/alternative; boundary=001a113a9cd0d1d13104f1f84f51 X-Virus-Checked: Checked by ClamAV on apache.org --001a113a9cd0d1d13104f1f84f51 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hey all, sorry to bring back this topic again. But, I am curious. I was looking at the CS source code, at the method "com.cloud.vm.UserVmManagerImpl.moveVMToUser(AssignVMCmd)" I found this: if (newAccount =3D=3D null || newAccount.getType() =3D=3D Account.ACCOUNT_TYPE_PROJECT= ) { throw new InvalidParameterValueException("Invalid accountid=3D" + cmd.getAccountName() + " in domain " + cmd.getDomainId()); } Why cannot we transfer one VM to a project? Is there some sort of limitation? On Mon, Jan 20, 2014 at 7:50 AM, Geoff Higginbottom < geoff.higginbottom@shapeblue.com> wrote: > I actually tried that 30 mins ago and unfortunately it does not work > > Regards > > Geoff Higginbottom > > D: +44 20 3603 0542 | S: +44 20 3603 0540 | M: +447968161581 > > geoff.higginbottom@shapeblue.com > > -----Original Message----- > From: Sean Hamilton [mailto:sean@seanhamilton.co.uk] > Sent: 20 January 2014 09:47 > To: users@cloudstack.apache.org > Subject: Re: Move running vm to project > > Rafael, > > If you look at the account table in the cloud database, you'll see that > some fields in account_name look like *PrjAcct-[Project Name]-2 *they hav= e > the type set as 5: select * from cloud.account where type =3D5; > > I think that if you use the migrateVM API command and make this user the > owner, it will get moved into that project. You can see that this user > account 'owns' all vms within that project. > > Not sure if this helps at all... > > Sean > > > On 19 January 2014 16:32, Rafael Weingartner >wrote: > > > Well, I could do that. However, this way seems that the VM is just > > going to be migrate to that user and not to a project. Unless the > > 'master' account of a project has the ability to migrate its VMs to a > > specific project since it can be master in more than one project. > > > > On Sun, Jan 19, 2014 at 2:26 PM, Sean Hamilton > > > > wrote: > > > Isn't there a master user account for a project? This account holds > > resources for that project, including vms. > > > > > > You could list all user accounts in a project and find the 'master' > > account and use migrate VM command? > > > > > >> On 19 Jan 2014, at 15:48, Rafael Weingartner < > > rafaelweingartner@gmail.com> wrote: > > >> > > >> I saw that command, but, reading the docs, it seems that it just > > >> migrate VMs between accounts. > > >> > > >> On Sat, Jan 18, 2014 at 6:22 AM, Geoff Higginbottom > > >> wrote: > > >>> Rafael, > > >>> > > >>> There is a migrate VM API command that allows you to move a VM to > > another account, it might work with projects as we'll but I have not > > tried it. > > >>> > > >>> > > http://cloudstack.apache.org/docs/api/apidocs-4.2/root_admin/assignVir > > tualMachine.html > > >>> > > >>> > > >>> Regards > > >>> > > >>> Geoff Higginbottom > > >>> CTO / Cloud Architect > > >>> > > >>> > > >>> D: +44 20 3603 0542 | S: +44 20 3603 0540 > +442036030540> | M: +447968161581 > > >>> > > >>> geoff.higginbottom@shapeblue.com > geoff.higginbottom@shapeblue.com> | www.shapeblue.com > www.shapeblue.com/> > > >>> > > >>> ShapeBlue Ltd, 53 Chandos Place, Covent Garden, London, WC2N > > 4HS > > >>> > > >>> > > >>> > > >>> On 18 Jan 2014, at 00:47, "Rafael Weingartner" < > > rafaelweingartner@gmail.com> wrote: > > >>> > > >>> Hi, > > >>> I was wondering, is it possible to move a running VM to a project? > > >>> If so, how could I do that? I know that I can do that working > > >>> directly on the database, but this would be an error prone job. > > >>> > > >>> -- > > >>> Rafael Weing?rtner > > >>> Need Enterprise Grade Support for Apache CloudStack? > > >>> Our CloudStack Infrastructure Support< > > http://shapeblue.com/cloudstack-infrastructure-support/> offers the > > best > > 24/7 SLA for CloudStack Environments. > > >>> > > >>> Apache CloudStack Bootcamp training courses > > >>> > > >>> **NEW!** CloudStack 4.2 training< > > http://shapeblue.com/cloudstack-training/> > > >>> 08/09 January 2014, > > >>> London > > >>> 13-17 January 2014, GLOBAL. Instructor led, On-line< > > http://shapeblue.com/cloudstack-training/> > > >>> 20-24 January 2014, GLOBAL. Instructor led, On-line< > > http://shapeblue.com/cloudstack-training/> > > >>> > > >>> This email and any attachments to it may be confidential and are > > intended solely for the use of the individual to whom it is addressed. > > Any views or opinions expressed are solely those of the author and do > > not necessarily represent those of Shape Blue Ltd or related > > companies. If you are not the intended recipient of this email, you > > must neither take any action based upon its contents, nor copy or show > > it to anyone. Please contact the sender if you believe you have receive= d > this email in error. > > Shape Blue Ltd is a company incorporated in England & Wales. ShapeBlue > > Services India LLP is a company incorporated in India and is operated > > under license from Shape Blue Ltd. Shape Blue Brasil Consultoria Ltda > > is a company incorporated in Brasil and is operated under license from > > Shape Blue Ltd. ShapeBlue is a registered trademark. > > >> > > >> > > >> > > >> -- > > >> Rafael Weing=E4rtner > > > > > > > > -- > > Rafael Weing=E4rtner > > > This email and any attachments to it may be confidential and are intended > solely for the use of the individual to whom it is addressed. Any views o= r > opinions expressed are solely those of the author and do not necessarily > represent those of Shape Blue Ltd or related companies. If you are not th= e > intended recipient of this email, you must neither take any action based > upon its contents, nor copy or show it to anyone. Please contact the send= er > if you believe you have received this email in error. Shape Blue Ltd is a > company incorporated in England & Wales. ShapeBlue Services India LLP is = a > company incorporated in India and is operated under license from Shape Bl= ue > Ltd. Shape Blue Brasil Consultoria Ltda is a company incorporated in Bras= il > and is operated under license from Shape Blue Ltd. ShapeBlue is a > registered trademark. > --=20 Rafael Weing=E4rtner --001a113a9cd0d1d13104f1f84f51--