Posts Tagged ‘Linux’
Linux on Hyper-V — use hv_storvsc instead of ata_piix to handle the IDE disks devices ( but not for the DVD-ROM CD-ROM device handling)
2012-03-29 17:28:50 :
See later:
==
List: linux-kernel
Subject: [PATCH 1/1] ata_piix: defer disks to the Hyper-V paravirtualised drivers by default
From: Andy Whitcroft
Date: 2012-03-29 17:28:50
==
http://marc.info/?l=linux-kernel&w=2&r=1&s=hyper-v&q=b
=>
http://marc.info/?l=linux-kernel&m=133302969709312&w=2
==
List: linux-kernel
Subject: Linux on Hyper-V -- use hv_storvsc instead of ata_piix to handle the IDE disks devices ( but not for the DVD-ROM / CD-ROM device handling) Fw: [PATCH RFC] ata_piix: ignore disks in a hyper-v guest
From: "Victor Miasnikov"
Date: 2012-03-29 14:00:05
Hi!
Shortly:
IMHO, need apply 1/2 ( or combined ) solution problem related "ata_piix.c" in Hyper-V enviroment:
"UBUNTU Way" Solution -- tested with
Ubuntu 12.04 LTS (Precise Pangolin) Daily Build 2012-03-13
precise-desktop-amd64.iso
, work Ok
"OpenSUSE Way" Solution -- tested with
{
OpenSUSE v12.2-Milestone1 09-Feb-2012 16:01 741M
http://download.opensuse.org/distribution/12.2-Milestone1/iso/
[
http://ftp.byfly.by/pub/opensuse/distribution/12.2-Milestone1/iso/openSUSE-KDE-LiveCD-Build0151-x86_64.iso
]
•Last modified: Thu, 09 Feb 2012 15:01:45 GMT (Unix time: 1328799705)
•SHA-1 Hash: 2d9063b7a3ae0c0e43cd91c1ad97ad62b712db18
•MD5 Hash: 220687642130915637357791fe4b5fd1
}
, work Ok
---
1 Problem , 2 solution:
Problem:
http://marc.info/?l=linux-ide&m=131489185106149&w=2
==
From: Olaf Hering
Date: 2011-09-01 15:43:40
Subject: [PATCH RFC] ata_piix: ignore disks in a hyper-v guest
> both ata_piix and hv_blkvsc ( VVM: on 2012-03-XX hv_storvsc) will bind to the same drive
. . .
Here is an attempt ( VVM: on 2012-03-XX worked solution see "OpenSUSE Way") to
ignore disks in a hyper-v disks, and let ata_piix handle only the configured cdrom devices (iso of physical).
If the disks are not ignored, they will appear twice,
once through ata_piix and once through hv_storvsc.
. . .
==
http://vvm.blog.tut.by/2012/02/16/state-of-linux-on-hyper-v/
==
. . .
Kernel v3.2: With Arch fork Сhakra: . . . , but
\dev\sdb is IDE Drive Master Primary ( and not work as need)
and
\dev\sda is IDE Drive Master Primary
i.e.
— \dev\sda = = \dev\sdb
and SCSI not \dev\sdb , but \dev\sdc — IMHO, it is may be not very well ( VVM: on 2012-03-XX -- de-facto, big problem
)
see Linux on Hyper-V Image:
[ Image => see blog ]
. . .
--------------------------------------------------------------------------------
From: KY Srinivasan
Sent: Tuesday, February 21, 2012 7:37 PM
To: Miasnikov Victor
Subject: RE: . . . b) patches to ata_piix need in _official_ kernel RE: Ubuntu: ata_piix.prefer_ms_hyperv=0 Fw: Problem:
\dev\sda == \dev\sdb Fw: IDE drives to hv_storvsc and drops hv_blkvsc Fw: State of Linux on Hyper-V
. . .
With regards to the ata_piix changes, we will try to push that upstream shortly. ( VVM: on 2012-03-29 -- IMHO, need
start work
)
K. Y
==
http://kernel.opensuse.org/cgit/kernel-source/commit/?id=d0bebdb606bad2545622f61225707f061bd6eba5
==
If the disks are not ignored, they will appear twice: once through piix and once through hv_storvsc.
hv_storvsc can not handle ATAPI devices because they can only be accessed
through the emulated code path (not through the vm_bus channel),
the piix driver is still required.
==
http://kernel.ubuntu.com/git?p=ubuntu/ubuntu-precise.git;a=commit;h=a896e46ae52619bf4f34cdb342c2862071f5c25c
===
UBUNTU: SAUCE: ata_piix: defer disks to the Hyper-V drivers by default
author Andy Whitcroft
. . .
Mon, 19 Mar 2012 17:30:08 +0000 (11:30 -0600)
. . .
UBUNTU: SAUCE: ata_piix: defer disks to the Hyper-V drivers by default
When we are hosted on a Microsoft Hyper-V hypervisor
the guest disks are exposed both via the Hyper-V paravirtualised drivers and via an emulated SATA disk drive.
In this case we want to use the paravirtualised drivers if we can as they are much more efficient.
Note that the Hyper-V paravirtualised drivers only expose the virtual hard disk devices,
the CDROM/DVD devices must still be enumerated.
Check the disk type when picking up its ID and if it appears to be a disk just report it disconnected.
BugLink: http://bugs.launchpad.net/bugs/929545
BugLink: http://bugs.launchpad.net/bugs/942316
Signed-off-by: Andy Whitcroft
===
Solutions:
use hv_storvsc instead of ata_piix to handle the IDE disks devices ( but not for the DVD-ROM CD-ROM device handling)
Or
ata_piix should not control the disks when hosted on Hyper-V
Or
Modify the ata_piix driver to recognize that when hosted on Hyper-V, it should not control the disks.
"UBUNTU Way" Solution:
(
{
Ubuntu 12.04 (PP) development kernel tree -- Ubuntu-3.2.0-20.33
http://kernel.ubuntu.com/git?p=ubuntu/ubuntu-precise.git;a=summary
[
http://kernel.ubuntu.com/git?p=ubuntu/ubuntu-precise.git;a=snapshot;h=870f3e33f86692a751ca7b94a7ad96e114674489;sf=tgz
]
}
)
See variant ( i.e. patch only with soruce code related Hyper-V ):
==
--- ..00\ata_piix.c Thu Jan 05 02:55:44 2012
+++ ata_piix.c Thu Mar 29 13:41:04 2012
@@ -91,12 +91,15 @@
#include
#include
#include
#include
#include
#include
+#ifdef CONFIG_X86
+#include
+#endif
#define DRV_NAME "ata_piix"
#define DRV_VERSION "2.13"
enum {
PIIX_IOCFG = 0x54, /* IDE I/O configuration register */
@@ -185,12 +188,35 @@
static int piix_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg);
static int piix_pci_device_resume(struct pci_dev *pdev);
#endif
static unsigned int in_module_init = 1;
+static int prefer_ms_hyperv = 1;
+
+unsigned int ata_piix_read_id(struct ata_device *dev,
+ struct ata_taskfile *tf, u16 *id)
+{
+ int ret = ata_do_dev_read_id(dev, tf, id);
+
+#ifdef CONFIG_X86
+ /* XXX: note that the device id is in little-endian order, the caller
+ * will shift it to host order, but we are working with little-endian.
+ * As this is _only_ used on x86 we can actually directly access it
+ * as host is also little-endian.
+ */
+ if (!ret && prefer_ms_hyperv && x86_hyper == &x86_hyper_ms_hyperv &&
+ ata_id_is_ata(id)) {
+ ata_dev_printk(dev, KERN_WARNING, "ATA disk ignored deferring to Hyper-V paravirt driver\n");
+
+ return AC_ERR_DEV|AC_ERR_NODEV_HINT;
+ }
+#endif
+ return ret;
+}
+
static const struct pci_device_id piix_pci_tbl[] = {
/* Intel PIIX3 for the 430HX etc */
{ 0x8086, 0x7010, PCI_ANY_ID, PCI_ANY_ID, 0, 0, piix_pata_mwdma },
/* VMware ICH4 */
{ 0x8086, 0x7111, 0x15ad, 0x1976, 0, 0, piix_pata_vmw },
/* Intel PIIX4 for the 430TX/440BX/MX chipset: UDMA 33 */
@@ -348,12 +374,13 @@
static struct ata_port_operations piix_pata_ops = {
.inherits = &piix_sata_ops,
.cable_detect = ata_cable_40wire,
.set_piomode = piix_set_piomode,
.set_dmamode = piix_set_dmamode,
.prereset = piix_pata_prereset,
+ .read_id = ata_piix_read_id,
};
static struct ata_port_operations piix_vmw_ops = {
.inherits = &piix_pata_ops,
.bmdma_status = piix_vmw_bmdma_status,
};
@@ -1685,6 +1712,8 @@
{
pci_unregister_driver(&piix_pci_driver);
}
module_init(piix_init);
module_exit(piix_exit);
+
+module_param(prefer_ms_hyperv, int, 0);
==
"OpenSUSE Way" Solution:
http://kernel.opensuse.org/cgit/kernel/commit/?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
http://kernel.opensuse.org/cgit/kernel/tree/drivers/ata/ata_piix.c?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
[
http://kernel.opensuse.org/cgit/kernel/plain/drivers/ata/ata_piix.c?id=aeff3a8fcde6df6e7f26618c5e3bc716a6aa9e85
]
See variant ( i.e. patch only with soruce code related Hyper-V ):
==
--- ..00\ata_piix.c Tue Mar 27 14:39:53 2012
+++ ata_piix.c Tue Mar 27 14:40:31 2012
@@ -162,16 +162,17 @@
const int *map;
u32 saved_iocfg;
void __iomem *sidpr;
};
static int piix_init_one(struct pci_dev *pdev,
const struct pci_device_id *ent);
static void piix_remove_one(struct pci_dev *pdev);
+static unsigned int piix_pata_read_id(struct ata_device *adev, struct ata_taskfile *tf, u16 *id);
static int piix_pata_prereset(struct ata_link *link, unsigned long deadline);
static void piix_set_piomode(struct ata_port *ap, struct ata_device *adev);
static void piix_set_dmamode(struct ata_port *ap, struct ata_device *adev);
static void ich_set_dmamode(struct ata_port *ap, struct ata_device *adev);
static int ich_pata_cable_detect(struct ata_port *ap);
static u8 piix_vmw_bmdma_status(struct ata_port *ap);
static int piix_sidpr_scr_read(struct ata_link *link,
unsigned int reg, u32 *val);
@@ -346,16 +347,17 @@
};
static struct ata_port_operations piix_pata_ops = {
.inherits = &piix_sata_ops,
.cable_detect = ata_cable_40wire,
.set_piomode = piix_set_piomode,
.set_dmamode = piix_set_dmamode,
.prereset = piix_pata_prereset,
+ .read_id = piix_pata_read_id,
};
static struct ata_port_operations piix_vmw_ops = {
.inherits = &piix_pata_ops,
.bmdma_status = piix_vmw_bmdma_status,
};
static struct ata_port_operations ich_pata_ops = {
@@ -633,16 +635,36 @@
};
MODULE_AUTHOR("Andre Hedrick, Alan Cox, Andrzej Krzysztofowicz, Jeff Garzik");
MODULE_DESCRIPTION("SCSI low-level driver for Intel PIIX/ICH ATA controllers");
MODULE_LICENSE("GPL");
MODULE_DEVICE_TABLE(pci, piix_pci_tbl);
MODULE_VERSION(DRV_VERSION);
+static int piix_msft_hyperv(void)
+{
+ int hv = 0;
+#if defined(CONFIG_HYPERV_STORAGE) || defined(CONFIG_HYPERV_STORAGE_MODULE)
+ static const struct dmi_system_id hv_dmi_ident[] = {
+ {
+ .ident = "Hyper-V",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Microsoft Corporation"),
+ DMI_MATCH(DMI_PRODUCT_NAME, "Virtual Machine"),
+ DMI_MATCH(DMI_BOARD_NAME, "Virtual Machine"),
+ },
+ },
+ { } /* terminate list */
+ };
+ hv = !!dmi_check_system(hv_dmi_ident);
+#endif
+ return hv;
+}
+
struct ich_laptop {
u16 device;
u16 subvendor;
u16 subdevice;
};
/*
* List of laptops that use short cables rather than 80 wire
@@ -722,16 +744,36 @@
static int piix_pata_prereset(struct ata_link *link, unsigned long deadline)
{
struct ata_port *ap = link->ap;
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
if (!pci_test_config_bits(pdev, &piix_enable_bits[ap->port_no]))
return -ENOENT;
return ata_sff_prereset(link, deadline);
+}
+
+static unsigned int piix_pata_read_id(struct ata_device *adev, struct ata_taskfile *tf, u16 *id)
+{
+ unsigned int err_mask = ata_do_dev_read_id(adev, tf, id);
+ /*
+ * Ignore disks in a hyper-v guest.
+ * There is no unplug protocol like it is done with xen_emul_unplug= option.
+ * Emulate the unplug by ignoring disks when the hv_storvsc driver is enabled.
+ * If the disks are not ignored, they will appear twice: once through
+ * piix and once through hv_storvsc.
+ * hv_storvsc can not handle ATAPI devices because they can only be
+ * accessed through the emulated code path (not through the vm_bus
+ * channel), the piix driver is still required.
+ */
+ if (ata_id_is_ata(id) && piix_msft_hyperv()) {
+ ata_dev_printk(adev, KERN_WARNING, "ATA device ignored in Hyper-V guest\n");
+ id[ATA_ID_CONFIG] |= (1 <host->dev);
==
Best regards, Victor Miasnikov
Blog: http://vvm.blog.tut.by/
--
----- Original Message -----
From: "Olaf Hering" ohering
To: "Victor Miasnikov" vvm
Cc: "Andy Whitcroft" apw ( at )canonical; "Mathieu Simon"
Sent: Thursday, March 29, 2012 4:58 PM
Subject: Re: Are You see "UBUNTU Way" Variant? Fw: Are You see "OpenSUSE Way" Variant? Fw: UBUNTU: SAUCE: ata_piix: defer disks to the Hyper-V drivers by default
On Thu, Mar 29, Victor Miasnikov wrote:
>
> Hi!
> Are You see "UBUNTU Way" Variant?
Victor,
thanks for sharing their approach. Either way is fine for the time
being, disks are ignored by ata_piix if it runs in hyper-v guest.
Now someone has to step up and submit a change suitable for upstream.
Both approaches have the issue that ATA probing is slightly delayed, at
least that happens with our change.
Olaf
--
----- Original Message -----
From: "Victor Miasnikov" vvm
To: "Olaf Hering" ohering
Cc: "Andy Whitcroft" apw ( at ) canonical.com; "Mathieu Simon" ; "KY Srinivasan" kys (at) microsoft
Sent: Thursday, March 29, 2012 5:10 PM
Subject: Re: Are You see "UBUNTU Way" Variant? Fw: Are You see "OpenSUSE Way" Variant? Fw: UBUNTU: SAUCE: ata_piix: defer disks to the Hyper-V drivers by default
Hi!
> thanks for sharing their approach.
No problem
> Either way is fine for the time being,
> disks are ignored by ata_piix if it runs in hyper-v guest.
>
> Now someone has to step up and submit a change suitable for upstream.
> Both approaches have the issue that ATA probing is slightly delayed, at
> least that happens with our change.
"issue . . .is slightly delayed" -- but Linux work as need
And see in P.P.S. :
[ this blog entry ]
Best regards, Victor Miasnikov
--
https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/942316
==
Mike Sterling (mike-sterling) wrote on 2012-03-05:
==
After reviewing this - I suspect the issue is the modifications to ata_piix to prevent it from loading on a Hyper-V platform. Since ata_piix now detects a Hyper-V platform and unloads if it's found, this would prevent the OS from installing. We need a modification to the patch here ( VVM: only for history
. . ./lp929545-precise/0001-ata_piix-defer-to-the-Hyper-V-drivers-by-default.patch ) that will only unload the block device handling, not the CD/DVD device handling.
==
Done: 1) in Ubuntu kernel already 2) for "vanila kernel" send patch ( Big thanks Andy Whitcroft (apw)! ) see
http://marc.info/?l=linux-kernel&m=133304222215301&w=2
==
List: linux-kernel
Subject: [PATCH 1/1] ata_piix: defer disks to the Hyper-V paravirtualised drivers by default
From: Andy Whitcroft
Date: 2012-03-29 17:28:50
When we are hosted on a Hyper-V hypervisor the guest disks are exposed
both via the Hyper-V paravirtualised drivers and via an emulated SATA disk
controller. We want to use the paravirtualised drivers where possible as
they are much more performant. The Hyper-V paravirtualised drivers only
expose the virtual hard disk devices, the CDROM/DVD devices must still
be enumerated on the virtualised SATA controller. As we have no control
over kernel probe order for these two drivers especially when one driver
is builtin to the kernel and the other a module, we need to prevent the
ata_piix driver from claiming the disks devices by default when running
on a Hyper-V hypervisor.
When enumerating the drives look at the aquired device ID and if it
appears to be a disk device then report it as disconnected. Limit this
behaviour to when we have detected a Hyper-V hypervisor. Finally allow
this behaviour to be overriden via a new module parameter.
==
==
==
State of Linux on Hyper-V — total «moved out ot staging» in kernel v3.2/v3.3
Update 2012-02-23 12-00:
a)
See
==
K. Y. Srinivasan:
With regards to the ata_piix changes, we will try to push that upstream shortly.
==
z)
Hyper-V drivers for Linux will finally leave the staging area with 3.4
http://git.kernel.org/?p=linux/kernel/git/gregkh/staging.git;a=commit;h=89ae7d709357df3a60e81c57613859d91d093ace
==
. . .
Staging: hv: storvsc: Move the storage driver out of the staging area
The storage driver (storvsc_drv.c) handles all block storage devices
assigned to Linux guests hosted on Hyper-V. This driver has been in the
staging tree for a while and this patch moves it out of the staging area.
James was willing to apply this patch during the 3.3-rc phase and a decision
was taken to defer this to 3.4 since Greg had queued up a bunch of storvsc
patches for 3.4. Now that Greg has applied all of the pending storvsc patches,
I am sending this patch to move this driver out of staging. Based on James’
recommendation, this patch gets rid of the unneeded files in the staging/hv
directory.
. . .
==
Update 2012-02-21 11-32:
See
==
«Ubuntu Way»
. . .
2. Modify the ata driver to recognize that when hosted on Hyper-V
==
Update 2012-02-17 16-05:
see later:
==
Kernel v3.2: With Arch fork Сhakra: mouse work fine ( simply — ideal) , but
— \dev\sda = = \dev\sdb
\dev\sdb is IDE Drive Master Primary ( and not work as need)
and
\dev\sda is IDE Drive Master Primary
and SCSI not \dev\sdb , but \dev\sdc — IMHO, it is may be not very well
==
http://www.simweb.ch/blog/2011/12/experimental-hyper-v-branch/
==
. . .
. . . will be coming from stagin-next, hid and the network area where some of the drivers Hyper-V have left staging as of December 2011. So with the release of 3.2 sooner or later, you can fetch a kernel that has:
• SCSI hot plug / remove
• netvsc network promiscuous mode
• netvsc and hid out of staging
. . .. . . – I’m quite positive with 3.4 most of Hyper-V code will have left staging and reached a maturity for other distributions to enable drivers in default kernel builds.
If you’re a admin that has to manage Linux on Hyper-V – other than SLES/RHEL or CentOS – now you should be asking your distributions to enable these modules (at least hyper-v bus with 3.2)
. . .
==
http://www.simweb.ch/blog/2011/12/experimental-hyper-v-branch/
==
Experimental Hyper-V branchHere is a experimental branch of the mainline kernel with some backported patches . . .
https://gitorious.org/~matsimon/linux-gymkl/matsimons-hv-kernel
==
{
http://www.simweb.ch/blog/2011/10/state-of-linux-on-hyper-v/
==
State of Linux on Hyper-V
Update 02.2012 . . .
==
==
. . . move the handling of IDE drives to hv_storvsc and drops hv_blkvsc completely . . .Update: It seems one can ommit this having only /boot and GRUB on the bootable IDE disk, thanks Victor – he has more details how to omit this.
Actually it’s not a technical problem yet. MS handles this via modprobe rules in their Linux ICs for sanity.
==
==
Partly leaving the staging area
Greg Kroah-Hartmann has put a patch in staging-next that moves the VMBus part out of drivers/staging/hv – read his commit message. It now means the VMBus drivers – the paravirtualized bus of Hyper-V where paravirt devices connect to the hypervisor backend – are considered enough cleaned up to be considered stable.Update: With Linux 3.3 only storvsc will be / is left in staging area. This means that the kernel hackers think that the overall quality of the kernel modules are believed to be good enough for daily use. For sure there are possible bugs and will be fixed hopefully as well.
==
==
Mouse support
. . .Update: I have since then tested the dirvers, 3.2 seems to work well but 3.3 contains some memory leak bugfixes others have had their issues with them in 3.0/3.1. If you dont have X.org on a Server VM, you can quietly ignore this module anyway. – I’ll let Puppet do the work or SSH to the box first
Starting 3.3 the driver has been renamed once as hid_hyperv and was moved out ot staging.
==
}
----- Original Message -----
From: "Mathieu Simon"
To: "Victor Miasnikov"
Sent: Thursday, February 16, 2012 4:32 PM
. . .
While 3.2 is quite ok, 3.3 still has a bunch of fixes that look scary - and are missing in 3.2 still (kernel oopses, memory leaks etc.)
Have fun with Arch on Hyper-V - there is a patch underway that will also remove the 4 vCPU limit that is still yet imposed by 2008 R2 and will go awa with Windows 8 Servers.
. . .
But I ( Mathieu Simon) don't think this patch is already in 3.3.
You can read here:
http://groups.google.com/group/linux.kernel/browse_thread/thread/26e70c50d24fd38c/9aa8eea98838fbf3?show_docid=9aa8eea98838fbf3
. . .
--
----- Original Message -----
From: "Victor Miasnikov"
To: "Mathieu Simon"
Sent: Thursday, February 16, 2012 5:51 PM
. . . Thanks You for very interesant and usefull blog and other work
>> If you dont have X.org on a Server VM, you can quietly ignore this module anyway. – I’ll let Puppet do the work or SSH to the box first
If need mouse in old-kernel Linux -- simple use directly connect via Hyper-V MMC from physically Windows-workstantion
. . .
--
Update 2012-02-17 16-05:
Kernel v3.2: With Arch fork Сhakra: mouse work fine ( simply — ideal) , but
\dev\sdb is IDE Drive Master Primary ( and not work as need)
and
\dev\sda is IDE Drive Master Primary
i.e.
— \dev\sda = = \dev\sdb
and SCSI not \dev\sdb , but \dev\sdc — IMHO, it is may be not very well
see Linux on Hyper-V Image:

Full size picture:
http://vvm.blog.tut.by/files/2012/02/Linux-on-Hyper-V-Image-2012-02-17-14-04.png
–
Update 2012-02-21 11-32:
From: Miasnikov Victor
Sent: Tuesday, February 21, 2012 11:23 AM
To: 'K. Y. Srinivasan'
Subject: Ubuntu: ata_piix.prefer_ms_hyperv=0 Fw: Problem: \dev\sda == \dev\sdb is is IDE Drive Master Primary and SCSI not \dev\sdb , but \dev\sdc Fw: move the handling of IDE drives to hv_storvsc and drops hv_blkvsc completely Fw: State of Linux on Hyper-V
. . .
Can solve problem someone a-la this
Var A Or "Ubuntu Way"
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/929545
==
. . .
The strategies Microsoft currently use on other distributions are based on setting up modprobe rules but these will not work on Ubuntu
as the native (ata*) driver is built directly into the kernel.
. . .
2. Modify the ata driver to recognize that when hosted on Hyper-V, it
should not control the disks.
. . .
Andy Whitcroft (apw) wrote on 2012-02-10:
I . . . add hyper-v detection to the ata_piix driver. This basically defers handling to hyper-v by default if the hypervisor is detected. I have also added an override to allow this to be suppressed from the command line. Could someone with a hyper-v based cloud test the kernels below and report whether they work here. Could you please include a dmesg of a successful boot so I can confirm the detection has recorded itself correctly. It would also be helpful to get a boot with ata_piix.prefer_ms_hyperv=0,
==
http://www.ubuntuupdates.org/package/core/precise/main/base/linux-image-3.2.0-17-generic
=>
===
...
* deviations -- note the source of the Hyper-V updates
* SAUCE: ata_piix: defer to the Hyper-V drivers by default
- LP: #929545
...
===
==
http://people.canonical.com/~apw/lp929545-precise/0001-ata_piix-defer-to-the-Hyper-V-drivers-by-default.patch
===
From 9c2e8890fee7c07540e477bac63984a53a903455 Mon Sep 17 00:00:00 2001
From: Andy Whitcroft
Date: Fri, 10 Feb 2012 12:17:14 +0000
Subject: [PATCH 01/70] ata_piix: defer to the Hyper-V drivers by default
When we are hosted on a Microsoft Hyper-V hypervisor the guest disks
are exposed both via the Hyper-V paravirtualised drivers and via an
emulated SATA disk drive. In this case we want to use the
paravirtualised drivers if we can as they are much more efficient.
Add check for the Hyper-V hypervisor during initialisation and avoid
initialising. Also adds a module parameter to override this behaviour.
BugLink: http://bugs.launchpad.net/bugs/929545
Signed-off-by: Andy Whitcroft
---
debian/rules.d/1-maintainer.mk | 1 +
drivers/ata/ata_piix.c | 17 +++++++++++++++++
2 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/debian/rules.d/1-maintainer.mk b/debian/rules.d/1-maintainer.mk
index 975cd79..6477b68 100644
--- a/debian/rules.d/1-maintainer.mk
+++ b/debian/rules.d/1-maintainer.mk
@@ -92,6 +92,7 @@ prev_release="$(release)-$(prev_revision)"
printchanges:
@baseCommit=$$(git log --pretty=format:'%H %s' | \
awk '/UBUNTU: '".*Ubuntu-$(prev_release)"'$$/ { print $$1; exit }'); \
+ echo "$$baseCommit" ; \
git log "$$baseCommit"..HEAD | \
perl -w -f $(DROOT)/scripts/misc/git-ubuntu-log $(ubuntu_log_opts)
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c
index 69ac373..f8280c5 100644
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -94,6 +94,9 @@
#include
#include
#include
+#ifdef CONFIG_X86
+#include
+#endif
#define DRV_NAME "ata_piix"
#define DRV_VERSION "2.13"
@@ -1666,9 +1669,21 @@ static void piix_remove_one(struct pci_dev *pdev)
ata_pci_remove_one(pdev);
}
+static int prefer_ms_hyperv = 1;
+
static int __init piix_init(void)
{
int rc;
+#ifdef CONFIG_X86
+ /*
+ * If we are on the Microsoft Hyper-V platform deferr to its block
+ * drivers.
+ */
+ if (prefer_ms_hyperv && x86_hyper == &x86_hyper_ms_hyperv) {
+ pr_info("ata_piix: deferring to Hyper-V hypervisor");
+ return -ENODEV;
+ }
+#endif
DPRINTK("pci_register_driver\n");
rc = pci_register_driver(&piix_pci_driver);
@@ -1688,3 +1703,5 @@ static void __exit piix_exit(void)
module_init(piix_init);
module_exit(piix_exit);
+
+module_param(prefer_ms_hyperv, int, 0);
--
1.7.9
===
==
==
http://people.canonical.com/~apw/lp929545-precise/0002-debug.patch
===
From b58963a158e54b716bd6e43de08df4503f273a00 Mon Sep 17 00:00:00 2001
From: Andy Whitcroft
Date: Fri, 10 Feb 2012 19:55:16 +0000
Subject: [PATCH 02/70] debug
---
drivers/ata/ata_piix.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c
index f8280c5..b022548 100644
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -1682,6 +1682,8 @@ static int __init piix_init(void)
if (prefer_ms_hyperv && x86_hyper == &x86_hyper_ms_hyperv) {
pr_info("ata_piix: deferring to Hyper-V hypervisor");
return -ENODEV;
+ } else {
+ pr_info("ata_piix: no Hyper-V hypervisor found");
}
#endif
--
1.7.9
===
==
Var B Or "OpenSUSE Way"
http://patchwork.ozlabs.org/patch/112939/
===
...
Olaf Hering - Sept. 1, 2011, 3:43 p.m.
On Wed, Aug 31, Olaf Hering wrote:
> After some more testing it looks like the hv_blkvsc driver claimed the
> ide major #3, so the ide_core could not bind to the emulated IDE
> hardware. The modprobe.conf rules prevented that ata_piix gets loaded.
> If I force a module load order of 'ata_piix ;hv_blkvsc' both ata_piix
> and hv_blkvsc will bind to the same drive, just as shown in my previous
> mail. So there is appearently no way to shutdown the IDE ports like it
> is done with xen_emul_unplug= option for Xen guests.
>
> Maybe some hack is needed for a hyper-v specific unplug if Windows does
> indeed lack that feature. Now that ata_piix is compiled into the kernel,
> there is nothing to a modprobe.conf rule can "fix".
Here is an attempt to ignore disks in a hyper-v disks, and let ata_piix
handle only the configured cdrom devices (iso of physical).
If the disks are not ignored, they will appear twice, once through
ata_piix and once through hv_storvsc.
Once hv_storvsc can also handle the configured cdrom devices, the added
piix_pata_read_id() function can be removed again. Only the check in
piix_init() or something similar needs to be done.
Maybe there is a better way enable only ATA_DEV_ATAPI?
Signed-off-by: Olaf Hering
. . .
Patch
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -98,6 +98,10 @@
#define DRV_NAME "ata_piix"
#define DRV_VERSION "2.13"
+#if defined(CONFIG_HYPERV_STORAGE) || defined(CONFIG_HYPERV_STORAGE_MODULE)
+#define PIIX_IGNORE_ATA_ON_HYPERV 1
+#endif
+
. . .
...
===
--------------------------------------------------------------------------------
From: KY Srinivasan
Sent: Tuesday, February 21, 2012 7:37 PM
To: Мясников Виктор Вячеславович
Subject: RE: . . . b) patches to ata_piix need in _official_ kernel RE: Ubuntu: ata_piix.prefer_ms_hyperv=0 Fw: Problem: \dev\sda == \dev\sdb Fw: IDE drives to hv_storvsc and drops hv_blkvsc Fw: State of Linux on Hyper-V
. . .
With regards to the ata_piix changes, we will try to push that upstream shortly.
K. Y
Linux Hyper-V fix PM-Timer Bug by add acpi_pm_good to the kernel command in GRUB menu.lst
!!!
!!! VVM: need for Hyper-V:
!!! added acpi_pm_good to the kernel command in /boot/grub/menu.lst
!!!
Error:
run
dmesg
or best
dmesg | grep *
and see
===
...
* Found PM-Timer Bug on the chipset. Due to workarounds for a bug,
* this clock source is slow. Consider trying other clock sources
...
===
Solution:
===
...
added acpi_pm_good to the kernel command in /boot/grub/menu.lst
...
===
http://home.earthlink.net/~peter.a.taylor/dualboot.htm
===
. . . my wife's computer, "Isis", . . .
. . .
I also note that Linux (on Isis) gave me this boot-time warning message:* The chipset may have PM-Timer Bug. Due to workarounds for a bug,
* this clock source is slow. If you are sure your timer does not have
* this bug, please use "acpi_pm_good" to disable the workaroundI downloaded the pmtmr_test.c program by OGAWA Hirofumi
==http://markmail.org/message/yapeh7vrwrsticzf
==
to test for this, compiled with gcc (gcc -opmtmr_test pmtmr_test.c),
ran it, concluded that Isis did not have this bug, and
added acpi_pm_good to the kernel command in /boot/grub/menu.lst
. This made Linux noticably faster on Isis.. . .
===
Arch Linux: Hyper-V And archboot.iso
https://bbs.archlinux.org/viewtopic.php?id=127923&p=1
==
Arch Linux (archboot creation tool) 2011.10-1, "2k11-R6" has been released.
. . .
Environment changes:
. . .
- added hypervisor kernel modules
==
IMHO, "hypervisor kernel modules" best read as "Hyper-V ( hv_ ) kernel modules".
----- Original Message -----
From: "Victor Miasnikov"
To: "Tobias Powalowski (tpowa)"
Sent: Friday, September 09, 2011 5:18 PM
Subject: Big thanks! Re: Please, add again modules for Hyper-V ( hv_ ) to -archboot.iso Re: archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Hi!
>> Please, add again modules for Hyper-V ( hv_ ) to -archboot.iso
> Next archboot iso will contain the modules you need.
Big thanks!
Best regards, Victor Miasnikov
---
----- Original Message -----
From: "Tobias Powalowski (tpowa)"
To: "Victor Miasnikov"
Sent: Friday, September 09, 2011 5:05 PM
Subject: Re: Please, add again modules for Hyper-V ( hv_ ) to -archboot.iso Re: archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Next archboot iso will contain the modules you need.
greetings
tpowa
--
----- Original Message -----
From: "Victor Miasnikov"
To: "Tobias Powalowski (tpowa)"
Sent: Friday, September 09, 2011 1:00 PM
Subject: Please, add again modules for Hyper-V ( hv_ ) to -archboot.iso Re: archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Hi!
> I can add them again,
Please, do it i.e.add again modules for Hyper-V ( hv_ )
Reason:
1)
modules for Hyper-V work fine with Arch Linux :
See:
https://bbs.archlinux.org/viewtopic.php?pid=987725#p987725
or directly:
http://vvm.blog.tut.by/2011/09/06/howto-install-archlinux-on-hyper-v/
== == ==
Boot Arch Linux Installer ( I'm use archlinux-2011.08.19-core-dual.iso )
_Before_
/arch/setupload Hyper-V module for SCSI:
==
modprobe hv_storvsc
==. . .
!!!
!!! Don't forget add hv_storvsc in MODULES= to /etc/mkinitcpio.conf
!!! before reboot step of /arch/setup
!!!/etc/mkinitcpio.conf
==
MODULES="hv_storvsc"
==. . .
== == ==
2)
I'm not run stress test, but A.Beshkov run this test on Ubuntu :
http://habrahabr.ru/blogs/virtualization/112850/
=>
http://translate.google.ru/translate?hl=ru&ie=UTF8&prev=_t&sl=auto&tl=en&u=http://habrahabr.ru/blogs/virtualization/112850/
==
It is also worth noting that Ubuntu works fine in both uniprocessor and multiprocessor configurations. The system easily scales up to 4 processors.
Unfortunately, the resources of my test server memory is limited, so to give more than 14 GB of RAM to virtual machines with Ubuntu I could not. However, for most problems ( VVM: for most task/scope) of this [memory] size is enough.. . .
In any case ( VVM: for insurance ) , inside a virtual machine with Ubuntu, I set up a Web server and FTP server. Within a few days ( VVM: for long period of time / N*24*Hours ) with scripts periodically [VVM: by cron/sheduler ] downloaded from them are quite large ( VVM: really big) amounts of data. Have been no degradation of performance, no problems, no failures i.e. all work fine.
( VVM: Russian is my mothers ( and fathers Ж-) ) language =>
"Have been no degradation of performance, no problems, no failures i.e. all work fine."
– is best [ may be IMHO] variant translation to English this phrase "Деградации быстродействия, каких либо проблем и сбоев замечено не было."Another variants:
каких либо проблем и сбоев замечено не было. = any problems and failures have been reported.
is equal
никаких проблем или сбоев не было замечено = any problems or failures was not observedis equal
ни одной проблемы или сбоя не было = not a single problem or failure was not
)The conclusion - despite the fact that the official support for Ubuntu is not stated that distribution is running Hyper-V is very reliable and, in my opinion, can be used in a production environment.
==
( VVM: A.Beshkov is Microsoft worker from Russia, but Linux/FreeBSD fan )
2b)
Archlinux work under Hyper-V on VDS provider:
http://habrahabr.ru/blogs/virtualization/112850/
=>
http://translate.google.ru/translate?hl=ru&ie=UTF8&prev=_t&sl=auto&tl=en&u=http://habrahabr.ru/blogs/virtualization/112850/
==
. . .
o Aecktann , January 31, 2011, 01:28
It has long been holding Archlinux under Hyper-V. No problems or differences from the standard installation is not seen at all.
o abeshkov , January 31, 2011, 01:50
( I just was wondering ) / VVM: ( I ( abeshkov) need information ) how Arch / [Arch Linux] works under Hyper-V.
Thank you for your detailed response.By the way, another question. Multiprocessing is not tested?
o Aecktann , January 31, 2011, 02:00
No, I buy the cheapest VDS, I ( Aecktann) unfortunatelycan not afford dedicted physical server for Hyper-V installation ( -- by VVM , by Google translate: ( its Hyper-V and I have nowhere to put it. ) )
. . .
==
Z)
http://habrahabr.ru/blogs/virtualization/115630/
= Translate by Google =>
http://translate.google.ru/translate?hl=ru&ie=UTF8&prev=_t&sl=auto&tl=en&u=http://habrahabr.ru/blogs/virtualization/115630/
== ==
. . .
abeshkov ( <= VVM: A.Beshkov is Microsoft worker from Russia, but Linux/FreeBSD fan ) , March 17, 2011, 16:28
the new Ubuntu 10.10 is already included [drivers for Hyper-V] by default in their core.AnViar , 16:29 March 17, 2011, 16:29
^^ Ubuntu - legislator Enterprise ^ ^![]()
abeshkov , March 17, 2011, 16:36
0 0
Ubuntu is an early indicator of future trends. A legislator enterprize in the Linux world is RedHat, which is even officially certified as a supported OS for Hyper-V.
== ==
If Arch Linux stopped support Hyper-V enviroment, I be _must_ go to Ubuntu or RHEL/CentOs
But I'm love ArchLinux
Best regards, Victor Miasnikov
Blog: http://vvm.blog.tut.by/
P.S.
> i think i removed them because of being staging
De-facto main reason: "Coding style" (!)
Analysis of initial patches for Microsoft's Hyper-V driver in the Linux ...
www.unixwiz.net/techtips/review-hv-patches.html -
20 Sep 2009 – The main reason is that the driver was written with a Windows API dialect, ....
http://www.unixwiz.net/techtips/review-hv-patches.html
==
The main reason is that the driver was written with a Windows API dialect, which certainly matches the dialect of the other side of the Hyper-V code (the part that this driver talks to).
Coding style is mainly about consistency, and there isn't any one right style. . .
In the Windows dialect, it's common to typedef essentially everything, and to rely on some common types universally defined by the Windows SDK. Everybody who's done Win32 programming knows about DWORD (32-bit unsigned integer),PVOID (void *), and HANDLE (opaque handle to a resource), among many others.
This is done with structs defined by the project as well, with things like this (chosen at random):typedef struct _VMBUS_CHANNEL_MESSAGE_HEADER
{
VMBUS_CHANNEL_MESSAGE_TYPE MessageType;
UINT32 Padding;
} VMBUS_CHANNEL_MESSAGE_HEADER, *PVMBUS_CHANNEL_MESSAGE_HEADER;
This defines the types VMBUS_CHANNEL_MESSAGE_HEADER and PVMBUS_CHANNEL_MESSAGE_HEADER, and though it looks awkward and busy for a Linux developer, this is the Win32 style: it's simply the way it's been done for at least 20 years. I don't care for it much either, but it is what it is.The Linux style prefers not to hide type information, so it would be changed to:
struct vmbus_channel_message_header
{
enum vmbus_channel_message_type MessageType;
u32 Padding;
}
I saw numerous comments on the Linux kernel mailing list chastising Microsoft for such style, but this chastisement is ignorant.
==
>and it was discussed that it will be removed again from kernel tree.
I'm found what start process "exiting staging" to normal area:
"Process for subsystem maintainers to get Hyper-V code out of staging."
http://www.spinics.net/lists/linux-ide/msg40273.html
==
To: "shemminger@xxxxxxxxxxxxxxxxxxxx" , "netdev@xxxxxxxxxxxxxxx" , "davem@xxxxxxxxxxxxx" , "linux-ide@xxxxxxxxxxxxxxx" , "Jame.Bottomley@xxxxxxxxxxxxxxxxxxxxx" , "linux-scsi@xxxxxxxxxxxxxxx"
Subject: Process for subsystem maintainers to get Hyper-V code out of staging.
From: Hank Janssen
Date: Mon, 14 Feb 2011 23:30:07 +0000. . .
Stephen/James/David,
Greetings to you all. As you might be aware, we submitted Hyper-V drivers to the kernel 2009.
We have been extending these drivers with additional functionality and our primary focus
now is doing the work needed to exit the staging area.To give you some background, the following are Hyper-V specific Linux drivers:
hv_vmbus The vmbus driver that is the bridge between guest and the host
hv_storvsc The SCSI device driver
hv_blkvsc The IDE driver
hv_netvsc The network driverWe think our drivers are pretty close to be reviewed by the subsystem maintainers.
We have been working with Greg on hv_vmbus, and several other driver issues as it
relates to exiting staging.. . .
==
But:
http://www.spinics.net/lists/linux-ide/msg40275.html
==
. . .
> We have been working with Greg on hv_vmbus, and several other driver issues as it
> relates to exiting staging. And now we are looking for guidance for the other drivers.
>
> 1. Most important thing of course, did we contact the correct subsystem
> maintainers?
> i. IDE/Blkvsc David Miller
> ii. SCSI/Storvsc James Bottomley
> iii. Network/Netvsc Stephen HemmingerThat's what the MAINTAINERS file says, right?
> 2. What is the process to submit the code for review?
Like Documentation/SubmittingPatches shows, send patches.
> 3. Which mailing list(s) do we need to use for the code reviews
Again, MAINTAINERS shows this.
> 4. I assume normal patch format is required?
Yes.
> 5. What additional information is needed
What's normally needed.
> 6. Once they leave staging where do they need to go? Because they all
> pretty much come as a package we were thinking drivers/hyperv might
> be a good place.That's up to the subsystem, if they want all network drivers in
drivers/net/ then they go there, same for scsi, it's up to the
maintainer.> There are still a few outstanding items we are currently working on. But they should be
> wrapped up shortly. (There are a few remaining FIXME comments in the code we are
> cleaning up as I write this). But if possible we would like to get your feedback even as
> we are addressing the issues we currently know about.I would wait and only ask for review _after_ you fix the things you know
about first. Otherwise it just wastes everyone's time.. . .
==
etc. . . .
P.P.S.
And see
===
. . .
Z)
. . .
If Arch Linux stopped support Hyper-V enviroment, I be _must_ go to Ubuntu or RHEL/CentOs
But I'm love ArchLinux ![]()
. . .
===
--
----- Original Message -----
From: "Tobias Powalowski (tpowa)"
To: "Victor Miasnikov"
Sent: Thursday, September 08, 2011 7:32 PM
Subject: Re: archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Am 08.09.2011 17:35, schrieb Victor Miasnikov:
> archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ?
> Can be it fixed?
I can add them again, i think i removed them because of being staging
and it was discussed that it will be removed again from kernel tree.
greetings
tpowa
--
Tobias Powalowski
Archlinux Developer & Package Maintainer (tpowa)
http://www.archlinux.org
--
----- Original Message -----
From: "Victor Miasnikov"
To: "Tobias Powalowski (tpowa)"
Sent: Thursday, September 08, 2011 6:35 PM
Subject: archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Hi!
archlinux-2011.08-2-archboot.iso not contain hv_ modules for Hyper-V ? Can be it fixed?
Best regards, Victor Miasnikov
--
2011-10-21: See:
Or boot archboot 2011.10-1
2011-09-15: See:
MODULES="pata_acpi ata_generic ata_piix hv_storvsc"
----
HowTo: Install Arch Linux on Hyper-V
https://bbs.archlinux.org/viewtopic.php?id=103981
===
Index» Kernel & Hardware » Hyper-V installation and hv_ kernel modules use
emoriver:
Hi everybody, I'm trying to install Arch as a Virtual Machine under Windows 2008 Server R2 Hyper-V.
Someone says ( _http://blog.allanglesit.com/2010/05/ubuntu-and-hyper-v-the-paths-to-enlightenment/ ) it's possible to configure Ubuntu to use synthetic devices.
I've tried with no success and that made me happy because the distro I'd like to use is Arch!
. . .
Any idea? Is there a way to translate the post I cited for Arch (I'm not able by myself, unfortunately...)?
===
Boot Arch Linux Installer ( I'm use archlinux-2011.08.19-core-dual.iso )
2011-10-21: Or boot archboot 2011.10-1
_Before_
/arch/setup
load Hyper-V module for SCSI:
==
modprobe hv_storvsc
==
after this SCSI disk
/dev/sdb
IDE disk
/dev/sda
!!!
!!! Don't forget add hv_storvsc in MODULES= to /etc/mkinitcpio.conf
!!! before reboot step of /arch/setup
!!!
/etc/mkinitcpio.conf
==
MODULES="pata_acpi ata_generic ata_piix hv_storvsc"
==
# Old variant:
# MODULES="hv_storvsc"
#
(
Estetic:
I see the following error message when booting Arch Linux:
==
piix4_smbus 0000.00.07.0: SMBus base address uninitialized - upgrade bios or use force_addr=0xaddr
==
For fix this add "blacklist i2c_piix4" to file /etc/modprobe.d/modprobe.conf
/etc/modprobe.d/modprobe.conf
==
blacklist i2c_piix4
==
)
!
!
!
Install Bootloader GRUB to IDE disk
/dev/sda
!
! Place /boot to IDE Disk !!!
!
( other partitions best place to SCSI Disk)
(
#IF /etc/mkinitcpio.conf MODULES="pata_acpi ata_generic ata_piix hv_storvsc"
# No problem "/dev/sdb _swap_ with /dev/sda"
#ELSIF /etc/mkinitcpio.conf MODULES="hv_storvsc"
Problem:
before reboot step of /arch/setup if You:
Run cfdisk /dev/sdb , see output:
==
Name Flags Part Type FS Type [Label] Size (MB)
-------------------------------------------------------------------------
Pri/Log Free Space 24.68 #
sdb2 Primary Linux swap [ARCH_SWAP] 271.44 #swap
sdb3 Primary ext4 [ARCH_ROOT] 7871.60 #root
sdb4 Primary ext4 [ARCH_HOME] 421323.52 #/home
Pri/Log Free Space 5.51 #
==
Run cfdisk , see output:
==
Name Flags Part Type FS Type [Label] Size (MB)
-------------------------------------------------------------------------
sda1 boot Primary ext2 [ARCH_BOOT] 106.93 #/boot
Pri/Log Free Space 136256.21 #
==
Run blkid , see output:
==
/dev/sda1: LABEL="ARCH_BOOT" UUID="ff414d44-50d1-4363-a71d-2722eb8e16f5" TYPE="ext2"
/dev/loop100: . . .
. . .
/dev/loop110: . . .
/dev/sdb2: LABEL="ARCH_SWAP" UUID="9e206a22-ead3-4ebb-b9e8-9315b76a7877" TYPE="swap"
/dev/sdb3: LABEL="ARCH_ROOT" UUID="a29ef7f8-8cb0-49e6-b792-7b0d72acfca6" TYPE="ext4"
/dev/sdb4: LABEL="ARCH_HOME" UUID="c0b226be-34ea-4f85-87d7-972da0038411" TYPE="ext4"
==
but in installed Arch Linux
SCSI disk
/dev/sda
IDE disk
/dev/sdb
i.e. /dev/sdb _swap_ with /dev/sda
Run cfdisk , see output:
==
Name Flags Part Type FS Type [Label] Size (MB)
-------------------------------------------------------------------------
Pri/Log Free Space 24.68 #
sda2 Primary Linux swap [ARCH_SWAP] 271.44 #swap
sda3 Primary ext4 [ARCH_ROOT] 7871.60 #root
sda4 Primary ext4 [ARCH_HOME] 421323.52 #/home
Pri/Log Free Space 5.51 #
==
Run cfdisk /dev/sdb , see output:
==
Name Flags Part Type FS Type [Label] Size (MB)
-------------------------------------------------------------------------
sdb1 boot Primary ext2 [ARCH_BOOT] 106.93 #boot
Pri/Log Free Space 136256.21 #
==
Run blkid , see output:
/dev/sda2: LABEL="ARCH_SWAP" UUID="9e206a22-ead3-4ebb-b9e8-9315b76a7877" TYPE="swap"
/dev/sda3: LABEL="ARCH_ROOT" UUID="a29ef7f8-8cb0-49e6-b792-7b0d72acfca6" TYPE="ext4"
/dev/sda4: LABEL="ARCH_HOME" UUID="c0b226be-34ea-4f85-87d7-972da0038411" TYPE="ext4"
/dev/sdb1: LABEL="ARCH_BOOT" UUID="ff414d44-50d1-4363-a71d-2722eb8e16f5" TYPE="ext2"
Solution:
#ENDIF
)
!
! Use LABEL or UUID in fstab
!
(
#IF /etc/mkinitcpio.conf MODULES="pata_acpi ata_generic ata_piix hv_storvsc"
# not need edit /boot/grub/menu.lst
#ELSIF /etc/mkinitcpio.conf MODULES="hv_storvsc"
!
! Don't forget set root= in /boot/grub/menu.lst
! before reboot step of /arch/setup
! i.e.:
In file
/boot/grub/menu.lst
replace
==
root=/dev/sdb
==
to
==
root=/dev/sda
==
Example:
==
kernel /vmlinuz-linux root=/dev/sda3 ro
==
#ENDIF
)
Sorry i’m forgot «r» in «hyper-v_mouse_in_linux» ![]()
Right URL:
http://vvm.blog.tut.by/2011/02/22/hyper-v_mouse_in_linux/
==
Without Satori, mouse work in Linux Guest if connect to it from Windows _directly_
. . .
установите на рабочую станцию MMC-оснастку Hyper-V и _напрямую_ подключайтесь к Guest-компьютерам
==
Впрочем, пусть здесь будет сперва русский текст, затем English, а там наоборот Ж-)
Комментарии, please, в «hyper-v_mouse_in_linux»
– — – –
Without Satori, mouse work in Linux Guest if connect to it from Windows _directly_
Or
Linux on Hyper-V How-To FIX “Mouse not captured in Remote Desktop session”
Подробнее:
http://blogs.technet.com/b/abeshkov/archive/2011/01/30/3383495.aspx
==
Стоит отметить, что поддержки синтетической мыши в Ubuntu нет, а проект Satori пока что не портирован под этот дистрибутив, поэтому для удаленного управления в графическом режиме я использовал VNC.
==
На практике Satori не очень-то и нужен
http://blogs.technet.com/b/abeshkov/archive/2011/02/07/3385455.aspx
==
если вы присоединяетесь к Hyper-V через RDP а затем через консоль Hyper-V открываете окно в виртуальную машину то мышь в ней работать не будет.
==
Оказалось, что это надо понимать так: установите на рабочую станцию MMC-оснастку Hyper-V и _напрямую_ подключайтесь к Guest-компьютерам
http://technet.microsoft.com/ru-ru/library/cc742454.aspx
==
Не удается использовать мышь для управления виртуальной машиной. Для подключения к серверу, на котором установлено средство Hyper-V, используется подключение к удаленному рабочему столу.
Причина. При использовании диспетчера Hyper-V для подключения к виртуальной машине это подключение обеспечивает компонент «Подключение к виртуальной машине». Однако использование подключения к виртуальной машине в сеансе подключения к удаленному рабочему столу не поддерживается, если не установлены службы интеграции. Поэтому ожидаемый результат – потеря функциональности мыши.
Устранение. Не используйте подключение к виртуальной машине в сеансе подключения к удаленному рабочему столу, . . . Есть несколько способов решить эту проблему.
- . . .
- . . .
- На поддерживаемом клиентском компьютере установить средства управления Hyper-V, чтобы установить компонент «Подключение к виртуальной машине» и создать сеанс подключения к виртуальной машине. Дополнительные сведения см. в технической библиотеке Windows Server 2008 ( http://technet.microsoft.com/ru-ru/library/cc794756(WS.10).aspx )
==
Остается некоторое неудобство:
==
При использовании подключения к виртуальной машине указатель мыши принимает вид точки или «застревает» в окне виртуальной машины.
. . .
Устранение. . . . Если операционная система на виртуальной машине не поддерживается, то можно использовать комбинацию клавиш для перемещения мыши за пределы окна виртуальной машины. Комбинация клавиш по умолчанию – CTRL+ALT+СТРЕЛКА ВЛЕВО.
==
Linux on Hyper-V How-To FIX “Mouse not captured in Remote Desktop session”
in English:
Shane 22 Oct 2010 11:34 AM
We still need mouse integration thou and I haven’t been able to find anything on how to enable it.
==
one of the dialog windows cannot be accessed using the keyboard so I’m having to leave the comfort of my office and walk all the way over to the server room, log into it, click a mouse a couple of times, and then return to the office again.
==
==
No alternate like get used to keyboard or command line controll..
==
_http://weblog.allanglesit.net/2010/05/eight-things-you-need-to-know-about-linux-on-hyper-v/
==
It is also important to note that mouse integration is not included in the kernel, and will not work
==
«not included» — Yes
«not work» — No ( if use Hyper-V MMC оn _physical_ workstantion)
http://ubuntuforums.org/showthread.php?t=1389024
==
matthew.mattoon
May 29th, 2010Now it sounds to me like the mouse is not working for you at all? If that is the case it is probably due to you using RDP from your workstation to another workstation or the server, then from their using SCVMM or Hyper-V Manager to connect to the VM. This will NOT work for mouse. If you use your workstation to connect to the VM directly via SCVMM or Hyper-V Manager it will work just fine. It is simply the problem with the RDP connection losing control of the mouse (this happens on Windows guests with no ICs as well).
==
Without Satori, mouse work in Linux Guest if connect to it from Windows _directly_ :
http://technet.microsoft.com/en-us/library/cc742454.aspx
==
When I try to control a virtual machine, I cannot use the mouse. I am using Remote Desktop Connection to connect to a server running Hyper-V.
Cause: When you use Hyper-V Manager to connect to a virtual machine, Virtual Machine Connection provides the connection to the virtual machine. However, use of Virtual Machine Connection within a Remote Desktop Connection session is not supported until integration services ( VVM: integration services _with_ synthectic mouse support) are installed. As a result, lack of mouse functionality is expected behavior.Solution: Avoid using Virtual Machine Connection within a Remote Desktop Connection session until integration services are installed. There are several ways you can accomplish this:
. . .
On a supported client computer, install the Hyper-V management tools to install Virtual Machine Connection on the computer ( VVM: «computer» need read as «personal workstantion» ) and establish a Virtual Machine Connection session to the virtual machine. For more information, see the Windows Server 2008 Technical Library (http://go.microsoft.com/fwlink/?LinkId=143558).
==
Little imperfection:
==
When I use Virtual Machine Connection, the mouse pointer appears as a dot or the mouse pointer is stuck in the virtual machine window.. . .
Solution: . . .
If the guest operating system is not supported, you can use a key combination to move the mouse out of the virtual machine window. The default key combination is CTRL+ALT+LEFT ARROW.
==
– — – — – — – — – — – — – — – — – — – — – — – — – — – — – –
Without Satori, mouse work in Linux Guest if connect to it from Windows _directly_
Or
Linux on Hyper-V How-To FIX “Mouse not captured in Remote Desktop session”
Подробнее:
http://blogs.technet.com/b/abeshkov/archive/2011/01/30/3383495.aspx
==
Стоит отметить, что поддержки синтетической мыши в Ubuntu нет, а проект Satori пока что не портирован под этот дистрибутив, поэтому для удаленного управления в графическом режиме я использовал VNC.
==
На практике Satori не очень-то и нужен
http://blogs.technet.com/b/abeshkov/archive/2011/02/07/3385455.aspx
==
если вы присоединяетесь к Hyper-V через RDP а затем через консоль Hyper-V открываете окно в виртуальную машину то мышь в ней работать не будет.
==
Оказалось, что это надо понимать так: установите на рабочую станцию MMC-оснастку Hyper-V и _напрямую_ подключайтесь к Guest-компьютерам
http://technet.microsoft.com/ru-ru/library/cc742454.aspx
==
Не удается использовать мышь для управления виртуальной машиной. Для подключения к серверу, на котором установлено средство Hyper-V, используется подключение к удаленному рабочему столу.
Причина. При использовании диспетчера Hyper-V для подключения к виртуальной машине это подключение обеспечивает компонент «Подключение к виртуальной машине». Однако использование подключения к виртуальной машине в сеансе подключения к удаленному рабочему столу не поддерживается, если не установлены службы интеграции. Поэтому ожидаемый результат – потеря функциональности мыши.
Устранение. Не используйте подключение к виртуальной машине в сеансе подключения к удаленному рабочему столу, . . . Есть несколько способов решить эту проблему.
- . . .
- . . .
- На поддерживаемом клиентском компьютере установить средства управления Hyper-V, чтобы установить компонент «Подключение к виртуальной машине» и создать сеанс подключения к виртуальной машине. Дополнительные сведения см. в технической библиотеке Windows Server 2008 ( http://technet.microsoft.com/ru-ru/library/cc794756(WS.10).aspx )
==
Остается некоторое неудобство:
==
При использовании подключения к виртуальной машине указатель мыши принимает вид точки или «застревает» в окне виртуальной машины.
. . .
Устранение. . . . Если операционная система на виртуальной машине не поддерживается, то можно использовать комбинацию клавиш для перемещения мыши за пределы окна виртуальной машины. Комбинация клавиш по умолчанию – CTRL+ALT+СТРЕЛКА ВЛЕВО.
==