Thanks Sanjay for detailed explanation. I will share the requested counts and output soon.
Regards, Gaurav On Fri, Apr 18, 2014 at 1:37 PM, Sanjay Tripathi <sanjay.tripa...@citrix.com > wrote: > Hi Gaurav, > > Before registering a template, CS checks for template size by making HTTP > call to get the size from remote location using getRemoteSize method. If > the secondary storage count (including this new template) is within limits > then CS will register this template and start the download process. In some > case, these templates are zipped and CS gets this zipped size using HTTP > call, but once templates get downloaded, CS extract this template and > installs it, which results in increase in size of this template; then CS > checks the difference in size(the one from HTTP call and this one after > extraction) and updates the secondary storage count correspondingly. If > this size difference exceeds the sec storage limits, then CS generates an > alert for root-admin (it won't delete this template in this case). > > In the scenario you mentioned, it looks like a bug but I tested this > scenario very well while implementing this feature. After registering two > template of 9GB each, can you check secondary storage count and sec storage > limits in DB; and it would be great if you share the DB output as well. > > --Sanjay > > > -----Original Message----- > From: Gaurav Aradhye [mailto:gaurav.arad...@clogeny.com] > Sent: Thursday, April 17, 2014 7:09 PM > To: dev@cloudstack.apache.org > Subject: Secondary Storage limits > > Hi, > > I came across this scenario where secondary storage limit of the domain > gets exceeded. > > Suppose we have set secondary storage limit for a domain as 20 GB and we > register 2 templates of 10 GB each in the domain. Now as already the limit > is reached, new template won't be registered. > > But suppose we register 2 templates of 9 GB each, then 2 GBs are left > available. But now if I register and download a template of 10 GB, then > still it will be successful although it exceeds the limit. > > This might be happening because it won't know the size of the template > while registering it. But at least then the download operation should fail. > > Is this correct behaviour? If not, I will log a bug for this. > > Regards, > Gaurav >