Renaming ethernet interfaces Debian 5
From Kenneth Noyens
Make a file /etc/mactab with the following contents:
<source lang="ini"> wan0 00:01:03:E5:6D:FC lan0 00:19:db:f6:3e:3d </source>
This will rename the ethernet adapter with mac 00:01:03:E5:6D:FC to wan0 and ethernet adapter with mac 00:19:db:f6:3e:3d to lan0.
Now enter the command "nameif" to activate the new names.
Normally you have to enter this command every time after rebooting your server.
To do this automatically you can make a file (ex. nameif) in /etc/network/if-pre-up.d/:
<source lang="bash">
- !/bin/sh
PATH=/sbin
nameif </source>