Forums

×

Warning

JUser: :_load: Unable to load user with ID: 26840
Resolved
0 votes
hello!

i use clearos 5.1 in a virtual machine on win2008r2 - hyper-v. I installed in clearos 5.1 the "Linux Integration Components for Microssoft Hyper-V" and the network interface changed from "eth0" to "seth0". Afte a reboot i can't change the static ip in the gui.

It shows

"You must define at least one network interface with an external role. This is a requirement for both gateway mode and standalone mode."

Also I write with nano the static ip and the gateway to

/etc/sysconfig/network-scipts/ifcfg-seth0 (ip, HW-adress....) and
/etc/sysconfig/network (gw is seth0)

and clearos 5.1 works.

There is a possibility that I can do the settings on the clearos-gui?

regards from austria

rosi



ps.: excuse my bad english.
Thursday, February 25 2010, 12:10 PM
Share this post:
Responses (9)
  • Accepted Answer

    Thursday, February 25 2010, 12:36 PM - #Permalink
    Resolved
    0 votes
    Hi!
    You must have at least one interface defined as the 'external' interface...this will show up in EXTIF=seth0 in /etc/firewall otherwise most of the system services will not run. This is true for both standalone mode and gateway mode
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, February 25 2010, 12:51 PM - #Permalink
    Resolved
    0 votes
    thanks!

    OK. the warning is gone, but i can't se a network interface (eth0 or seth0) on the gui (network -> ip-settings) the network card section (interface) is not displayed.

    regards
    rosi
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, February 25 2010, 10:00 PM - #Permalink
    Resolved
    0 votes
    Webconfig only recognises certain names such as ethX and wlanX. I know for instance that rausbX is not seen. Maybe the same with sethX...

    Back in the old CC Forum there are instructions on using ifrename to rename an interface...
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, April 28 2010, 03:41 AM - #Permalink
    Resolved
    0 votes
    I found it was easiest just edit the interfaces directly in /etc/sysconfig/network-scripts to ethXX
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, July 27 2010, 09:23 AM - #Permalink
    Resolved
    0 votes
    Tony,

    Your answer helped me get pointed in the right direction, but there are a couple things that still aren't working quite right. Once I've worked through the remaining issues I'll summarize what I learned in order to help others.

    I'm running Microsoft Server 2008 R2 with the Hyper-V role.

    Intel Core 2 Quad Q6600 (4 CPUs)
    Windows Server 2008 R2 Enterprise
    Service Pack 1, v1.78

    ClearOS 5.2
    kernel-2.6.18-194.8.1.v5

    I installed the Linux Integration Services for Microsoft Hyper-V - Version 2.1 Release Candidate.

    The current version (2) installed, but after changing the Hyper-V configuration from the Legacy NICs to the Virtual NICs the ClearOS VM boot hung. In searching the web I found someone with a similar issue.

    http://www.yusufozturk.info/virtual-machine-manager/centos-hangs-at-ibm-trackpoint-firmware-on-hyper-v-r2.html

    He changed the VM configuration to use a single CPU. (I was configured with 4 virtual CPUs.) And that did allow me to boot.

    From the Hyper-V menu I was able to click on "Shutdown" and the ClearOS VM did shutdown. So the Microsoft drivers seemed to install correctly. But because I wanted 4 CPUs I tried the Version 2.1 Release Candidate instead.

    Both driver versions seemed to have other issues. I'll need to run through the process again from the beginning to recall exactly what was necessary to change, but I suspect that all the problems boil down to what you're describing here, i.e., sethX is not recognized by the ClearOS webconfig tools.

    I'm not sure exactly how this was being done, but something created

    /etc/sysconfig/network-scripts/ifcfg-sethX

    I had renamed these files to ifcfg-ethX as Trevor mentioned. I also had to modify various statements in the files (as I had been using Static IP addresses for both interfaces).

    I found a webpage that I believe is talking about the ifrename process you mentioned.

    http://ccforums.clearfoundation.com/showthreaded.php?Cat=0&Number=81783&page=9&vc=1

    It took me a while to understand exactly what needed to be done, but there seemed to be two key elements.

    I created /etc/iftab and coded my Virtual NIC hardware (MAC) addresses.

    # LAN Interface
    seth0 mac 00:15:5D:01:76:A2

    # WAN Interface
    seth1 mac 00:15:5D:01:76:A3

    I also updated /etc/init.d/network and after the following statements:

    # Even if VLAN is configured, without the utility we can't do much
    [ ! -x /sbin/vconfig ] && VLAN=

    I added:

    if [ -x /sbin/ifrename ] && [ -r /etc/iftab ]; then
    echo -n "Remapping network interfaces name: "
    ifrename -p
    echo "done."
    fi

    The rename does seem to work as expected (after rebooting) and certain things seem to function now which weren't before, but there are still several problems.

    a) On the webconfig "IP Settings" page the columns where the "IP Address" should go both have a blue spinning icon. I assume this is because something about this webpage is still seeing sethX instead of ethX? Any other ideas on how to fix that? (This also seems to be a factor in my missing default route? See below.)

    b) After installing the Microsoft driver when the system booted it came up in Standalone Mode and the Gateway Mode was not an option in the drop down box. In searching I found a mention that until an External interface was defined this would happen. I changed several files and that got me the Gateway Mode back, but ever since them something seems to have affected the Firewall. Until I issue

    service firewall stop

    from outside I can't PING either ClearOS IP address. From inside the ClearOS VM I believe I was able to PING myself, but I was unable to PING anything outside the VM. Got this type of error message:

    ping: sendmsg: Operation not permitted

    And NSLOOKUP failed. I've tried changing /etc/firewall to use both ethX or sethX, but neither seems to make any difference. So I've had to leave the firewall down to work around these issues.

    But something in the system seems to restart the firewall every few minutes ... so I'll unexpectedly lose my PuTTY connection (until I realized that was happening).

    c) Even with the firewall stopped - yum update - gets the following errors.

    [root@clearos52dev init.d]# yum update
    Loading "kmod" plugin
    Loading "protect-packages" plugin
    http://download.clearfoundation.com/clearos/enterprise/5.2/kernels/repodata/repomd.xml: [Errno 4] IOError: <urlopen error (101, 'Network is unreachable')>
    Trying other mirror.
    http://download2.clearfoundation.com/clearos/enterprise/5.2/kernels/repodata/repomd.xml: [Errno 4] IOError: <urlopen error (101, 'Network is unreachable')>
    Trying other mirror.
    http://download3.clearfoundation.com/clearos/enterprise/5.2/kernels/repodata/repomd.xml: [Errno 4] IOError: <urlopen error (101, 'Network is unreachable')>
    Trying other mirror.
    http://download1.clearfoundation.com/clearos/enterprise/5.2/kernels/repodata/repomd.xml: [Errno 4] IOError: <urlopen error (101, 'Network is unreachable')>
    Trying other mirror.
    http://download4.clearfoundation.com/clearos/enterprise/5.2/kernels/repodata/repomd.xml: [Errno 4] IOError: <urlopen error (101, 'Network is unreachable')>
    Trying other mirror.
    Error: Cannot retrieve repository metadata (repomd.xml) for repository: base-kernels. Please verify its path and try again

    NSLOOKUP works so the firewall is no longer the source of my problems.

    [root@clearos52dev init.d]# nslookup download4.clearfoundation.com
    Server: 192.168.2.2
    Address: 192.168.2.2#53

    Non-authoritative answer:
    download4.clearfoundation.com canonical name = mirror4-dallas.clearsdn.com.
    Name: mirror4-dallas.clearsdn.com
    Address: 67.18.166.6

    As I was composing this update I realized the issue is that I'm missing a default route. Which I believe normally would be created from the "IP Settings" webpage that I'm having trouble with?

    I'm not sure exactly where this default route is coming from, but even if the webconfig tool has problems there may be a way to manually code something to fix this? But at the moment I'm not sure exactly how that is done.

    Here's what I'm seeing on this ClearOS VM.

    [root@clearos52dev init.d]# tracert download4.clearfoundation.com
    traceroute to download4.clearfoundation.com (67.18.166.6), 30 hops max, 40 byte packets
    sendto: Network is unreachable

    [root@clearos52dev init.d]# netstat -r
    Kernel IP routing table
    Destination Gateway Genmask Flags MSS Window irtt Iface
    192.168.7.0 * 255.255.255.0 U 0 0 0 seth1
    192.168.2.0 * 255.255.255.0 U 0 0 0 seth0

    I have another ClearOS 5.2 VM that did not have the Microsoft Linux Integration driver installed. It works properly and the only difference I see is the default route.

    [root@clearos52prod ~]# tracert download4.clearfoundation.com
    traceroute to download4.clearfoundation.com (67.18.166.6), 30 hops max, 40 byte packets
    1 192.168.7.1 (192.168.7.1) 0.000 ms 0.000 ms 12.998 ms

    [root@clearos52prod ~]# netstat -r
    Kernel IP routing table
    Destination Gateway Genmask Flags MSS Window irtt Iface
    192.168.7.0 * 255.255.255.0 U 0 0 0 eth1
    192.168.2.0 * 255.255.255.0 U 0 0 0 eth0
    default 192.168.7.1 0.0.0.0 UG 0 0 0 eth1

    d) This isn't a ClearOS issue, but /etc/iftab relies upon coding the hardware (MAC) addresses for the Virtual NIC interfaces. I suspect that may not stay constant within Hyper-V? I believe I saw on some Hyper-V menu there is a way in creating the VM NICs to specify the MAC address and it looks like that will need to be hard coded for this process to consistently work.

    e) As I was composing this update some ClearOS system process kicked off and recreated these files - /etc/sysconfig/network-scripts/ifcfg-sethX

    I had to remove them and recreate my network configuration and reboot the system to get back to the problems described above.

    After making several more changes I believe what caused this to happen is that I clicked on the Edit button from the IP Settings page and then on the Confirm button. When that is done it is wiping out my manual configuration. (I suspect this Confirm button is also having problems with the sethX configuration?)

    Thanks for any help you can provide on these remaining issues.
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, July 28 2010, 07:25 AM - #Permalink
    Resolved
    0 votes
    Sorry, I know nothing about Microsoft Hyper-V so cannot help you with this aspect of your problems...

    Once I have the ifcfg-ethX files configured how I want them, I set the immuable bit so Webconfig, OS updates etc cannot change them...

    There is an option you might be able to explore... (not tested)

    If you look at /var/webconfig/api/Iface.class.php (line 1427+ on mine), you will see this code. I think it might be the section that blocks seth but allows eth. You could try editing it and add and extra line for seth. Note that a ClearOS upgrade could remove your changes... save a copy of the original so you can always retreat!


    function IsConfigurable()
    {
    if (COMMON_DEBUG_MODE)
    $this->Log(COMMON_DEBUG, 'called', __METHOD__, __LINE__);

    // PPPoE interfaces are configurable, bug only if they already configured.

    if (
    preg_match('/^eth/', $this->iface) ||
    preg_match('/^wlan/', $this->iface) ||
    preg_match('/^ath/', $this->iface) ||
    preg_match('/^br/', $this->iface) ||
    preg_match('/^bond/', $this->iface) ||
    (preg_match('/^ppp/', $this->iface) && $this->IsConfigured())
    ) {
    return true;
    } else {
    return false;
    }
    }


    "ping: sendmsg: Operation not permitted" comes form the firewall blocking...
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, July 28 2010, 08:03 AM - #Permalink
    Resolved
    0 votes
    Tony,

    I believe I've found a solution to the problems I was having last night. And so far this doesn't seem to have broken anything else. (I'll review your update later as I may still need to incorporate those suggestions.)

    I'm not very familiar with the Linux boot process, but in poking around the Internet this seemed to be the right way to resolve my issues with Hyper-V and ClearOS.

    I'll need to start from a clean install again and run through all the steps to ensure I've got everything down correctly, but in general while troubleshooting I had various files with "sethX" in them. I changed all those back to "ethX." Those I recall restoring were:

    /etc/sysconfig/network-scripts/ifcfg-ethX
    /etc/firewall

    Something in the boot process was creating /etc/sysconfig/network-scripts/ifcfg-sethX files. I'm not quite sure why this was being done. But I had to delete those files.

    After restoring all the sethX to ethX the key seems to have been these three steps.

    I created a file - /etc/init.d/ifrename

    ifrename -i seth0 -n eth0
    ifrename -i seth1 -n eth1

    chmod 755 ifrename Then made it executable.

    /etc/rc.d/rc5.d/ I believe contains a number of scripts and/or links. "Snn" seems to be scripts that are executed during initialization and the "nn" gives the order? There were existing "scripts" named S09vmbus and S10network. So making this link (below) looked to me to be the way to execute the ifrename script I had just created? I believe this is happening early enough in the boot process so that all later processes see ethX instead of sethX for the NICs.

    ln -s /etc/rc.d/init.d/ifrename /etc/rc.d/rc5.d/S09ifrename

    Last night I had also created a file - /etc/iftab

    # LAN Interface
    eth0 mac 00:15:5D:01:76:A2

    # WAN Interface
    eth1 mac 00:15:5D:01:76:A3

    Last night I had "sethX" here, but this was one of the files I changed back to "ethX." My recollection is that /etc/iftab was needed for the ifrename process. So far Windows has not changed my virtual hardware (MAC) addresses, but I still need to change the Hyper-V NIC configuration to hard code these MAC addresses.

    After making all these corrections and rebooting from outside the ClearOS VM I was able to PING both IP addresses. From the Webadmin Network IP Settings webpage I know see both interfaces correctly. I no longer have the blue spinning icon in the IP Address field. When clicking on edit the external interface now shows a default gateway.

    I compared /etc/firewall from my ClearOS VM without the Microsoft driver to the ClearOS VM with the Microsoft driver and I didn't see any differences. But for some reason the firewall wasn't working properly last night. I suspect it was having issues due to the sethX/ethX issue?

    When I try a clean install again I'll have to double check if the change to /etc/init.d/network is still necessary. That was supposed to help with the sethX/ethX issues and it did help some, but didn't eliminate all the problems. With the 3 items mentioned above it may no longer be necessary to update /etc/init.d/network?

    I've only been working with this ClearOS VM (with the Microsoft v2.1 Release Candidate driver) for a short time since finding this solution, but it seems that everything is working.

    I do notice one error message during the boot process. Probably something I forgot to restore to the original configuration? But it doesn't seem to be hurting anything.

    Starting iSCSI daemon
    Checking for new synthetic nics... (I believe this is new due to the Microsoft Hyper-V driver?)
    Remapping network interfaces name: Warning: interface name is 'eth0' at line 2,
    can't be mapped reliably.

    At this point the Microsoft driver seems to be working correctly. I am able to click the Hyper-V shutdown button and the ClearOS VM shuts down normally. I had trouble with the version 2 driver. I was configured for 4 virtual CPUs and ClearOS would hang during the boot. But with the version 2.1 Release Candidate driver all the Microsoft services seem to be provided to ClearOS (Linux). So I am happy.

    Thanks for your help.
    The reply is currently minimized Show
  • Accepted Answer

    Friday, July 30 2010, 07:14 AM - #Permalink
    Resolved
    0 votes
    rosi,

    By now I'm sure your original problem has been fixed, but I thought I would document what I did to get this working for the benefit of anyone else who runs into problems getting ClearOS to work on Hyper-V.

    I was using ClearOS 5.2, but I believe these steps will probably also work for ClearOS 5.1?

    A couple things to keep in mind about my notes.

    a) I had ClearOS setup as a gateway with two NICs. Due to other VMs on Hyper-V I am using eth0 as the LAN and eth1 as the WAN. ClearOS seems to default to the reverse and if you followed that convention you'll need to reverse some of the things I'll document below.

    b) For my notes below I did this from a fresh install of ClearOS 5.2. If you've already been using ClearOS for a while you may need to do things a little differently than what I'm describing here. In general you want all the configurations I mention to have "ethX" instead of "sethX" with the exception of /etc/iftab

    c) If you see "sethX" during the boot process then you're missing one of these configuration steps.

    d) I used the Microsoft Version 2.1 Release Candidate driver as I have a 4 CPU system. In using the current Microsoft Version 2.0 driver my system hung during the boot process. I found that by changing the Hyper-V configuration to 1 virtual CPU the boot completed. If you would rather only use non-Beta code I believe that in using a single CPU the other steps I mention here should all work for you.

    e) There are several places in which the Ethernet Hardware (MAC) address is specified. I don't know what restrictions there are (if any) for Ethernet specs, Hyper-V, and/or Linux on valid MAC addresses. Keep in mind that whatever value you choose it needs to be unique in your network. Other than that I believe that any value from 0x000000000000 to 0xFFFFFFFFFFFF should work? You'll also need to ensure that the same value is used in the two or three places it must be specified. (I coded it in the ifcfg-XXX files, but it may not be absolutely necessary to include it there?)

    f) In researching my problems I was reminded that Linux doesn't necessarily activate hardware devices in the same order each time. Thus it might be possible for eth0 and eth1 to be physically reversed from one boot to another. I don't know if that could be an issue with ClearOS or not? But I suspect the fact that the MAC address is specified should ensure that eth0 and eth1 are always the same physical interface from one boot to another?

    g) Before following these steps you'll want to install ClearOS and get it working on Hyper-V. Verify that all your IP addresses are working, i.e., PING them from another host. And verify that all other software is functioning correctly. I believe it is better to be current on maintenance. So I'd also recommend that you update all software, both to ClearOS and Hyper-V, before trying to install this Microsoft driver.

    h) Of course be sure you backup any critical data before attempting this. Just in case something goes wrong. In trying to find the best way to install and configure everything I had one erroneous variation in which neither NIC came up and I had trouble stopping the ClearOS boot process to try and get into a terminal session. I ended up re-installing ClearOS and starting over as I couldn't connect through the web interface on the Hyper-V console for this ClearOS VM.

    i) One IMPORTANT POINT to keep in mind is that because you're making changes to the Ethernet configuration you probably won't be able to connect to the VM from outside with something like PuTTY. You'll need to use a remote connection to the Hyper-V console and use that terminal to make these changes.

    j) I tried several variations to the process, but I couldn't find any way to install the driver and make all the configuration changes and just re-boot once. Because you have to make hardware changes to the Hyper-V NICs it appears that you need to boot once after the driver is installed and with the new (synthetic) NICs. Then make the configuration changes and boot a second time at which point everything should be working normally.

    k) I'm not a Linux guru, but it appears to me that whatever ifcfg-XXXX files are found by Linux it attempts to start these interfaces. There also seem to be several variations on how these configuration files can be coded. I saw it coded both with and without double quotes around the various parameters. Various ClearOS scripts seemed to make modifications to these files. I tried a number of options before finding this method that worked, but in doing so I may have added some options to this file that ClearOS would not have on its own. I don't know if that could cause any problems for ClearOS or not? But if you have trouble afterwards you might want to see if you are missing any parameters the original ifcfg-XXX files originally had in them or if you've added any parameters that they didn't have. (Or perhaps used a different syntax than what was there before.)

    Since my steps below are from a clean install I didn't have an existing ifcfg-XXXX file, but you might want to make a backup copy of the files you have first. Something in the process of trying to configure the system would wipe out those files and a backup will help to ensure you get back to your prior (working) network configuration. These are located in the directory /etc/sysconfig/network-scripts

    ifcfg-eth0 -

    DEVICE=eth0
    TYPE=”Ethernet”
    ONBOOT=”yes”
    USERCTL=”no”
    HWADDR=”00:15:5d:01:76:a2”
    BOOTPROTO=”static”
    IPADDR=”192.168.2.5”
    NETMASK=”255.255.255.0”
    GATEWAY=”192.168.7.1”

    ifcfg-eth1 -

    DEVICE=eth1
    TYPE=”Ethernet”
    ONBOOT=”yes”
    USERCTL=”no”
    HWADDR=”00:15:5d:01:76:a3”
    BOOTPROTO=”static”
    IPADDR=”192.168.7.5”
    NETMASK=”255.255.255.0”
    GATEWAY=”192.168.7.1”

    Here are the steps I took to get this Microsoft driver working. With some slight variations these first steps I believe are common to any derivative of Red Hat? Prior to executing these steps you'll want to modify Hyper-V to have the Microsoft driver ISO file in the virtual DVD drive.

    yum groupinstall "Development Tools"
    yum update (Get current on maintenance)
    mkdir -p /mnt/cdrom
    mount /dev/cdrom /mnt/cdrom
    cp -rp /mnt/cdrom /opt/linux_ic
    umount /mnt/cdrom
    cd /opt/linux_ic
    ./setup.pl drivers

    If the Microsoft driver setup runs correctly you should get something like this for your result.

    # ./setup.pl drivers
    Checking if required components are installed...done.
    Installing Linux integration components (vmbus, enlightened ide, enlightened scsi and network drivers) for Hyper-V...
    Building all modules...
    Building modules, stage 2.
    done.
    Your system supports the timesource driver, including driver in the build
    Installing vmbus driver...done.
    Installing netvsc driver...done.
    Installing storvsc driver...done.
    Installing blkvsc driver...done.
    Installing hv_timesource driver...done.
    Updating module dependencies. This may take a while...done.
    Installing various udev rules and scripts...done.
    Updating initrd image...
    Backing up /boot/initrd-2.6.18-194.8.1.v5.img to /boot/initrd-2.6.18-194.8.1.v5.img.backup0
    Done. Updated /boot/initrd-2.6.18-194.8.1.v5.img
    Updating grub conf file...
    Done.
    Installing vmbus startup script...
    *** The drivers have been installed successfully.*** [ OK ]

    To continue ...

    # lsmod | grep vsc (This verifies that the Microsoft drivers loaded. My result is shown below.)

    storvsc 33700 0
    vmbus 52168 1 storvsc
    scsi_mod 141908 8 storvsc,ib_iser,iscsi_tcp,libiscsi2,scsi_transport_iscsi2,scsi_dh,libata,sd_mod

    shutdown –h now

    At this point you need to modify the Hyper-V configuration. Remove the Microsoft driver from the virtual DVD drive. Delete your existing Legacy Network cards and add back in a "Network Adapter," i.e., the synthetic NIC that the Microsoft driver will communicate with. Specify a static MAC address. Once that is done boot the ClearOS VM.

    If you're doing this from a clean install of ClearOS no ethX or sethX message should show up during this boot. If you get any sethX messages ClearOS is likely to say FAILED. But once you've made the following configuration changes everything and booted the VM a second time then everything should be working.

    cd /etc/sysconfig/network-scripts

    You'll need the ifcfg-ethX files. Depending upon the exact steps you follow you may have both ifcfg-ethX and ifcfg-sethX files. If so the sethX files can be deleted. Use nano to edit the ifcfg-ethX (an example configuration is shown above) and ensure that this configuration matches your network, i.e., correct IP address, router (gateway) address, hardware (MAC) addresses, etc. If you only have ifcfg-sethX files rename them to ifcfg-ethX and then modify them as appropriate (see example above).

    cd /etc/init.d
    nano ifrename

    This newly created file should contain the following:

    ifrename -i seth0 -n eth0
    ifrename -i seth1 -n eth1

    chmod 755 ifrename (make the ifrename file executable)

    I don't know a lot about the Linux boot process, but basically this next command creates a link that is picked up at the appropriate time in the boot process to rename the sethX interfaces (which are created due to installing the Microsoft driver) to ethX which is something that the ClearOS system will recognize. Without doing this a number of the ClearOS webpages were not functioning correctly (see my prior post).

    ln -s /etc/rc.d/init.d/ifrename /etc/rc.d/rc5.d/S09ifrename

    cd /etc
    nano iftab

    This newly created file should contain the following. This is the only place in your configuration where you should have sethX instead of the more usual ethX. This is one of three places in which the Ethernet hardware (MAC) address is specified. (The other two are in the Hyper-V virtual NIC configuration and in the ifcfg-ethX files.)

    # LAN Interface
    seth0 mac 00:15:5D:01:76:A2

    # WAN Interface
    seth1 mac 00:15:5D:01:76:A3

    cd /etc/init.d
    nano network

    CNTL-W to find VLAN (This is a nano search command to jump to the right place in this file.)

    You should see the following in this "network" file -

    # Even if VLAN is configured, without the utility we can't do much
    [ ! -x /sbin/vconfig ] && VLAN=

    Just below this point, i.e., after the equals sign, you'll want to add the following code.

    if [ -x /sbin/ifrename ] && [ -r /etc/iftab ]; then
    echo -n "Remapping network interfaces name: "
    ifrename -p
    echo "done."
    fi

    If you've done a fresh install of ClearOS at this point you should be able to reboot and everything should be working. If you've been running ClearOS for a while there is one other thing you should double check to ensure the firewall is configured correctly. If the firewall is not configured correctly you'll not be able to PING from an outside host and from inside the VM you'll get an error message (see my prior post). (Since it doesn't take long to check the firewall configuration you may want to do this even if you've performed a clean install.)

    cd /etc
    nano firewall

    Verify the following is coded. In some cases something in a ClearOS script seemed to be clearing these values to "". On one occasion something I did caused a ClearOS script to fill in sethX instead of ethX.

    EXTIT=”eth1”
    LANIF=”eth0”

    This next command (shutdown) will reboot your ClearOS VM. During the boot process you should see some messages (such as VMBUS) which are related to the Microsoft drivers. You should also see eth0 (and if you've got a gateway eth1) as OK during the boot process. If you see sethX one of the above configuration steps was somehow missed. After you correct it and reboot everything should be working.

    Once the Microsoft driver is installed one benefit you'll see is that from the Hyper-V manager you can click the "Shutdown" button and instead of getting an error dialogue box back after a few minutes you'll see that ClearOS VM is shutting down gracefully.

    shutdown –r now


    In a prior post I mentioned getting the error message, "Remapping network interfaces name: Warning: interface name is 'eth0' at line 2, can't be mapped reliably" This was occurring because I incorrectly coded ethX in the iftab file rather than sethX.

    Enjoy.
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, August 03 2010, 07:20 AM - #Permalink
    Resolved
    0 votes
    Linux Integration Services v2.1 for Windows Server 2008 Hyper-V R2 has been released by Microsoft.

    http://www.microsoft.com/downloads/details.aspx?displaylang=enFamilyID=eee39325-898b-4522-9b4c-f4b5b9b64551

    The installation steps differ slightly from the Release Candidate v2.1 driver (see prior post).

    The v2.1 RTM steps are:

    yum groupinstall "Development Tools"
    yum update
    mkdir -p /mnt/cdrom
    mount /dev/cdrom /mnt/cdrom
    cp -rp /mnt/cdrom /opt/linux_ic_v21_rtm
    umount /mnt/cdrom
    cd /opt/linux_ic_v21_rtm
    make
    make install

    If your installation worked correctly you will see messages that look like this:

    [root@clearos52 linux_ic_v21_rtm]# make
    Building all modules...
    make -C /lib/modules/2.6.18-194.8.1.v5/build SUBDIRS=/opt/linux_ic_v21_rtm/src modules
    make[1]: Entering directory `/usr/src/kernels/2.6.18-194.8.1.v5-i686'
    CC [M] /opt/linux_ic_v21_rtm/src/BlkVsc.o
    CC [M] /opt/linux_ic_v21_rtm/src/osd.o
    CC [M] /opt/linux_ic_v21_rtm/src/blkvsc_drv.o
    CC [M] /opt/linux_ic_v21_rtm/src/RndisFilter.o
    CC [M] /opt/linux_ic_v21_rtm/src/NetVsc.o
    CC [M] /opt/linux_ic_v21_rtm/src/netvsc_drv.o
    CC [M] /opt/linux_ic_v21_rtm/src/StorVsc.o
    CC [M] /opt/linux_ic_v21_rtm/src/storvsc_drv.o
    CC [M] /opt/linux_ic_v21_rtm/src/Sources.o
    CC [M] /opt/linux_ic_v21_rtm/src/vmbus_drv.o
    /opt/linux_ic_v21_rtm/src/vmbus_drv.c: In function âshutdown_linux_systemâ:
    /opt/linux_ic_v21_rtm/src/vmbus_drv.c:335: warning: ISO C90 forbids mixed declarations and code
    LD [M] /opt/linux_ic_v21_rtm/src/vmbus.o
    LD [M] /opt/linux_ic_v21_rtm/src/netvsc.o
    LD [M] /opt/linux_ic_v21_rtm/src/storvsc.o
    LD [M] /opt/linux_ic_v21_rtm/src/blkvsc.o
    CC [M] /opt/linux_ic_v21_rtm/src/hv_timesource.o
    Building modules, stage 2.
    MODPOST
    CC /opt/linux_ic_v21_rtm/src/blkvsc.mod.o
    LD [M] /opt/linux_ic_v21_rtm/src/blkvsc.ko
    CC /opt/linux_ic_v21_rtm/src/hv_timesource.mod.o
    LD [M] /opt/linux_ic_v21_rtm/src/hv_timesource.ko
    CC /opt/linux_ic_v21_rtm/src/netvsc.mod.o
    LD [M] /opt/linux_ic_v21_rtm/src/netvsc.ko
    CC /opt/linux_ic_v21_rtm/src/storvsc.mod.o
    LD [M] /opt/linux_ic_v21_rtm/src/storvsc.ko
    CC /opt/linux_ic_v21_rtm/src/vmbus.mod.o
    LD [M] /opt/linux_ic_v21_rtm/src/vmbus.ko
    make[1]: Leaving directory `/usr/src/kernels/2.6.18-194.8.1.v5-i686'
    done.
    Your system supports the timesource driver, including driver in the build


    [root@clearos52 linux_ic_v21_rtm]# make install
    Building all modules...
    make -C /lib/modules/2.6.18-194.8.1.v5/build SUBDIRS=/opt/linux_ic_v21_rtm/src modules
    make[1]: Entering directory `/usr/src/kernels/2.6.18-194.8.1.v5-i686'
    Building modules, stage 2.
    MODPOST
    make[1]: Leaving directory `/usr/src/kernels/2.6.18-194.8.1.v5-i686'
    done.
    Your system supports the timesource driver, including driver in the build
    install -d -m0755 /lib/modules/2.6.18-194.8.1.v5/kernel/drivers/vmbus
    install -m0755 /opt/linux_ic_v21_rtm/src/Module*.symvers /lib/modules/2.6.18-194.8.1.v5/kernel/drivers/vmbus
    Installing vmbus driver...done.
    Installing netvsc driver...done.
    Installing storvsc driver...done.
    Installing blkvsc driver...done.
    Installing hv_timesource driver...done.
    Updating module dependencies. This may take a while...depmod
    done.
    Installing various udev rules and scripts...install -d -m0755 /etc/vmbus
    install -m0755 ./scripts/vmbus.uevent /etc/vmbus
    install -m0755 ./scripts/netvsc.uevent /etc/vmbus
    install -m0644 ./scripts/20-vmbus.rules /etc/udev/rules.d
    install -m0644 ./scripts/20-netvsc.rules /etc/udev/rules.d
    udevcontrol reload_rules
    done.
    Updating initrd image...
    chmod 755 ./scripts/updateinitrd.pl
    ./scripts/updateinitrd.pl vmbus netvsc storvsc blkvsc hv_timesource
    Backing up /boot/initrd-2.6.18-194.8.1.v5.img to /boot/initrd-2.6.18-194.8.1.v5.img.backup0
    Done. Updated /boot/initrd-2.6.18-194.8.1.v5.img
    Updating grub conf file...
    chmod 755 ./scripts/updategrub.pl
    ./scripts/updategrub.pl
    Done.
    Installing vmbus startup script...
    install -m0755 ./scripts/vmbus /etc/init.d
    chkconfig --add vmbus
    /etc/init.d/vmbus start
    [root@clearos52 linux_ic_v21_rtm]# [ OK ]

    This command will verify the Microsoft driver was installed:

    [root@clearos52 linux_ic_v21_rtm]# lsmod | grep vsc

    storvsc 32548 0
    vmbus 52168 1 storvsc
    scsi_mod 141908 8 storvsc,ib_iser,iscsi_tcp,libiscsi2,scsi_transport_iscsi2,scsi_dh,libata,sd_mod

    At this point you reboot the ClearOS VM:

    shutdown –h now

    and once it is back up then continue editing the files mentioned in the prior post (about the Release Candidate v2.1 driver). After editing is complete then one more reboot and everything should be working correctly.
    The reply is currently minimized Show
Your Reply