LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 11-29-2013, 08:03 PM   #1
skush
LQ Newbie
 
Registered: Aug 2013
Distribution: Ubuntu (At home), Slackware (On server), Redhat (At Work).
Posts: 23

Rep: Reputation: Disabled
Slackware 14.1 in MS Hyper-V


I'm having trouble with Slackware 14.1 in Hyper-V, it gets through the installer just fine, and reboots, and LILO works fine. After selecting it from the LILO menu however, it goes through some of the regular boot procedure (Loading Linux…….., etc.) then it goes to a kernel panic. Does anyone else have a successful installation on Hyper-V? Should I not be using the default kernel? Do I need to give certain kernel parameters when it asks? The hypervisor is running Windows Server 2008. I can post an image of the panic the next time I have access to the machine if necessary.

Thanks

Last edited by skush; 11-29-2013 at 08:05 PM.
 
Old 11-30-2013, 11:05 AM   #2
tux_dude
Member
 
Registered: Dec 2008
Distribution: Slackware64 Current
Posts: 249

Rep: Reputation: 34
Are you using initrd and if yes, what options did you specify?
 
Old 11-30-2013, 11:48 AM   #3
mostlyharmless
Senior Member
 
Registered: Jan 2008
Distribution: Arch/Slackware/Knoppix
Posts: 1,761
Blog Entries: 14

Rep: Reputation: 267Reputation: 267Reputation: 267
There's a hyper-v compatibility option for the kernel compile options which is not selected by default. Methinks you need to recompile the kernel.
 
Old 12-01-2013, 05:54 PM   #4
CeeWave
LQ Newbie
 
Registered: Dec 2013
Posts: 3

Rep: Reputation: Disabled
I have recently installed a Slackware64 guest virtual machine in a Windows 8 host with Hyper-V. I ran into similar problems finding the root device when booting either the huge or generic 3.10.17 kernels. I was able to successfully boot the virtual machine, with the stock kernels, by using an initrd image that included the hv_vmbus and hv_storvsc modules. These modules are in addition to any filesystem modules that you would normally require for use when booting with the generic kernel.
 
1 members found this post helpful.
Old 12-02-2013, 08:44 PM   #5
skush
LQ Newbie
 
Registered: Aug 2013
Distribution: Ubuntu (At home), Slackware (On server), Redhat (At Work).
Posts: 23

Original Poster
Rep: Reputation: Disabled
initrd

Thanks for the replies. CeeWave, as I have zero experience with initrd, could you explain the process you went through a little bit more. Thanks.
 
Old 12-03-2013, 08:14 AM   #6
CeeWave
LQ Newbie
 
Registered: Dec 2013
Posts: 3

Rep: Reputation: Disabled
This may not be the cleanest method, and I'm recalling the process mostly from memory, but the basic steps I used to fix this was to:

1) Boot off of the installation disc
2) Mount the partition holding the root partition on /mnt, e.g.:
Code:
mount -t ext4 /dev/sda1 /mnt
3) Enter an interactive shell with the mounted partition as root directory:
Code:
chroot /mnt
4) Change directory to /boot and review the file README.initrd for the official description of the initrd building process and usage. You should also review the man page for the mkinitrd command.
5) Create the initrd.gz image:
Code:
mkinitrd -c -f ext4 -r /dev/sda1 -m hv_vmbus:hv_storvsc:mbcache:jbd2:ext4 -u -o /boot/initrd.gz
6) Follow the instructions in /boot/README.initrd to edit /etc/lilo.conf and run lilo to set up and install the boot loader.

If you used a root filesystem other than ext4 or a partition other than /dev/sda1, you'll need to adjust the commands in steps #2 and #5. The hv_vmbus and hv_storvsc modules were the key to getting it working under Hyper-V while the mbcache, jbd2, and ext4 modules were required to use the generic kernel with the ext4 root filesystem. You can also try using the /usr/share/mkinitrd/mkinitrd_command_generator.sh script to automatically generate the command appropriate for you to use in step #5.
 
4 members found this post helpful.
Old 12-03-2013, 11:27 PM   #7
skush
LQ Newbie
 
Registered: Aug 2013
Distribution: Ubuntu (At home), Slackware (On server), Redhat (At Work).
Posts: 23

Original Poster
Rep: Reputation: Disabled
Thanks

Your method worked flawlessly, and in reading that file, I gained a basic understanding of initrd. Thank you very much.
 
Old 12-03-2013, 11:53 PM   #8
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-Current
Posts: 6,378
Blog Entries: 15

Rep: Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953Reputation: 1953
Alternatively you can also use the Huge kernel which doesn't require an initrd.gz.
 
Old 12-04-2013, 08:16 AM   #9
CeeWave
LQ Newbie
 
Registered: Dec 2013
Posts: 3

Rep: Reputation: Disabled
skush, You're welcome, I'm glad you were able to to get it to work.

ReaperX7, using the Huge kernel often avoids requiring an initrd.gz. Unfortunately, by design or oversight, the Hyper-V support is provided by modules in both the Huge and Generic 3.10.17 kernels.

