qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2] net/net: Change the default mac address of n


From: mike
Subject: Re: [Qemu-devel] [PATCH v2] net/net: Change the default mac address of nic
Date: Fri, 18 Oct 2013 10:54:13 +0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8

On 10/17/2013 08:30 PM, Stefan Hajnoczi wrote:
On Tue, Oct 15, 2013 at 09:33:06PM +0800, mike wrote:
On 10/15/2013 08:36 PM, Eric Blake wrote:
On 10/14/2013 11:07 PM, Stefan Weil wrote:
Is it reasonable to get a random mac address in your guest? I don't
think so. It would no longer be possible to connect to a guest using
ssh, restart that guest and connect again with ssh.
Agreed - libvirt ALWAYS passes a MAC to qemu, even if the user did not
specify a MAC to libvirt, precisely because the MAC must be reproducible
rather than random to avoid changing the guest ABI.  I don't think this
patch is needed - it's up to management to use qemu correctly.
Yes, you are right in this condition. But qemu support Mac address unset.
Also we can get the ip address through a lot of different ways, like use
monitor to get the mac and then get the ip. So we can login use ssh.

But as you mentioned, this patch is not needed, I don't agree with you.

First, this patch just fix the Potential issue of this feature. Now libvirt
maybe can't triggered this issue, who can promise in future will not.

The second is,  qemu not only be used by libvirt,  lots of developers like
to use the command line to boot up the guest. And in the future, we
are not sure about other program will use qemu.

The third is, when one feature has a issue in qemu,
no matter when it is been triggered, should we not fix it?
NACK

I'm not going to merge this patch:

If you terminate QEMU and launch it again the NIC gets a different MAC
address.  Some guest operating systems are sensitive to this - under
For these users must use -device <nic-model>,mac=XX:XX:XX:XX:XX:XX.
I think no body will boot up the guest, which sensitive to this, without mac address.

Actually, people use the command line without mac address, mean they mainly
don't care about mac address, so give them random mac address is reasonable
I think.

In my opinion, if we fix this, for qemu side no any issue, we both support
mac address set or unset correctly.

What am I confuse is, *qemu supports mac address unset, why we force
users must set the address when more than one guests*?
This is unreasonable.

many Linux distros the network interfaces names change due to the MAC
address change.  As a result firewall configuration will break and other
services may fail to start because they cannot find the interface.
Agree, so this mac address should set in qemu command line as
libvirt does :)
If you have multiple guests or want control over the MAC address, set it
explicitly using -device <nic-model>,mac=XX:XX:XX:XX:XX:XX.
Currently, especially for developers, people mainly use qemu
command line directly, and as qemu supports mac address
unset, they may try the simplest command line to boot up
lots of guests, they will confuse about why all this guest use
the same mac address.

Thanks
Mike
Stefan







reply via email to

[Prev in Thread] Current Thread [Next in Thread]