disk problem affecting KVM?

(no idea what’s going on here - maybe after more coffee) Epic fail with KVM install of Win7. It may be my hard drive. I’ve never seen this behavior before - I installed a second hard drive on my laptop (replaced the dvd) and it formatted fine. But when I boot, neither of the partitions I created with gparted are mounted and both throw errors when I try to mount them and navigate to them from dolphin. But then, a few minutes later, they appear all mounted and apparently OK in dolphin. This is very odd behavior and may relate to the KVM fail (and slow disk allocation) because I was trying to create the KVM VM in those partitions.

I may have done something monumentally stupid…

/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part6 swap                 swap       defaults              0 0
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part7 /                    ext4       acl,user_xattr        1 1
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part2 /boot/efi            vfat       umask=0002,utf8=true  0 0
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part8 /home                ext4       acl,user_xattr        1 2
/dev/disk/by-id/mmc-NCard_0x25503bb5-part1 /OSS/Chip64          ntfs-3g    defaults,nofail                          0 0
/dev/disk/by-id/ata-WDC_WD10SPCX-55HWST0_WD-WX51AB3Y0134-part1 /OSS/Data1_Ext4      ext4       acl,user_xattr,nofail 1 2
/dev/disk/by-id/ata-WDC_WD10SPCX-55HWST0_WD-WX51AB3Y0134-part2 /OSS/Data2           ntfs-3g    defaults,nofail      0 0 

Dolphin shows the last two drives “not mounted” in the “Places” panel. When I click on the (nonmounted) drive shown there, it asks for su password to mount, but then reports this error - it shows the same error if I start up superuser Dolphin and click on a drive (except it does not ask for password):

An error occurred while accessing 'Data1_Ext4', the system responded: An unspecified error has occurred: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.

Then, after 20 seconds or so, the drive shows up mounted just fine. Except it takes longer than usual to load any folders. When I tried to preallocate a 80GB KVM partition on either of these two partitions, then it takes 30 hours or more (!!!) - this seems really odd.

Is this just something I did stupid with fstab, or a hardware issue (this is a HP17-e016dx - a rather newish design that may be configured strangely WRT opensuse).

Thank You!
Patti

Hi
So your trying to use an actual mounted partition for the KVM?

I use virt-manager (run as root user), then use the wizard to create a raw file at the size required for the VM, ram allocation, cpu’s to use, bridge device etc, then connect an iso image and install.

Sounds to me like your trying to use an actual disk partition as the hard drive for the VM?

Well, sort of. The KVM/Xen virtual machine creation applet wants a mounted partition to place the .vm file (the virtual disk file) upon. This is also what VirtualBox and VMware workstation (a few years back) want. I take it that is wrong for KVM?

I use virt-manager (run as root user), then use the wizard to create a raw file at the size required for the VM, ram allocation, cpu’s to use, bridge device etc, then connect an iso image and install.

I’m sort of confused by the term “raw file” - that isn’t used anywhere in the KDE applet to create a Xen or KVM virtual machine. It only asks if you want to “preallocate” the drive space.

Sounds to me like your trying to use an actual disk partition as the hard drive for the VM?

No, just navigating to a subdirectory in a mounted disk partition for the vm file to reside.

I wonder if this is a BIOS thing? I noticed that my machine had “legacy booting” enabled. Should that be UEFI only? Windows 8 seems to want only UEFI although it will tolerate legacy (until it has to repair itself). Will OS13.1 install with UEFI enabled and let GRUB2 handle booting without borking Win8.1?

If I read your post correctly,
I don’t think you’re posting about KVM, right? You’re perhaps trying to prepare your disks for use including for KVM?

You might want to fdisk your disks to determine if there is anything that needs to be repaired. As a general rule of thumb, although you might hope that there is no difference, creating partitions and formatting with an application different than an OS’s native app can sometimes cause problems. When you see little anomalies, you need to determine why they exist before they become big problems.

Also, when you post code, be clear what you’re posting.
I assume your the code snippet you posted is a gparted output.

TSU

