mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Merge remote-tracking branch 'origin/4.19'
This commit is contained in:
commit
0e32380e0a
@ -415,6 +415,13 @@ public class SnapshotSchedulerImpl extends ManagerBase implements SnapshotSchedu
|
|||||||
if (policyId == Snapshot.MANUAL_POLICY_ID) {
|
if (policyId == Snapshot.MANUAL_POLICY_ID) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (_volsDao.findById(policy.getVolumeId()) == null) {
|
||||||
|
s_logger.warn("Found snapshot policy ID: " + policyId + " for volume ID: " + policy.getVolumeId() + " that does not exist or has been removed");
|
||||||
|
removeSchedule(policy.getVolumeId(), policy.getId());
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
final Date nextSnapshotTimestamp = getNextScheduledTime(policyId, _currentTimestamp);
|
final Date nextSnapshotTimestamp = getNextScheduledTime(policyId, _currentTimestamp);
|
||||||
SnapshotScheduleVO spstSchedVO = _snapshotScheduleDao.findOneByVolumePolicy(policy.getVolumeId(), policy.getId());
|
SnapshotScheduleVO spstSchedVO = _snapshotScheduleDao.findOneByVolumePolicy(policy.getVolumeId(), policy.getId());
|
||||||
if (spstSchedVO == null) {
|
if (spstSchedVO == null) {
|
||||||
|
|||||||
@ -26,6 +26,19 @@ log_it() {
|
|||||||
# Restart journald for setting changes to apply
|
# Restart journald for setting changes to apply
|
||||||
systemctl restart systemd-journald
|
systemctl restart systemd-journald
|
||||||
|
|
||||||
|
# Restore the persistent iptables nat, rules and filters for IPv4 and IPv6 if they exist
|
||||||
|
ipv4="/etc/iptables/rules.v4"
|
||||||
|
if [ -e $ipv4 ]
|
||||||
|
then
|
||||||
|
iptables-restore < $ipv4
|
||||||
|
fi
|
||||||
|
|
||||||
|
ipv6="/etc/iptables/rules.v6"
|
||||||
|
if [ -e $ipv6 ]
|
||||||
|
then
|
||||||
|
ip6tables-restore < $ipv6
|
||||||
|
fi
|
||||||
|
|
||||||
CMDLINE=/var/cache/cloud/cmdline
|
CMDLINE=/var/cache/cloud/cmdline
|
||||||
TYPE=$(grep -Po 'type=\K[a-zA-Z]*' $CMDLINE)
|
TYPE=$(grep -Po 'type=\K[a-zA-Z]*' $CMDLINE)
|
||||||
if [ "$TYPE" == "router" ] || [ "$TYPE" == "vpcrouter" ] || [ "$TYPE" == "dhcpsrvr" ]
|
if [ "$TYPE" == "router" ] || [ "$TYPE" == "vpcrouter" ] || [ "$TYPE" == "dhcpsrvr" ]
|
||||||
@ -52,17 +65,4 @@ do
|
|||||||
systemctl disable --now --no-block $svc
|
systemctl disable --now --no-block $svc
|
||||||
done
|
done
|
||||||
|
|
||||||
# Restore the persistent iptables nat, rules and filters for IPv4 and IPv6 if they exist
|
|
||||||
ipv4="/etc/iptables/rules.v4"
|
|
||||||
if [ -e $ipv4 ]
|
|
||||||
then
|
|
||||||
iptables-restore < $ipv4
|
|
||||||
fi
|
|
||||||
|
|
||||||
ipv6="/etc/iptables/rules.v6"
|
|
||||||
if [ -e $ipv6 ]
|
|
||||||
then
|
|
||||||
ip6tables-restore < $ipv6
|
|
||||||
fi
|
|
||||||
|
|
||||||
date > /var/cache/cloud/boot_up_done
|
date > /var/cache/cloud/boot_up_done
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user