mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-4661:[DB Upgrade] SecondaryStorage entry in host table before
upgrade is not marked as removed after migrating them to image_store table.
This commit is contained in:
parent
bc98bca7f2
commit
1042136c23
|
|
@ -2197,6 +2197,11 @@ public class Upgrade410to420 implements DbUpgrade {
|
|||
storeInsert.setDate(9, nfs_created);
|
||||
storeInsert.executeUpdate();
|
||||
}
|
||||
|
||||
s_logger.debug("Marking NFS secondary storage in host table as removed");
|
||||
pstmt = conn.prepareStatement("UPDATE `cloud`.`host` SET removed = now() WHERE type = 'SecondaryStorage' and removed is null");
|
||||
pstmt.executeUpdate();
|
||||
pstmt.close();
|
||||
}
|
||||
catch (SQLException e) {
|
||||
String msg = "Unable to migrate secondary storages." + e.getMessage();
|
||||
|
|
|
|||
Loading…
Reference in New Issue