Prev: Fix uninitialized variable warning in do_one_initcall
Next: net/ipv4/ip_output.c: Removal of unused variable in ip_fragment()
From: Andrew Fong on 8 Jul 2010 16:50 On Thu, Jul 8, 2010 at 1:36 PM, Loke, Chetan <Chetan.Loke(a)netscout.com> wrote: >> -----Original Message----- >> From: linux-kernel-owner(a)vger.kernel.org [mailto:linux-kernel- >> owner(a)vger.kernel.org] On Behalf Of Matt Domsch >> Sent: July 07, 2010 9:21 PM >> >> http://lwn.net/Articles/356900/ >> >> And on a system where you can use udev rules, the >> 70-persistent-net.rules file can be used to make them constant, by >> using the MAC address to force the names to be what you want. >> > > Ok, but can we achieve the renaming w/o a reboot? You probably can restart the udev subsystem. > > >> -- >> Matt Domsch > > Chetan Loke > -- > To unsubscribe from this list: send the line "unsubscribe linux-net" in > the body of a message to majordomo(a)vger.kernel.org > More majordomo info at �http://vger.kernel.org/majordomo-info.html > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: Kay Sievers on 8 Jul 2010 17:30 On Thu, Jul 8, 2010 at 22:47, Andrew Fong <ayf(a)youtube.com> wrote: > On Thu, Jul 8, 2010 at 1:36 PM, Loke, Chetan <Chetan.Loke(a)netscout.com> wrote: >>> -----Original Message----- >>> From: linux-kernel-owner(a)vger.kernel.org [mailto:linux-kernel- >>> owner(a)vger.kernel.org] On Behalf Of Matt Domsch >>> Sent: July 07, 2010 9:21 PM >>> >>> http://lwn.net/Articles/356900/ >>> >>> And on a system where you can use udev rules, the >>> 70-persistent-net.rules file can be used to make them constant, by >>> using the MAC address to force the names to be what you want. >> >> Ok, but can we achieve the renaming w/o a reboot? > > You probably can restart the udev subsystem. No, udev has not really a concept of being restarted, it will not do anything. You can only synthesize events, so it looks like the device is just plugged in. For that, you need to make sure the interface is not busy, otherwise renaming will fail in interesting ways, especially if names need to be swapped between several devices. Live renaming of interfaces is something you really need to know what you are doing, especially on remote machines. Kay -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: Charlie Brady on 8 Jul 2010 17:40 On Thu, 8 Jul 2010, Loke, Chetan wrote: > > -----Original Message----- > > From: linux-kernel-owner(a)vger.kernel.org [mailto:linux-kernel- > > owner(a)vger.kernel.org] On Behalf Of Matt Domsch > > Sent: July 07, 2010 9:21 PM > > > > http://lwn.net/Articles/356900/ > > > > And on a system where you can use udev rules, the > > 70-persistent-net.rules file can be used to make them constant, by > > using the MAC address to force the names to be what you want. > > Ok, but can we achieve the renaming w/o a reboot? Yes, you can rename interfaces using the 'ip' command. ip link set oldname name newname -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: Loke, Chetan on 8 Jul 2010 18:10 > -----Original Message----- > From: Kay Sievers [mailto:kay.sievers(a)vrfy.org] > Sent: July 08, 2010 5:28 PM > To: Andrew Fong > Cc: Loke, Chetan; Matt Domsch; Michael Di Domenico; linux- > net(a)vger.kernel.org; linux-kernel(a)vger.kernel.org > Subject: Re: nic enumeration > > On Thu, Jul 8, 2010 at 22:47, Andrew Fong <ayf(a)youtube.com> wrote: > > On Thu, Jul 8, 2010 at 1:36 PM, Loke, Chetan > <Chetan.Loke(a)netscout.com> wrote: > >>> -----Original Message----- > >>> From: linux-kernel-owner(a)vger.kernel.org [mailto:linux-kernel- > >>> owner(a)vger.kernel.org] On Behalf Of Matt Domsch > >>> Sent: July 07, 2010 9:21 PM > >>> > >>> http://lwn.net/Articles/356900/ > >>> > >>> And on a system where you can use udev rules, the > >>> 70-persistent-net.rules file can be used to make them constant, by > >>> using the MAC address to force the names to be what you want. > >> > >> Ok, but can we achieve the renaming w/o a reboot? > > > > You probably can restart the udev subsystem. > > No, udev has not really a concept of being restarted, it will not do > anything. You can only synthesize events, so it looks like the device > is just plugged in. For that, you need to make sure the interface is > not busy, otherwise renaming will fail in interesting ways, especially > if names need to be swapped between several devices. > I'm not a udev guru so I don't know how will renaming a simple net_device->name work? What about the msi-x queues created by the driver? May be I missed it but I don't see a single driver tearing apart everything and restarting unless a NETDEV_RENAME somehow automagically reloads the driver. I know it's silly for the driver to tear apart the whole world. But then why allow renaming in the first place, correct? > Live renaming of interfaces is something you really need to know what > you are doing, especially on remote machines. > I agree, I wanted someone to say 'try the symlink attrib'. I really need to create a 'symlink' or a reference to the newly added 'ethX' interface. I have to support 75+ VMs(each w/ 5+ vNICs) and I can't [re]name the newly added vNIC and then reboot. Rebooting 75+ VMs is non-practical. Adding a new vNIC is as simple as point-and-click and the guest sees the new vNIC. The VM doesn't need to reboot. How do I achieve this 'symlinking' effect minus the reboot? > Kay Regards Chetan Loke
From: Florian Weimer on 9 Jul 2010 03:30
* Chetan Loke: >> And on a system where you can use udev rules, the >> 70-persistent-net.rules file can be used to make them constant, by >> using the MAC address to force the names to be what you want. >> > > Ok, but can we achieve the renaming w/o a reboot? "udev-trigger" or "udevadm trigger" works for renaming network interfaces. The kernel has some restrictions on renaming interfaces which are in use, so this might not work in your case. -- Florian Weimer <fweimer(a)bfk.de> BFK edv-consulting GmbH http://www.bfk.de/ Kriegsstra�e 100 tel: +49-721-96201-1 D-76133 Karlsruhe fax: +49-721-96201-99 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ |