TurnKey Linux Virtual Appliance Library

Network interface unavailable in copied Turnkey

 Hello all

I've installed a Turnkey LAMP Appliance into a VMWare Fusion virtual machine (VM) and it works great.

However, when I copy it to another computer (with the same version of VMWare Fusion installed)  in the same local network and launch the VM, the Turnkey appliance is not able to obtain an IP address via DHCP.

I tried to set the static IP address manually, but it also would not save.

What do I need to do to resolve this? 

Thanks in advance

more information

Just to add a bit more detail, it seems that that no network interface can be found.

When I key in

# ifconfig eth0 

I get the output

# eth0: error fetching interface information: Device not found

How can I "force" the appliance to re-detect and reconfigure the network interface? Thank you

The solution

 After googling around in various forums, I've pieced together the solution. 

Hope this is useful for whomever is configuring and re-deploying Turnkey Linux in Virtual Machines.

--

 

Important: You must log in to the console / terminal as root or as a sudo user.

If you are in Turnkey Linux Configuration Console, you need to Quit it first.

 

1. Open the following file in nano

 

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

 

2. You will see lines that look like the following. There may be more than 1 set. Delete them all to remove existing network interface mappings.

 

# PCI device xxxxxxxxxxx (modulename)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:xx:xx:xx:xx:xx", NAME="eth0"

 

3. Restart udev to make the changes come into effect

 

# /etc/init.d/udev restart 

 

4. Open the previous file again

 

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

 

 

5. You should see a new set of lines for network interface mappings. Do these 2 things

a) take note of the module name at the end of the line that starts with PCI device

 

e.g. PCI device 0x1022:0x2000 (pcnet32)

 

b)  scroll to the end of the line that starts with SUBSYSTEM

 

Make sure it reads NAME="eth0" (and NOT eth3 or any other number)

 

 

6. Now we load and reload the module. In this example, pcnet32 is the module name (use the name of the module you noted in Step 5a)

 

# modprobe -r pcnet32 
# modprobe pcnet32


7. Ok reboot and you're good to go!

 

# reboot

 

Alon Swartz's picture

Thanks!

Thanks for diagnosing the issue, I'm sure it will help others with similar problems.

Alon Swartz's picture

Doc: Virtualization networking issues

Again, thanks for the great write up.
We have fixed this issue in all VM builds, and have documented the issue in Virtualization networking issues (udev persistent net generation), linking to this post as well.

Fix does not work ...

I'm playing with an actual Turnkey MediaWiki with the same effect. But when I open

70-persistent-net.rules

I find it empty (0 Byte). Also after restarting udev.

Any idea what's wrong here?

 

Thanks in advance.

I tried also the advice

I tried also the advice from Virtualization networking issues (udev persistent net generation)

rm -f /etc/udev/rules.d/70-persistent-net.rules
reboot

but this does not change anything. The data is locked up in the VM ... how would I get the already entered data out and moved to a new install? 
I mounted an external HDD but don't know which path to enter to backup the MSSQL database as described in Upgrading MediaWiki

 

Network interface unavailable Turnkey Lamp

Wow! You really helped me with this problem. Thanks!

Alon Swartz's picture

Your post fell through the gaps...

Your post fell through the gaps, sorry. I thought I had updated all relevant threads.

Anyway, it took a while to replicate the described issue, figure out what was causing it and how to solve it. The fix is described here, and you should be able fix networking in your VM in a snap.

We have patched all VM builds and re-uploaded.

Thanks for bearing with our first batch of VM builds, and helping to identify issues.

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)