Commit 411327e2 authored by Leigh Stoller's avatar Leigh Stoller

Watch for over quota returned from CreateSliver() and say something useful.

parent 8640cca2
......@@ -979,6 +979,7 @@ else {
$rval == GENIRESPONSE_INSUFFICIENT_NODES ||
$rval == GENIRESPONSE_INSUFFICIENT_MEMORY ||
$rval == GENIRESPONSE_INSUFFICIENT_BANDWIDTH ||
$rval == GENIRESPONSE_NOSPACE ||
$rval == GENIRESPONSE_NO_MAPPING) {
AuditAbort()
if (!$debug);
......
......@@ -7061,6 +7061,10 @@ sub GeniExperiment($;$)
GeniUtil::FlipToGeniUser();
if ($saved_exitcode) {
if ($saved_exitcode >> 8 == ENOSPC) {
return GeniResponse->Create(GENIRESPONSE_NOSPACE, undef,
"Over disk quota, please clean up");
}
return GeniResponse->Create(GENIRESPONSE_ERROR, undef,
"Error creating container experiment");
}
......
......@@ -168,6 +168,15 @@ function Do_GetInstanceStatus()
$blob["reason"] = "Your topology source contains invalid ".
"values.\n\n";
}
elseif ($webtask->exitcode() == GENIRESPONSE_NOSPACE) {
#
# Over Quota.
#
$blob["reason"] = "You are over your disk quota at the target ".
"cluster, probably because of too many saved disk images. ".
"Please click on the 'Storage->My Disk Images' above and delete ".
"images you no longer need.";
}
elseif ($webtask->exitcode() == GENIRESPONSE_STITCHER_ERROR) {
#
# This is GENIRESPONSE_STITCHER_ERROR which is a catch all.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment