3

I have the following procedure for replicating a Fedora workstation setup.

  1. Boot from a Live CD, make tgz's of the filesystems.
  2. Go to new machine, make filesystems, dump the tgz's in the proper places.
  3. Adjust UUID's in /etc/fstab and /boot/grub/menu.lst
  4. Run grub-install
  5. Reboot!

The nice thing is that DHCP assigns the new machine an unique name, and users have /home mounted on the server. Graphics configuration aren't a worry either, since recent versions of Xorg are wicked smart in auto-detecting graphic adapters.

So everything works like a snap... with the exception of one small quirk:

In the first boot of the new machine, network startup fails. It turns out the machine thinks there's no such thing as an eth0, but there is an eth1 and it is the machine's onboard ethernet. So I have to go to /etc/sysconfig/network-scripts, rename ifcfg-eth0 to ifcfg-eth1, and edit the DEVICE= line in it. Then I reboot and everything works.

I believe somewhere, in some file, there is information associating eth0 with the MAC of the "Master Mold" machine's eth0. But where?

P.S.: I don't use NetworkManager.

JCCyC
  • 686

1 Answers1

4

On my machine it is

/etc/udev/rules.d/70-persistent-net.rules

This is a Debian squeeze machine, but it is probably similar for other Linux distributions. Mine looks like

# This file was automatically generated by the /lib/udev/write_net_rules
# program, probably run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single line.
# MAC addresses must be written in lowercase.

# Firewire device 00e081000026d042 (ohci1394)
SUBSYSTEM=="net", DRIVERS=="?*", ATTR{address}=="00:e0:81:00:00:26:d0:42", NAME="eth0"

# PCI device 0x10de:0x0057 (forcedeth)
SUBSYSTEM=="net", DRIVERS=="?*", ATTR{address}=="00:e0:81:70:18:22", NAME="eth1"

Tip: doing

/etc# grep -r eth0 * | less

will give you the answer in a couple of minutes, probably. That is what I did.

Faheem Mitha
  • 35,108