[pve-devel] [PATCH 2/7] vmconfig_hotplug_pending : add update_net

Dietmar Maurer dietmar at proxmox.com
Wed Nov 19 10:31:09 CET 2014


> +sub vmconfig_update_net {
> +    my ($storecfg, $conf, $vmid, $opt) = @_;
> +
> +    if ($conf->{$opt}) {
> +        my $running = PVE::QemuServer::check_running($vmid);
> +
> +        my $oldnet = PVE::QemuServer::parse_net($conf->{$opt});
> +        my $newnet =
> + PVE::QemuServer::parse_net($conf->{pending}->{$opt});
> +
> +        if(&$safe_string_ne($oldnet->{model}, $newnet->{model}) ||
> +           &$safe_string_ne($oldnet->{macaddr}, $newnet->{macaddr}) ||
> +           &$safe_num_ne($oldnet->{queues}, $newnet->{queues})){
> +            #for non online change, we try to hot-unplug

what if firewall flag changed?





More information about the pve-devel mailing list