Yes, virtual disk files should be located on mounted partitions like any other file to be accessed.
IMO Malcolm’s “raw file” is his own terminology. He really means an empty disk file (not to be confused with a raw format or raw access to a real physical file system).

IMO Malcolm misunderstood what you were posting about.

TSU

You need to convert the image from one to the other, for example;
http://cheznick.net/main/content/converting-a-virtual-machine-from-virtualbox-to-kvm

See above :wink:

Don’t think it’s BIOS related. Yes 13.1 will run in UEFI secure mode fine with 8.1, you just need to use the expert partitioner to set /boot/efi and to NOT format… You will probably have issues booting, and may have to use the F9 key to select openSUSE or Windows to boot, but there are some tweaks with the efibootmgr application that can be done, but would need further info once the UEFI install is completed.

So is the KDE applet using virt-manager, of is it a DE Tool? I only ever use virt-manager and vish (cli only)… Can you run;


su -
virt-manager

Is this the same tool seen from the KDE applet?

Thanks, yes a disk image but in ‘raw’ format and ends in <some_vm>.raw :wink:

As I noted, it sounds to me that Michelle is having a more fundamental problem which needs to be resolved before doing any kind of disk operations (like converting diskfile images).

Something else to consider…
You should generally choose to place disk image storage on a partition that is mounted on boot.

Partitions which are mounted by the Desktop like how is described in the OP can have issues… If the partition is mounted, then images on those partitions may not be available until after the Desktop has loaded and maybe even later if they have to be mounted by Dolphin (as a Place).

So, I’d highly recommend you store your images only on / or /home/ on a typical system unless you know what you are doing.

TSU

Finger-fehler (for you chessnicks).
Sorry, didn’t mean “fdisk” – Of course I meant fschk.

TSU

OK, so I am just now going through the process creating a VM on my opteron box. It’s the Start Menu > System > Virtualization > Create Virtual Machines for Xen and KVM applet. I created a new file container on my hard drive, and it is “preallocating” space at about 5 GB per minute - which is reasonable for a standard SATA hard drive on an NTFS formatted disk. I wonder why it would only do about 100K per minute on my laptop? (that’s what made me think there was a problem) Then there’s also the weird errors it throws… :\

I guess I need to fiddle around with fsck and make sure there’re no problems, then figure out why those two partitions on my second hard drive don’t show up as already mounted after booting opensuse. This is a very new HP Pavilion and they may have messed with the hardware. I can’t get Linux Mint live to boot on this machine, which seems odd.

Thanks, Will do.

I’ve noticed that Opensuse no longer “forces a disk check” during boot every month or so. I used to rely on that.

Not openSUSE “forced” this, that’s a feature of the filesystem.
For ext2/ext3/ext4 you can configure this with “tune2fs”, for reiserfs with “reiserfstune”. Have a look at the man pages.

Hi
Just a query as I don’t use KDE or ntfs (but I might have to whack a ntfs formatted disk into my system), but on my system it takes about 2 seconds to ‘allocate’ space for a vm on a xfs disk (well I do run bcache and SATAIII)? What does it have to preallocate on ntfs?

Glad to hear your Operon system is behaving as expected (and consistent with what Malcolm later posted).

When something is not performing as expected (on your laptop), it’s worth looking into instead of ignoring hoping it’ll go away. I doubt very many problems resolve themselves without attention.

The usual stuff…

  • Run fschk on your file system to verify a catastrophe isn’t around the corner.
  • If you’re running KDE, there is a 3rd party utility I highly recommend to monitor disk I/O in real time (It’s in my SSD slide deck, but I’ll post specific info if this applies to you).
  • Run top (and/or any of the various other top variants) to see what is happening in real time.
  • Run free to inspect your memory usage. See my article how to use and read free User:Tsu2/free tool - openSUSE Wiki
    Of course, memory exhaustion leads to disk swapping and a freezing system. And, note the command I describe which wipes your memory buffers free when you are moving from one set of intensive work to another (alternative is a reboot).

Virtualization can be resource intensive. Clear the decks of all other work and either clear memory buffers or reboot if you want maximum available resources for intensive operations.

TSU

So far, concerning the disk, the only reproducible issues are (1) the disks don’t appear to be mounted following booting (they always used to appear with the mounted icon in “Places” in Dolphin after I boot), and (2) when I try to enter either of the partitions on that drive, I get this error:

An error occurred while accessing 'Data1_Ext4', the system responded: An unspecified 
error has occurred: Did not receive a reply. Possible causes include: the remote application did 
not send a reply, the message bus security policy blocked the reply, the reply timeout expired, 
or the network connection was broken.

My fstab looks like this, so they should be mounted after boot, right? (it’s the WD drive)

/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part6 swap                 swap       defaults              0 0
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part7 /                    ext4       acl,user_xattr        1 1
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part2 /boot/efi            vfat       umask=0002,utf8=true  0 0
/dev/disk/by-id/ata-HGST_HTS541075A9E680_JD13021X06UH4K-part8 /home                ext4       acl,user_xattr        1 2
/dev/disk/by-id/mmc-NCard_0x25503bb5-part1 /OSS/Chip64          ntfs-3g    defaults,nofail                          0 0
/dev/disk/by-id/ata-WDC_WD10SPCX-55HWST0_WD-WX51AB3Y0134-part1 /OSS/Data1_Ext4      ext4       acl,user_xattr,nofail 1 2
/dev/disk/by-id/ata-WDC_WD10SPCX-55HWST0_WD-WX51AB3Y0134-part2 /OSS/Data2           ntfs-3g    defaults,nofail      0 0

Oh, well I never see it any more during boot time - say since 12.x or thereabouts. I thought maybe it had been switched off by default…

Can you share the correct argument to find disks on opensuse vanilla? Thank You,

patti@linux-l8th:~> tune2fs -l
Absolute path to 'tune2fs' is '/usr/sbin/tune2fs', so running it may require superuser privileges (eg. root).
patti@linux-l8th:~> su
Password: 
linux-l8th:/home/patti # tune2fs -l
tune2fs 1.42.8 (20-Jun-2013)
Usage: tune2fs -c max_mounts_count] -e errors_behavior] -g group]
        -i interval[d|m|w]] -j] -J journal_options] -l]
        -m reserved_blocks_percent] -o ^]mount_options,...]] -p mmp_update_interval]
        -r reserved_blocks_count] -u user] -C mount_count] -L volume_label]
        -M last_mounted_dir] -O ^]feature,...]]
        -E extended-option,...]] -T last_check_time] -U UUID]
         -I new_inode_size ] device
linux-l8th:/home/patti # tune2fs -l sda
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: No such file or directory while trying to open sda
Couldn't find valid filesystem superblock.
linux-l8th:/home/patti # tune2fs -l /OSS/Data2
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Attempt to read block from filesystem resulted in short read while trying to open /OSS/Data2
Couldn't find valid filesystem superblock.
linux-l8th:/home/patti # tune2fs -l /OSS/Data1_Ext4
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Attempt to read block from filesystem resulted in short read while trying to open /OSS/Data1_Ext4
Couldn't find valid filesystem superblock.
linux-l8th:/home/patti # tune2fs -l /dev/sda1
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Bad magic number in super-block while trying to open /dev/sda1
Couldn't find valid filesystem superblock.
linux-l8th:/home/patti # tune2fs -l /dev/sda2
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Bad magic number in super-block while trying to open /dev/sda2
Couldn't find valid filesystem superblock.
linux-l8th:/home/patti # 

Gollee-ee-ee!

You have one of those keyboards that keep jumping around when you try to type, too? :open_mouth:

As you specified the “nofail” mount option, it need not necessarily be mounted. If an error occured when mounting it, the system would still boot.
Run “mount” to see whether it’s mounted.
Try to mount one of them manually and see if there’s an error.

Something like this should show the state (and possible errors) as well:

sudo systemctl status /OSS/Data1_Ext4

