mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-20 11:52:37 +09:00
Bug #1083: Better handling of RM FAILURE in ImageManagerDriver
(cherry picked from commit 8c348ca259)
This commit is contained in:
1 parent
aa60b0f5ac
commit
5a67956e68
1 file changed
+14
-2
@@ -228,13 +228,12 @@ void ImageManagerDriver::protocol(
|
||||
|
||||
if ( rc < 0 )
|
||||
{
|
||||
image->unlock();
|
||||
NebulaLog::log("ImM",Log::ERROR,"Image could not be removed from DB");
|
||||
}
|
||||
|
||||
if ( result == "SUCCESS" )
|
||||
{
|
||||
NebulaLog::log("ImM",Log::ERROR,"Image successfully removed.");
|
||||
NebulaLog::log("ImM",Log::INFO,"Image successfully removed.");
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -267,10 +266,23 @@ error_mkfs:
|
||||
goto error_common;
|
||||
|
||||
error_rm:
|
||||
image->unlock();
|
||||
|
||||
os.str("");
|
||||
os << "Error removing image from repository. Remove file " << source
|
||||
<< " to completely delete image.";
|
||||
|
||||
getline(is,info);
|
||||
|
||||
if (!info.empty() && (info[0] != '-'))
|
||||
{
|
||||
os << ": " << info;
|
||||
}
|
||||
|
||||
NebulaLog::log("ImM", Log::ERROR, os);
|
||||
|
||||
return;
|
||||
|
||||
error_common:
|
||||
getline(is,info);
|
||||
|
||||
|
||||
Reference in new issue
Block a user