
Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [tlug] Perform an action when network cable unplugged (and back in again)
- Date: Wed, 13 Jun 2012 12:00:15 +0200
- From: Attila Kinali <attila@example.com>
- Subject: Re: [tlug] Perform an action when network cable unplugged (and back in again)
- References: <4FD7DDC0.9090701@dcook.org> <CAAcd6GqmkcHhkLJv=UFaMoHBBJVx5ekpFj0Hrg+C7vsq=jz1pQ@mail.gmail.com>
- Organization: NERV
On Wed, 13 Jun 2012 11:07:16 +0900
Jawaad Mahmood <jawaad.mahmood@example.com> wrote:
> > Does such a thing even exist?
> >
> >
> It does exist.
>
> http://stackoverflow.com/questions/10340145/get-event-for-nic-ethernet-card-link-status-on-linux
>
> I don't have time to program it for you right now, but it seems one can
> handle netlink socket connections through python:
>
> http://stackoverflow.com/questions/4676866/how-can-i-use-a-netlink-socket-to-data-from-kernel-space-in-python
>
> This looks promising at least..
Hmm.. i would have first looked whether udev gets an event. If it does,
then you can just use standard shell scripts instead of hooking into netlink.
Attila Kinali
--
Why does it take years to find the answers to
the questions one should have asked long ago?
Home |
Main Index |
Thread Index