Passing the network device as argument to the scripts

Bug #1128403 reported by Removed by request
6
Affects Status Importance Assigned to Milestone
ifupdown (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

I'm using Ubuntu 13.04 dev with ifupdown 0.7.5ubuntu2. Because of this ticket (https://bugs.launchpad.net/ubuntu/+source/ifupdown/+bug/1126560) I had the idea that it would be useful if ifupdown passes the related network device as argument to the scripts in /etc/network/*. This would it make easier to debug problems and the scripts could maybe profit from the information for which network device they are running.

Revision history for this message
Stéphane Graber (stgraber) wrote :

Look for $INTERFACE in the environment, that's where we pass the network device name.

Changed in ifupdown (Ubuntu):
status: New → Invalid
Revision history for this message
Removed by request (removed3425744) wrote :

I have tested this and created the script /etc/network/if-pre-up.d/test with the content:

#!/bin/bash

echo "$INTERFACE" >> /tmp/test.log 2>&1

After a reboot /tmp/test.log has just contained 3 empty lines. The variable $INTERFACE was not know at this point for the script.

Changed in ifupdown (Ubuntu):
status: Invalid → New
Revision history for this message
Andrej Shadura (andrew.sh) wrote :

It should be IFACE if I remember correctly.

Revision history for this message
Stéphane Graber (stgraber) wrote :

Indeed. It's IFACE. Marking as invalid again.

Changed in ifupdown (Ubuntu):
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.