WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] Prevent changing a memory size of Domain-0 even

To: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] Prevent changing a memory size of Domain-0 even if users make a careless mistake
From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Date: Fri, 04 Apr 2008 11:13:33 +0100
Delivery-date: Fri, 04 Apr 2008 03:14:53 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <4EC8963B84D19Akanno.masaki@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AciWPImNyAITsQIvEd2H5AAX8io7RQ==
Thread-topic: [Xen-devel] [PATCH] Prevent changing a memory size of Domain-0 even if users make a careless mistake
User-agent: Microsoft-Entourage/11.4.0.080122
I think it's fair to just say "Don't do that then, you idiot!". :-)

 -- Keir

On 4/4/08 11:06, "Masaki Kanno" <kanno.masaki@xxxxxxxxxxxxxx> wrote:

> Hi,
> 
> If users accidentally change a memory size of Domain-0 to very small
> memory size by xm mem-set command, users will be not able to operate
> Domain-0.  I think that Domain-0 is important for Xen, so I'd like to
> prevent the accident by xm mem-set command.
> 
> This patch prevents changing the memory size of Domain-0 by xm mem-set
> command if specified memory size is smaller than dom0-min-mem in
> xend-config.sxp. 
> 
>  # cat /etc/xen/xend-config.sxp | grep "(dom0-min-mem"
>  (dom0-min-mem 384)
>  # xm list Domain-0
>  Name                                        ID   Mem VCPUs      State
> Time(s)
>  Domain-0                                     0   941     2     r-----
> 62.6
>  # xm mem-set Domain-0 1
>  Error: memory_dynamic_max cannot be changed for safety reasons
>  Usage: xm mem-set <Domain> <Mem>
>  
>  Set the current memory usage for a domain.
>  # xm list Domain-0
>  Name                                        ID   Mem VCPUs      State
> Time(s)
>  Domain-0                                     0   941     2     r-----
> 63.6
> 
> 
> Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
> 
> Best regards,
>  Kan
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel