* /sys/class/net/eth?/carrier and uevents
@ 2006-05-29 21:07 João Luis Meloni Assirati
2006-05-29 21:29 ` Jesper Juhl
0 siblings, 1 reply; 5+ messages in thread
From: João Luis Meloni Assirati @ 2006-05-29 21:07 UTC (permalink / raw)
To: linux-kernel
Hello,
I would like to have my network interfaces configured when plugged on the
network cable. I know there are some daemons that do this for me (laptop-net,
ifplugd, whereami), but it would be nice if a simple udev rule take care of
this to me. However, as I can see with kernel 2.6.16 and udevmonitor (udev
version 0.091), nonetheless /sys/class/net/eth?/carrier changes when I plug
the network cable, no uevent is generated. Could this be changed so udev get
triggered when network cables get plugged? As I am no kernel developper, this
is only a suggestion, hoping that it would be a simple and pertinent job for
those ho know the subject.
Thanks in advance,
João.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /sys/class/net/eth?/carrier and uevents
2006-05-29 21:07 /sys/class/net/eth?/carrier and uevents João Luis Meloni Assirati
@ 2006-05-29 21:29 ` Jesper Juhl
2006-05-29 21:33 ` Arjan van de Ven
0 siblings, 1 reply; 5+ messages in thread
From: Jesper Juhl @ 2006-05-29 21:29 UTC (permalink / raw)
To: João Luis Meloni Assirati; +Cc: linux-kernel
On 29/05/06, João Luis Meloni Assirati <assirati@nonada.if.usp.br> wrote:
>
> Hello,
>
Hi,
> I would like to have my network interfaces configured when plugged on the
> network cable. I know there are some daemons that do this for me (laptop-net,
> ifplugd, whereami), but it would be nice if a simple udev rule take care of
> this to me. However, as I can see with kernel 2.6.16 and udevmonitor (udev
> version 0.091), nonetheless /sys/class/net/eth?/carrier changes when I plug
> the network cable, no uevent is generated. Could this be changed so udev get
> triggered when network cables get plugged? As I am no kernel developper, this
> is only a suggestion, hoping that it would be a simple and pertinent job for
> those ho know the subject.
>
I added the 'carrier' attribute initially but never considered udev at
the time. But I can certainly see how it could be useful.
I'll take a look at adding a hotplug event when I get some spare time
(probably some time next week) - or perhaps someone else will beat me
to it :)
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /sys/class/net/eth?/carrier and uevents
2006-05-29 21:29 ` Jesper Juhl
@ 2006-05-29 21:33 ` Arjan van de Ven
2006-05-29 21:51 ` Jesper Juhl
2006-05-29 23:02 ` João Luis Meloni Assirati
0 siblings, 2 replies; 5+ messages in thread
From: Arjan van de Ven @ 2006-05-29 21:33 UTC (permalink / raw)
To: Jesper Juhl; +Cc: João Luis Meloni Assirati, linux-kernel
>
> I added the 'carrier' attribute initially but never considered udev at
> the time. But I can certainly see how it could be useful.
> I'll take a look at adding a hotplug event when I get some spare time
> (probably some time next week) - or perhaps someone else will beat me
> to it :)
there is a netlink event already though... is this really worth the
duplication?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /sys/class/net/eth?/carrier and uevents
2006-05-29 21:33 ` Arjan van de Ven
@ 2006-05-29 21:51 ` Jesper Juhl
2006-05-29 23:02 ` João Luis Meloni Assirati
1 sibling, 0 replies; 5+ messages in thread
From: Jesper Juhl @ 2006-05-29 21:51 UTC (permalink / raw)
To: Arjan van de Ven; +Cc: João Luis Meloni Assirati, linux-kernel
On 29/05/06, Arjan van de Ven <arjan@infradead.org> wrote:
>
> >
> > I added the 'carrier' attribute initially but never considered udev at
> > the time. But I can certainly see how it could be useful.
> > I'll take a look at adding a hotplug event when I get some spare time
> > (probably some time next week) - or perhaps someone else will beat me
> > to it :)
>
> there is a netlink event already though... is this really worth the
> duplication?
>
Dunno, perhaps not. Have not looked at it yet. If it's simple to add
and there won't be any confusion for userspace as to what event to
react to, then it might be a nice little thing to have.
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /sys/class/net/eth?/carrier and uevents
2006-05-29 21:33 ` Arjan van de Ven
2006-05-29 21:51 ` Jesper Juhl
@ 2006-05-29 23:02 ` João Luis Meloni Assirati
1 sibling, 0 replies; 5+ messages in thread
From: João Luis Meloni Assirati @ 2006-05-29 23:02 UTC (permalink / raw)
To: Arjan van de Ven; +Cc: Jesper Juhl, linux-kernel
Em Seg 29 Mai 2006 18:33, Arjan van de Ven escreveu:
> > I added the 'carrier' attribute initially but never considered udev at
> > the time. But I can certainly see how it could be useful.
> > I'll take a look at adding a hotplug event when I get some spare time
> > (probably some time next week) - or perhaps someone else will beat me
> > to it :)
>
> there is a netlink event already though... is this really worth the
> duplication?
IMHO the ability to substitute a daemon with a simple udev rule, together with
the benefit of notification by d-bus to the user interface (say KDE) makes it
worth.
Regards,
João.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2006-05-29 23:02 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-29 21:07 /sys/class/net/eth?/carrier and uevents João Luis Meloni Assirati
2006-05-29 21:29 ` Jesper Juhl
2006-05-29 21:33 ` Arjan van de Ven
2006-05-29 21:51 ` Jesper Juhl
2006-05-29 23:02 ` João Luis Meloni Assirati
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®