Probably the defaults have changed, yes. For ext4 that is. My reiserfs partition I have set up 11 years ago (fresh installation of SuSE 8.1 back then) never did this at all.

Can you share the correct argument to find disks on opensuse vanilla? Thank You,

What do you mean with “find disks”?
Commands like “fdisk -l” or “lsblk -f” list all your disks/partitions. (run them as root)

To set up automatic checking for your Data1_Ext4 partition, this would enable a forced check once a month:

tune2fs  -m1 /dev/disk/by-id/ata-WDC_WD10SPCX-55HWST0_WD-WX51AB3Y0134-part1[/QUOTE]


linux-l8th:/home/patti # tune2fs -l sda
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: No such file or directory while trying to open sda
Couldn’t find valid filesystem superblock.


First, it would be /dev/sda, not just sda.
Second, you have to specify the _partition_, not the disk.


linux-l8th:/home/patti # tune2fs -l /OSS/Data2
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Attempt to read block from filesystem resulted in short read while trying to open /OSS/Data2
Couldn’t find valid filesystem superblock.
linux-l8th:/home/patti # tune2fs -l /OSS/Data1_Ext4
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Attempt to read block from filesystem resulted in short read while trying to open /OSS/Data1_Ext4
Couldn’t find valid filesystem superblock.


Again, you have to specify the device file of the partition, not the mount point.
Something like /dev/sdb1.


linux-l8th:/home/patti # tune2fs -l /dev/sda1
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Bad magic number in super-block while trying to open /dev/sda1
Couldn’t find valid filesystem superblock.


This is more correct, but apparently /dev/sda1 doesn't contain an extX file system.
I suppose your WD drive is /dev/sdb, so the correct partition would be /dev/sdb1.


linux-l8th:/home/patti # tune2fs -l /dev/sda2
tune2fs 1.42.8 (20-Jun-2013)
tune2fs: Bad magic number in super-block while trying to open /dev/sda2
Couldn’t find valid filesystem superblock.
linux-l8th:/home/patti #


/dev/sda2 doesn't contain an ext file system either.
According to your fstab, /dev/sda2 would either be /boot/efi (which is FAT), or /OSS/Data2 (which is NTFS).
More likely the first one.

There was a time, probably 12.x or thereabouts, when the output of the fsck at boot time was not shown. I vaguely remember adding -C0 to one of the scripts in /etc/init.d… Probably had something to do with the switch to systemd in 12.1. (-C0 is an argument to fsck to show its output)

After a bit of google-ing I came up with this: man systemd-fsck@.service

[noparse]:o)[/noparse] So just feed fsck.mode=force to the kernel command line at boot, sit back and perhaps enjoy a sip your coffee (in the old days you could make a pot of coffee and drink a cup (pot?) as well). (Only do this if you know what you are doing!)

Oh, in case you’re wondering: try (as root): grep fsck /var/log/boot.log | less (13.1) or journalctl | grep fsck | less (13.2). That will show you whether fsck happens or not (on my systems 13.2 as well as 13.1: yes).

Kind regards,

Leen

LOL! Indeed! I think you hit the nail on the head. That is exactly how I’ve felt this last week!! :shame:

I think whatever neurons I had which knew anything about fstab died off with the last pint of homemade ale… I guess it’s because I have had several systems all borking at once (Win8 and my laptop are driving me crazy), in addition to my “day job.” I took a time-out today after I got done fighting some fires (as in, fires in the fire station…), fiddled with fstab, and got at least my Opteron system’s file systems all mounting and permissioned as expected (mostly with “auto,” and “defaults”). Now I’m trying KVM install, using the KDE Virtual Machine Manager. We will see how that goes.

While googling around about fstab, I found some promising details about KVM. Yes, it does look very good.

https://wiki.openstack.org/wiki/LibvirtXMLCPUModel

“host-passthrough” - this causes libvirt to tell KVM to passthrough the host CPU with no modifications. The difference to host-model, instead of just matching feature flags, every last detail of the host CPU is matched. This gives absolutely best performance, and can be important to some apps which check low level CPU details, but it comes at a cost wrt migration.