Fork MediaPortal on GitHub

Whole house technology solution | Page 2

Discussion in 'Ongoing HTPC Projects' started by fujistick, January 5, 2010.

  1. vk3heg

    vk3heg

    System Specs
    Sorry for late reply. (Didn't get email about new posts)...

    The Tv tuner didn't show up in the windows device manager, although the drivers looked like they installed ok. They didn't show any error's.

    I've removed the ESXi setup for now, but would like to try again latter.. Hopefully you get some good results. It could also be with the mb I'm using, as I didn't want to go i5/7 for this test. I had the cpu here already, and just got the mb.
  2. fujistick

    fujistick Thread Starter

    vk3heg,

    This is just a guess, but did you install the VMWare Tools on the VM? Maybe these have some drivers that are required for some things to work properly - kind of like VMWare's motherboard and chipset drivers I guess. Anyway, just a thought.
  3. vk3heg

    vk3heg

    System Specs
    Vmware tools got installed. I did have two devices that wouldn't install any drivers for, even after running windows update. Those might be the reason for the tv cards not showing up in the device list (yet the drivers installed without errors). I don't have the machine setup to re-test atm. Have had a hardware shuffle here to fix a issue with another...
  4. fujistick

    fujistick Thread Starter

    Ok, I think I’m going to give up on the idea of having a working Adaptec 3805 RAID card in the same system as one with VT-d enabled for PCI pass-through to a virtual machine.

    My experiments with Xen to get the RAID card and PCI passthru working together weren’t that successful. Using the linux distro CentOS 5.4, I could install to the raid card, create VM’s & install Vista ok. However, as soon as I tried to enable VT-d functionality by adding the "iommu=1" boot parameter to the grub config file and rebooting, things stopped working properly – disk access problems, kernel panics etc.

    This leaves me with a few options. One option is to put the RAID card into another system (maybe one of those cheap all-in-one ITX sized motherboards) for all storage, and setup an iSCSI target on it for diskless boot images, etc. This would allow me to setup the PCI passthrough just fine without the RAID card issues.

    Another option is to not worry about PCI passthrough to a VM and do as pnyberg suggested and put everything in one box and install Windows 7 64-bit. This is probably the path I’ll take. I can still create VM’s using desktop/workstation versions of a hyperviser, just without PCI passthru support. The only problem is I can’t quite fit everything in.

    I have a dual slot ATI HD 4870 PCIe 16x graphics card, a PCIe 4x Adaptec 3805 RAID card, a PCIe 1x X-Fi sound card and 2 x PCIe 1x TV tuner cards. The intel DX58SO motherboard has slots for all of this plus an old PCI slot, however, the dual slot graphics card covers one of the needed PCIe 1x slots.

    I can either find a good single slot graphics card to replace the dual slot one, or maybe use something like a PCIe extender cable (e.g. http://imgs.inkfrog.com/pix/tattoocountry/13373_1.jpg) to access the spare PCIe slot under the dual slot graphics card (if it will fit), and put one of the TV tuners hanging above the spare PCI slot with the low profile bracket that came with the card.

    Anyway, to summarise what I’ve got to work, and what didn’t:

    What worked:

    PCI passthrough of a TV tuner card to a Vista VM using ESXi 4 with MP TV Server installed. This could only be achieved when installed on a SATA drive, not using the RAID card. From memory, the stuttering I mentioned earlier when using my laptop as a client went away when I plugged my laptop into the wired network rather than using WiFi. I didn’t try PCI passthru without the RAID card in Xen, but suspect it would have worked.

    The onboard SATA and LAN ports on the Intel DX58SO motherboard worked out of the box in ESXi 4.

    What didn’t work:

    Getting the Adaptec 3805 RAID card to work at all with VT-d enabled on either ESXi 4 or linux/Xen.

    Both the motherboard and the RAID card had new BIOS/firmware released in the past month or so, but neither fixed the problem.

    PCI passthrough didn’t work for every slot on the motherboard. From memory, it didn’t work in the 16x slots. Either the device would not show up in the list of PCI devices to enable for PCI passthrough, or it would either log errors when trying to start a VM with a PCI device assigned to it.
  5. vk3heg

    vk3heg

    System Specs
    Why don't you use the esxi setup, create a server VM that just has the tv cards/hd's (minus the problem raid) and then a machine that runs the media-portal front end, and talks to the server vm. That's what I was going to be doing with my setup. The client was going to run XP on a 8gb compact flash card with write's turned off, and wouldn't always be turned on.

    If you use the above setup with a esxi server vm, then a cheap pci card will work a treat. I have some here, you would be welcome to for the cost of postage.
  6. fujistick

    fujistick Thread Starter

    OK new plan, I’m not going to give up just yet. :)

    I’ve been reading a bit more about Xen, and it appears as though it may be possible to passthrough the primary VGA card to a VM. i.e. it’s used during initial boot up of the base hypervisor, then when the relevant VM is started, the VGA card is reset and control passed through to the VM with the underlying hypervisor (i.e. Xen) still accessible via the network.

    To me, this sounds very interesting and warrants further investigation. Basically I would be able to set up a TV server VM with the 2 tuner cards passed through to it, as well as a MP client front end VM with the graphics card and sound card passed through to it, all on the same hardware, completely independent of each other. Jackpot!

    There are still issues with this plan though. The RAID card is not working so I would have to leave that out. Linux has software RAID so I’ve still got that functionality. I have 6 x SATA hard drives + 1 SATA BluRay drive, but only 6 internal SATA ports on the motherboard. There are 2 eSATA which I’m not sure if I can use. That also gives me no room to expand. The RAID card had spare ports for me to expand into as required.

    But I’ll cross those bridges when I get to them. To start with, I need to confirm if this is even possible by testing whether VGA and PCI passthrough will actually work. The latest stable build on Xen is 3.4.2, but there is a new version 4.0.0 which is on the verge of being released. I think it’s up to RC8 right now, but Xen.org Weekly Newsletter Vol 10 No 12 – blog.xen.org suggests that it’s going to be released in the next few days. I believe this version fixes a lot of bugs and hacks and workarounds regarding VGA passthrough.

    I’ll keep you all posted.
  7. vk3heg

    vk3heg

    System Specs
    If your going to be running both the server and client on the one machine, then you might as well setup a windows (xp/w7) machine to act as the server/client. Ie: single seat setup, with both the server functions and client on the one machine. It'll make life a lot simpler.

    The only issue's with this type of setup, is that the frontend/client sometimes gets lost/locks up. If the fromt end can be killed (have had to do that here a number of times) then the server part still runs and the front end can be re-started.

    That's one of the reason's why I'm looking at going to a distinct server/client setup. It also means that the client dosn't have to be powerd 24/7. I have been testing a setup here, with XP pro installed onto a 8gb flash card, and writes turned off. It works really well, and even comes out of standby fine.
  8. fujistick

    fujistick Thread Starter

    With the Xen/VGA passthorugh setup I described, the server and client would be on 2 separate VMs, both running on the same hardware. Because they are logically separate, if the client locks up for whatever reason, the client VM could be rebooted or powered down (in a virtual sense) remotely via my laptop, while the server VM continues on recording, etc.

    From what I remember reading about VT-d (Intel Virtualization Technology for Directed I/O), even if the passed through hardware has a fault (e.g. graphics card while playing a game), normally this would bring down the machine, but with VT-d, it’s isolated to just that VM. Other VMs and their associated passed through hardware (e.g. server with tv cards), are oblivious to the problem and continue as normal.

    Basically, the only difference would be that instead of having a big shiny physical power button to push, you would have to do it remotely from another PC (i.e. laptop).

    This is all well and good, but I can’t get it to work. I’ve spent the better part of the past week loosely going through this guide: Steps to try Xen 4.0.0 Release Candidate 8 on Ubuntu Lucid 10.04 64 Bits – blog.xen.org

    Major hurdles included:

    • Taking 2 or 3 days to figure out why none of the Xen options were showing up in the kernel configuration (make menuconfig) before compiling it.
      • I had inadvertently downloaded the 32-bit version of Ubuntu Lucid 10.04 Beta 1, and not the required 64-bit version.
    • Typo in the instructions.
      • “make dep-pkg” should be “make deb-pkg”.
    • When the Xen hypervisor and kernel etc was correctly configured in the bootloader (Grub 2) and the system booted, it seem to lockup just before showing the graphical login prompt for domain 0. It had changed from text mode to a graphic mode, but didn’t get to displaying the background image/login prompt. Booting on my freshly built kernel without the hypervisor worked fine.
      • I still don’t know why, but at a guess it probably had something to do with the X server (the bit the does the graphic desktop) which I didn’t need or want. I could ssh in using PuTTY (PuTTY: a free telnet/ssh client) on my laptop to do everything so it wasn’t such a big problem.
    • PCI passthrough of a PCIe TV tuner card to a VM worked OK. In TV Server config on the VM I could use Manual Control to Start TimeShift, then from my laptop using VLC I could connect to that stream with no problems. However, pass-through of the graphics card didn’t work so well. When I started the VM, the screen would go blank, but that was it. The VM seemed to not do anything more. Rebooting the VM and/or the whole system didn’t seem to fix it. Reconfigure the VM not to pass through the graphics card, and it works fine again (minus the graphics card).

    This is where I’m at now. Given that it was a release candidate of the Xen hypervisor on a beta version of the OS, it’s hardly surprising some things didn’t work smoothly. Maybe this will work better when it’s had time to stabilise a bit, or when it’s integrated into a linux distro.

    For those interested, the following sites were very helpful:


    So where does that leave me. Well I could go back to the 2 physical PC’s setup. The server PC having the TV tuner’s and all the hard drives plugged into the motherboard taking up all the SATA ports, without the RAID card. This would run either ESXi 4 (with individual drives – no RAID functionality), or the latest stable Xen 3.4.2 (with software RAID of the drives) to provide VMs. The client PC would have the sound and good graphics card, bluray drive, diskless boot etc. Other then the diskless boot, I’ve done enough testing to know that this will work. However, it does leave me with no room to add more disk space when required in the future.

    Or, I could just put everything together in one machine (including the RAID card) and run Windows 7 64-bit as the host OS, and run VMWare Server or similar for non MP stuff VMs. With this setup, reboots/locksups/crashes, etc will probably affect everything, but to be honest, my current single seat HTPC has been solid for quite a while now.

    The only time my current setup has been rebooted in the past few months has been me installing the next group of windows updates every month or two, and when the dishwasher tripped the circuit breaker, thus the power went out. The biggest problem that stops TV recordings is running out of disk space for recordings and timeshifting, but that’s because I tend to set stuff up to regularly record, but forget to delete old recordings..
  9. mythmaster

    mythmaster

    Thanks for the Xen links!

    I was looking to pass-through my tuner, also, but I'm 99% sure that my AMD setup doesn't support IOMMU, so no dice.

    BTW, it sounds like your video card isn't supported out-of-the-box in Ubuntu, so you'll need to boot up in recovery mode (to a console) and load up the proper driver. You'll need to do that in your DomU, too, then you should get the VGA pass-through working. Actually, I'd set up the Dom0 to just boot to a console instead of X.
  10. jayrock
    • Premium Supporter

    jayrock

    System Specs
    AW: Whole house technology solution

    Very interesting. I'm acutally looking at the "classic" approach, ie. running Linux as VMWare host and W7 as guest OS. Not sure when I have the time to do it, will report.

Share This Page

Users Viewing Thread (Users: 0, Guests: 1)

Running the latest version?

V1.9.0 FINAL - released Sept. 2014 
Releasenews | Download
Changelog
 | Requirements
HTPC
Team-MediaPortal
 
About
Contact |  Press
Partners