Huge:
Code:
bash-4.2# grep HYPERV /boot/config-huge-3.10.17
CONFIG_HYPERVISOR_GUEST=y
# CONFIG_SYS_HYPERVISOR is not set
CONFIG_HYPERV_STORAGE=m
CONFIG_HYPERV_NET=m
# CONFIG_FB_HYPERV is not set
CONFIG_HID_HYPERV_MOUSE=m
CONFIG_HYPERV=m
CONFIG_HYPERV_UTILS=m
CONFIG_HYPERV_BALLOON=m
and Generic:
Code:
bash-4.2# grep HYPERV /boot/config-generic-3.10.17
CONFIG_HYPERVISOR_GUEST=y
# CONFIG_SYS_HYPERVISOR is not set
CONFIG_HYPERV_STORAGE=m
CONFIG_HYPERV_NET=m
# CONFIG_FB_HYPERV is not set
CONFIG_HID_HYPERV_MOUSE=m
CONFIG_HYPERV=m
CONFIG_HYPERV_UTILS=m
CONFIG_HYPERV_BALLOON=m
necessitating the use of an initrd image with either kernel.
 
2 members found this post helpful.
Old 07-01-2016, 10:45 PM   #10
Strykar
Member
 
Registered: Apr 2008
Distribution: Slackware64, OpenBSD, Debian
Posts: 36

Rep: Reputation: 4
I use ext4 and even on 14.2 I use
Quote:
mkinitrd -c -f ext4 -r /dev/sda1 -m hv_vmbus:hv_storvsc -u -o /boot/initrd.gz
I wish I'd commented my 14.1's (kernel 4.0.1) lilo.conf because I found I would use
Quote:
append="vt.default_utf8=0 raid=noautodetect hyperv_clocksource"
This is from
Quote:
# ls -l /sys/devices/system/clocksource/clocksource0/
total 0
-r--r--r-- 1 root root 4096 Jul 2 08:12 available_clocksource
-rw-r--r-- 1 root root 4096 Jul 2 08:12 current_clocksource
drwxr-xr-x 2 root root 0 Jul 2 08:12 power/
lrwxrwxrwx 1 root root 0 Jul 2 08:12 subsystem -> ../../../../bus/clocksource/
-rw-r--r-- 1 root root 4096 Jul 2 2016 uevent
--w------- 1 root root 4096 Jul 2 08:12 unbind_clocksource
Telling lilo the clocksource isn't required, I tested it.
On 14.2 hyperv_clocksource_tsc_page is used by default.
 
Old 07-02-2016, 01:41 AM   #11
a4z
Senior Member
 
Registered: Feb 2009
Posts: 1,248

Rep: Reputation: 533Reputation: 533Reputation: 533Reputation: 533Reputation: 533Reputation: 533
Hej Strykar, thanks for the info

what does this mean?
Quote:
Originally Posted by Strykar View Post
I wish I'd commented my 14.1's (kernel 4.0.1) lilo.conf because I found I would use

This is from
Telling lilo the clocksource isn't required, I tested it.

On 14.2 hyperv_clocksource_tsc_page is used by default.
no extra parameter for lilo?


I wish this additional work would not be required and Slackware could work on Hyper-V out of the box.
I understand that most here do not need this, and therefor do not know/understand, but for certain development work on windows you need to use Hyper-V what disables VMWare (or limits it to 1 32bit CPU), switching between Hyper-V on of on the fly is not possible.

This makes people of course using something else, understandable, even I hate to fiddle around and fix this since my primary interests are getting dev jobs done, not fixing pre loaded modules, a stupid work someone has to do over and over again for each installation.
 
Old 07-02-2016, 02:05 AM   #12
Strykar
Member
 
Registered: Apr 2008
Distribution: Slackware64, OpenBSD, Debian
Posts: 36

Rep: Reputation: 4
Quote:
Originally Posted by a4z View Post
Hej Strykar, thanks for the info

what does this mean?


no extra parameter for lilo?


I wish this additional work would not be required and Slackware could work on Hyper-V out of the box.
Hi! It means to get Hyper-V support without the huge.s kernel, you need just 2 modules - hv_vmbus and hv_storvsc

I'd specified clocksource because of a kernel panic in the past.
No extra parameters are required in lilo.conf

The issue why initrd is required is due to the way Hyper-V is bundled in the kernel.
It seems unlikely to get Slackware working out of the box as a Hyper-V guest unless kernel.org changes the way Hyper-V is bundled.
Just follow CeeWave's instructions above when you install and setup the initrd right after completing the install before rebooting.

I often get trolled for using Slackware under Hyper-V, but they have 4 datacenters in India which are important to me and facts speak for themselves - http://www.geekwire.com/2016/azure-r...tanley-survey/

Last edited by Strykar; 07-02-2016 at 02:13 AM.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Slackware on MS Hyper-V spongetron Slackware 14 10-16-2014 11:26 AM
Virtualization by Hyper-V Hector2000 Linux - Virtualization and Cloud 1 06-06-2012 08:09 PM
Ubuntu 9.10 In Hyper-V zdunham Linux - Virtualization and Cloud 1 12-11-2009 01:22 PM
hyper terminal swift2008 Programming 3 11-11-2008 04:33 AM
hyper mplayer linuxhippy Fedora 2 01-28-2007 08:22 AM


All times are GMT -5. The time now is 02:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration