LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - Installation
User Name
Password
Slackware - Installation This forum is for the discussion of installation issues with Slackware.

Notices


Reply
  Search this Thread
Old 05-21-2017, 12:10 PM   #31
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (current), FreeBSD, Win10, It varies
Posts: 9,951

Rep: Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146

like he said that I just forgot or thought that part was ironed out. Huge does not use a img for one and yes use UUID because of the naming scheme that Linux uses for naming the drives on spin up. which ever spins up first gets the letter a so on and so fourth.

as you see here with huge in slacks grub2 cfg it does not use the initrd.gz at all -

Code:
menuentry 'Slackware-14.2 GNU/Linux' --class slackware-14.2 --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-218cff91-944d-454f-98ac-b1d162326e95' {
        load_video
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd0,msdos6'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos6 --hint-efi=hd0,msdos6 --hint-baremetal=ahci0,msdos6  218cff91-944d-454f-98ac-b1d162326e95
        else
          search --no-floppy --fs-uuid --set=root 218cff91-944d-454f-98ac-b1d162326e95
        fi
        echo    'Loading Linux 4.4.38 ...'
        linux   /boot/vmlinuz-huge-4.4.38 root=/dev/sda6 ro  
}
your fstab should look something similar to this
Code:
userx%slackwhere ⚡ hd ⚡> cat etc/fstab
UUID=8874f530-39a7-4bba-b71c-cc3270cdd826 / ext4 defaults 0 1
UUID=06c24029-5acf-4981-aeda-b998cdff7a07 /home ext4 defaults 0 2
within the Slackware grub cgf and fstab the UUID have to match. and NO initrd.gz at all if using huge which is not a bad thing.
 
Old 05-21-2017, 10:59 PM   #32
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,316

Rep: Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023
Yeah, UUIDs need to be used in the bootloader for your situation. Unfortunately, I have no experience with grub, so I have no idea how to force it to use UUIDs for all entries. I know with lilo, you just edit the /etc/lilo.conf file and replace the /dev/sd* entries with UUIDs and then you rewrite the bootloader and go. I do imagine you could edit that file manually, however, it would probably be ideal to figure out how to get the script to do it automatically. Hopefully some google searches can bring up the needed info for success.
 
Old 05-22-2017, 07:30 AM   #33
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (current), FreeBSD, Win10, It varies
Posts: 9,951

Rep: Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146
@bassmadrigal and OP I don't pay much attention to how grub2 does things. but mine just uses UUID even Slack does, it is the fstab for sure that needs to get changed because it still uses old school /dev/sdxx
It is just a matter of insuring that they UUID match.

even if he is using the other Linux grub to boot slack

40_custom in /etc/grub.d if needed to add a custom grub menu entry to get it to use UUID
If using the other Linux then put slacks grub menu in that 40_custom.

I got a dual boot, and that is what I do. I just copy the first menu entry for Void in its own grub.cfg then paste it into the 40_custom in Slacks 40_custom and/or visa versa. only because it does not pick up the distro name, and somewhere in all of that it was not picking up VOID.

quick fix, copy the others dirtro grub.cfg 1st menu in that config file and paste it into the others 40_custom. all of the settings are already written out to work. only draw back is kernel upgrades, which is another quick fix. Just mod the 40_custom and change version numbers and update. done.

The only thing I do not have understanding on is what is the difference between how that VBox vs the standard USB Port is booting the same distro. Other than NOT using UUID's it is going to reference the PORT differently due to first partition/ hdd spin up

if one has more than one thing plugged into USB ports when booting then they are going to get addressed differently. One then has to figure out which USB Ports take precedence over the others- there is an order to them as well.
 
Old 05-22-2017, 10:00 AM   #34
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,316

Rep: Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023
Quote:
Originally Posted by BW-userx View Post
like he said that I just forgot or thought that part was ironed out. Huge does not use a img for one and yes use UUID because of the naming scheme that Linux uses for naming the drives on spin up. which ever spins up first gets the letter a so on and so fourth.
Using UUIDs in your bootloader should require an initrd. If you don't use an initrd, you should get a kernel panic, because the system doesn't map the UUIDs to the devices without an initrd. You can get around this using PartUUIDs, however, I don't know how well grub plays with either of those, but lilo has full support for them. All of this is covered in that SlackDocs article.

Also, even if OP weren't using UUIDs, I believe booting off a USB drive also requires an initrd.

Quote:
Originally Posted by BW-userx View Post
@bassmadrigal and OP I don't pay much attention to how grub2 does things. but mine just uses UUID even Slack does, it is the fstab for sure that needs to get changed because it still uses old school /dev/sdxx
If you're using UUIDs due to drives designations changing, switching only your fstab isn't enough. You have to do your fstab and bootloader (grub or lilo).
 
Old 05-22-2017, 10:00 AM   #35
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
Well, after numerous attempts, coding UUIDs everywhere I could (fstab, grub) I still can not get slackware to boot from the external hdd when attahced to a PC (or laptop). The error I am getting is still

"mount: can't find /mnt in /etc/fstab
ERROR: no /sbin/init found on rootdev (or not mounted)".

This was addressed in the following thread:

http://www.linuxquestions.org/questi...ab-4175583059/

however, doing what was suggested there (for 14.1) did not work for me (14.2). I use the huge kernel instead of generic but still the same issues. I have even built the initrd to be used with the huge kernel (I know it is not recommended), I got the duplicate module errors but still no success in booting directly the pc.

Now, the strange thing is that none of these errors appear when I attach the exhternal hdd as a raw device to virtual box. I even have made two configurations for slackware on 40_custom, one where the hdd is defined as hd0 for the case when external disk is attached to virtual box as a raw device and another on as hd1 when it is attached to the laptop (or PC). Both configurations work under vbox, none of these work when laptop boots from this disk. Also strangely, many other distros I tried work in both ways without problem (either within vbox with hdd attached as raw device or directly on the pc). Latest try was with peppermint and it worked just fine.

I have to admint that many of the previous errors were due to not properly defined /dev/sdX and hdX values on grub and fstab (not properly paired) mixing up things. I understood that when this disk is given as raw device to vbox, it gets the value of /sda and hd0 accordingly for the vbox since it is the only disk it sees. But when it is just attached to the laptop (or attached as usb device to vbox and not as raw device) it takes the value of /sdb (or sdc etc accoerding the other usb ports) and hd1 or 2 etc. So one has to be very carefull when coding fstabs, grubs, etc (as BW-userx mentions above).

Thing is that after so many tries I believe I have found the correct combination of /dev/sdX and hdX (actually I am using uuids on grub and fstab), but I am still getting the above mentioned message.

Anyway, it was a fantastic knowledge path till now, and I intend to keep walking it. I have even had a look at the init script rc.S to find out why (and where) the hell these messages can occur, in which point of the boot process.

Many thanks to all those who respond and tried to help me.

Regards, Apostolos.

UPDATE: Just saw bassmadrigal's latest post. This explains a lot of my earlier failed attempts. But now I am using huge kernel with initrd on both scenarios (hdd as hd0 and hd1). I use another linux disto to build grub (though its 40_custom file).

Last edited by apmount; 05-22-2017 at 10:05 AM.
 
Old 05-22-2017, 10:22 AM   #36
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (current), FreeBSD, Win10, It varies
Posts: 9,951

Rep: Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146
Quote:
Originally Posted by bassmadrigal View Post
Using UUIDs in your bootloader should require an initrd. If you don't use an initrd, you should get a kernel panic, because the system doesn't map the UUIDs to the devices without an initrd. You can get around this using PartUUIDs, however, I don't know how well grub plays with either of those, but lilo has full support for them. All of this is covered in that SlackDocs article.

Also, even if OP weren't using UUIDs, I believe booting off a USB drive also requires an initrd.
my boot in slack is this.

Code:
userx%voider ⚡ ~ ⚡> ls /mnt/boot
README.initrd              config                 inside.dat    vmlinuz
System.map                 config-generic-4.4.38  map           vmlinuz-generic
System.map-generic-4.4.38  config-huge-4.4.38     onlyblue.bmp  vmlinuz-generic-4.4.38
System.map-huge-4.4.38     elilo-ia32.efi         onlyblue.dat  vmlinuz-huge
boot.0800                  elilo-x86_64.efi       slack.bmp     vmlinuz-huge-4.4.38
boot_message.txt           grub                   tuxlogo.bmp
coffee.dat                 inside.bmp             tuxlogo.dat
userx%voider ⚡ ~ ⚡>
I am using huge I have no initrd in there or in my grub.cfg as posted in 31
it is just using the vmlinuz-huge-4.4.38 - if that is the initrd by a different name then yeah. Just let Slackware set that part up for one during grub-install - update grub


then all is left to do is changing fstab to reflect same UUID's

Unless he screwed up his soft links to the kernel because he was playing around with the generic kernal without setting that one up properly first.


Quote:
If you're using UUIDs due to drives designations changing, switching only your fstab isn't enough. You have to do your fstab and bootloader (grub or lilo).
that is what we've been saying. I just stated that grub2 slack automaticlly adds UUID so fstab is needed to match UUID


booting off USB Port - needs eternal hdd to have grub or whatever boot loader installed onto it. I just use whatever grub installs and sets up within the grub.cfg is is only the fstab that needs to be looked at - that has to be the right /dev/sdxx whatever or UUID has to match whatever is in the grub.cfg

it is not that hard, but he is using two separate methods of booting this hdd -through VBox by a USB Port and straight through via USB Point (no Vbox) so for some reason it works with VBox but does not like just USB Port.

the means in which he is booting - they have to match in both methods

Last edited by BW-userx; 05-22-2017 at 10:30 AM.
 
Old 05-22-2017, 12:38 PM   #37
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,316

Rep: Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023
Quote:
Originally Posted by BW-userx View Post
I am using huge I have no initrd in there or in my grub.cfg as posted in 31
I don't know. Maybe it is because your grub.cfg has this line "set root='hd0,msdos6'" setting an actual location. All I know, is in all my research and testing, the huge kernel cannot boot a drive using UUIDs without an initrd. That's what all the various wikis I found stated as well. Maybe grub has found some way around this, or maybe grub is referencing them differently and not actually using UUIDs.

@apmount, maybe it would be worth switching to lilo. I am familiar with that and could help you get it set up to boot both systems. But before we do that, can you post the output of the following commands? Just so we can make sure we're on the same page.

Code:
ls -la /dev/disk/by-uuid/
cat /etc/fstab
cat /boot/grub/grub.cfg
cat /etc/lilo.conf
lsblk -o NAME,RM,SIZE,MOUNTPOINT,UUID
 
Old 05-22-2017, 12:59 PM   #38
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
Code:
bash-4.3$ ls -la /dev/disk/by-uuid/
total 0
drwxr-xr-x 2 root root 100 May 22  2017 .
drwxr-xr-x 4 root root  80 May 22  2017 ..
lrwxrwxrwx 1 root root  10 May 22 17:47 03beec21-deef-4dde-ad40-824900e79182 -> ../../sda5
lrwxrwxrwx 1 root root  10 May 22 17:47 98ced7a0-7711-4a00-b5db-981f0bc543c7 -> ../../sda1
lrwxrwxrwx 1 root root  10 May 22 17:47 f059da3a-3875-45b2-a4bf-e0c8c972bee3 -> ../../sda2

root@apost-slack:~# cat /etc/fstab
#/dev/sdb2 
UUID=f059da3a-3875-45b2-a4bf-e0c8c972bee3 swap swap defaults 0 0
#/dev/sdb1 
UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 /    ext4 defaults 1 1
#/dev/cdrom      /mnt/cdrom       auto        noauto,owner,ro,comment=x-gvfs-show 0   0
/dev/fd0         /mnt/floppy      auto        noauto,owner     0   0
devpts           /dev/pts         devpts      gid=5,mode=620   0   0
proc             /proc            proc        defaults         0   0
tmpfs            /dev/shm         tmpfs       defaults         0   0

root@apost-slack:~# cat /etc/lilo.conf
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/sdb1

#compact        # faster, but won't work on all systems.

# Boot BMP Image.
# Bitmap in BMP format: 640x480x8
  bitmap = /boot/slack.bmp
# Menu colors (foreground, background, shadow, highlighted
# foreground, highlighted background, highlighted shadow):
  bmp-colors = 255,0,255,0,255,0
# Location of the option table: location x, location y, number of
# columns, lines per column (max 15), "spill" (this is how many
# entries must be in the first column before the next begins to
# be used.  We don't specify it here, as there's just one column.
  bmp-table = 60,6,1,16
# Timer location x, timer location y, foreground color,
# background color, shadow color.
  bmp-timer = 65,27,0,255
# Standard menu.
# Or, you can comment out the bitmap menu above and
# use a boot message with the standard menu:
#message = /boot/boot_message.txt

# Append any additional kernel parameters:
append=" vt.default_utf8=0"
prompt
timeout = 50
# Normal VGA console
vga = normal
# Ask for video mode at boot (time out to normal in 30s)
#vga = ask
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# ramdisk = 0     # paranoia setting
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = /dev/sdb1
  label = Slack
  read-only  # Partitions should be mounted read-only for checking
# Linux bootable partition config ends


root@apost-slack:~# lsblk -o NAME,RM,SIZE,MOUNTPOINT,UUID
NAME   RM   SIZE MOUNTPOINT UUID
sda     0 465.8G            
|-sda1  0    50G /          98ced7a0-7711-4a00-b5db-981f0bc543c7
|-sda2  0     4G [SWAP]     f059da3a-3875-45b2-a4bf-e0c8c972bee3
|-sda3  0     1K            
`-sda5  0    50G            03beec21-deef-4dde-ad40-824900e79182
sr0     1  1024M
As for grub, currently I use the one by Peppermint:

Code:
root@apost-slack:/mnt/boot/grub# cat grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
  set have_grubenv=true
  load_env
fi
if [ "${next_entry}" ] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}
function recordfail {
  set recordfail=1
  if [ -n "${have_grubenv}" ]; then if [ -z "${boot_once}" ]; then save_env recordfail; fi; fi
}
function load_video {
  if [ x$feature_all_video_module = xy ]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

if [ x$feature_default_font_path = xy ] ; then
   font=unicode
else
insmod part_msdos
insmod ext2
set root='hd0,msdos5'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
else
  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
fi
    font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=en_US
  insmod gettext
fi
terminal_output gfxterm
if [ "${recordfail}" = 1 ] ; then
  set timeout=30
else
  if [ x$feature_timeout_style = xy ] ; then
    set timeout_style=menu
    set timeout=10
  # Fallback normal timeout code in case the timeout_style feature is
  # unavailable.
  else
    set timeout=10
  fi
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
insmod part_msdos
insmod ext2
set root='hd0,msdos5'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
else
  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
fi
insmod png
if background_image /boot/grub/grub-background.png; then
  true
else
  set menu_color_normal=light-gray/black
  set menu_color_highlight=white/red
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
	set gfxpayload="${1}"
	if [ "${1}" = "keep" ]; then
		set vt_handoff=vt.handoff=7
	else
		set vt_handoff=
	fi
}
if [ "${recordfail}" != 1 ]; then
  if [ -e ${prefix}/gfxblacklist.txt ]; then
    if hwmatch ${prefix}/gfxblacklist.txt 3; then
      if [ ${match} = 0 ]; then
        set linux_gfx_mode=keep
      else
        set linux_gfx_mode=text
      fi
    else
      set linux_gfx_mode=text
    fi
  else
    set linux_gfx_mode=keep
  fi
else
  set linux_gfx_mode=text
fi
export linux_gfx_mode
menuentry 'Peppermint GNU/Linux' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-03beec21-deef-4dde-ad40-824900e79182' {
	recordfail
	load_video
	gfxmode $linux_gfx_mode
	insmod gzio
	if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos5'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
	else
	  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
	fi
        linux	/boot/vmlinuz-4.4.0-66-generic root=UUID=03beec21-deef-4dde-ad40-824900e79182 ro  quiet splash $vt_handoff
	initrd	/boot/initrd.img-4.4.0-66-generic
}
submenu 'Advanced options for Peppermint GNU/Linux' $menuentry_id_option 'gnulinux-advanced-03beec21-deef-4dde-ad40-824900e79182' {
	menuentry 'Peppermint GNU/Linux, with Linux 4.4.0-66-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-66-generic-advanced-03beec21-deef-4dde-ad40-824900e79182' {
		recordfail
		load_video
		gfxmode $linux_gfx_mode
		insmod gzio
		if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
		else
		  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
		fi
		echo	'Loading Linux 4.4.0-66-generic ...'
	        linux	/boot/vmlinuz-4.4.0-66-generic root=UUID=03beec21-deef-4dde-ad40-824900e79182 ro  quiet splash $vt_handoff
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.img-4.4.0-66-generic
	}
	menuentry 'Peppermint GNU/Linux, with Linux 4.4.0-66-generic (upstart)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-66-generic-init-upstart-03beec21-deef-4dde-ad40-824900e79182' {
		recordfail
		load_video
		gfxmode $linux_gfx_mode
		insmod gzio
		if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
		else
		  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
		fi
		echo	'Loading Linux 4.4.0-66-generic ...'
	        linux	/boot/vmlinuz-4.4.0-66-generic root=UUID=03beec21-deef-4dde-ad40-824900e79182 ro  quiet splash $vt_handoff init=/sbin/upstart
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.img-4.4.0-66-generic
	}
	menuentry 'Peppermint GNU/Linux, with Linux 4.4.0-66-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-66-generic-recovery-03beec21-deef-4dde-ad40-824900e79182' {
		recordfail
		load_video
		insmod gzio
		if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
		else
		  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
		fi
		echo	'Loading Linux 4.4.0-66-generic ...'
	        linux	/boot/vmlinuz-4.4.0-66-generic root=UUID=03beec21-deef-4dde-ad40-824900e79182 ro recovery nomodeset 
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.img-4.4.0-66-generic
	}
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###

### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry 'Memory test (memtest86+)' {
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos5'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
	else
	  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
	fi
	knetbsd	/boot/memtest86+.elf
}
menuentry 'Memory test (memtest86+, serial console 115200)' {
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos5'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  03beec21-deef-4dde-ad40-824900e79182
	else
	  search --no-floppy --fs-uuid --set=root 03beec21-deef-4dde-ad40-824900e79182
	fi
	linux16	/boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Slackware Linux (Slackware 14.2) (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
	else
	  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
	fi
	linux /boot/vmlinuz-huge-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
	initrd /boot/initrd.gz
}
submenu 'Advanced options for Slackware Linux (Slackware 14.2) (on /dev/sda1)' $menuentry_id_option 'osprober-gnulinux-advanced-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
	menuentry 'Slackware-14.2 GNU/Linux (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-huge-4.4.14--98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-huge-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux 4.4.14 (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-huge-4.4.14--98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-huge-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux 4.4.14 (recovery mode) (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-huge-4.4.14-root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-huge-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux huge (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-huge--98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-huge root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux huge (recovery mode) (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-huge-root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-huge root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux 4.4.14 (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-generic-4.4.14--98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-generic-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux 4.4.14 (recovery mode) (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-generic-4.4.14-root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-generic-4.4.14 root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux generic (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-generic--98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-generic root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro
		initrd /boot/initrd.gz
	}
	menuentry 'Slackware-14.2 GNU/Linux, with Linux generic (recovery mode) (on /dev/sda1)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-generic-root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		linux /boot/vmlinuz-generic root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro single
		initrd /boot/initrd.gz
	}
}

set timeout_style=menu
if [ "${timeout}" = 0 ]; then
  set timeout=10
fi
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
menuentry 'Slackware-14.2 EXT as hd1,huge' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
	insmod part_msdos
	insmod ext2
	set root='hd1,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
	else
	  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
	fi
        echo    'Loading Linux 4.4.14 ...' 
	linux /boot/vmlinuz root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7  ro  rootdelay=5  vt.default_utf8=0 vga = normal
        echo    'Loading initial ramdisk ...'
        initrd /boot/initrd.gz 
}
menuentry 'Slackware-14.2 EXT as hd0,huge' --class slackware-14.2 --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.14-advanced-98ced7a0-7711-4a00-b5db-981f0bc543c7' {
		load_video
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  98ced7a0-7711-4a00-b5db-981f0bc543c7
		else
		  search --no-floppy --fs-uuid --set=root 98ced7a0-7711-4a00-b5db-981f0bc543c7
		fi
		echo	'Loading Linux 4.4.14 ...'
		linux	/boot/vmlinuz root=UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7 ro  
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.gz
	}

### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f  ${config_directory}/custom.cfg ]; then
  source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f  $prefix/custom.cfg ]; then
  source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
I have modified the 40_custom so I use these entries. I have booted with disk as a raw device to a vbox machine so it is the hd0/sda pair. If I use it as external usb disk it will be the hd1/sdX pair.

Regards, Apostolos.
 
Old 05-22-2017, 03:37 PM   #39
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,316

Rep: Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023
Well, if you want to try lilo, you could put the following in your /etc/lilo.conf (replacing what is currently in there).

And crap, I just realized I forgot to ask for your disk id for the boot disk. This is needed since you can't reference /dev/sda like you normally would, but because it doesn't have a partition (since we're talking about the disk as a whole, not an individual partition), you need to reference the disk by id. You can find that under /dev/disk/by-id/. The output for my computer is:

Code:
jbhansen@febtober:~$ ls -la /dev/disk/by-id
total 0
drwxr-xr-x 2 root root 200 May 12 07:04 ./
drwxr-xr-x 4 root root  80 May 12 07:04 ../
lrwxrwxrwx 1 root root   9 May 12 07:04 ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y -> ../../sda
lrwxrwxrwx 1 root root  10 May 12 07:04 ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y-part1 -> ../../sda1
lrwxrwxrwx 1 root root  10 May 12 07:04 ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y-part2 -> ../../sda2
lrwxrwxrwx 1 root root  10 May 12 07:04 ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y-part3 -> ../../sda3
lrwxrwxrwx 1 root root   9 May 12 07:04 wwn-0x575739478372339714x -> ../../sda
lrwxrwxrwx 1 root root  10 May 12 07:04 wwn-0x575739478372339714x-part1 -> ../../sda1
lrwxrwxrwx 1 root root  10 May 12 07:04 wwn-0x575739478372339714x-part2 -> ../../sda2
lrwxrwxrwx 1 root root  10 May 12 07:04 wwn-0x575739478372339714x-part3 -> ../../sda3
You can safely ignore the wnn entries, and we would want to focus on the one that contains your device name. We want the one that is just point to your ../../sda entry, not any of the partitions (sda1, sda2, etc). In my case, it is ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y. So we want to change the boot entry at the top to read /dev/disk/by-id/ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y in my case. In yours, you'll want to replace the red highlighted section with the one matching yours.

Code:
# LILO configuration file

# Append any additional kernel parameters:
append=" vt.default_utf8=0"
boot = /dev/disk/by-id/ata-Samsung_SSD_850_EVO_120GB_S21TNWAG214167Y
compact
LBA32

# Boot BMP Image.
  bitmap = /boot/slack.bmp
  bmp-colors = 255,0,255,0,255,0
  bmp-table = 60,6,1,16
  bmp-timer = 65,27,0,255

prompt
timeout = 120
change-rules
  reset
vga = 794

# Linux bootable partition config begins
image = /mnt/tmp/boot/vmlinuz-4.4.0-66-generic
  initrd = /mnt/tmp/boot/initrd.img-4.4.0-66-generic
  root = "UUID=03beec21-deef-4dde-ad40-824900e79182"
  label = Peppermint
  read-only

image = /boot/vmlinuz-generic-4.4.14
  initrd = /boot/initrd.gz
  root = "UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7"
  label = Slackware
  read-only
You will want to boot off the Slackware installation disk, but you don't want to run setup. Once booted, you will need to mount the Slackware drive and bind mount a few other directories. Once that is done, you'll also want to mount the Peppermint drive.

Code:
# Mount Slackware
mount /dev/sda1 /mnt
# Bind mount needed virtual directories
mount -o bind /dev /mnt/dev
mount -o bind /proc /mnt/proc
mount -o bind /sys /mnt/sys
# Mount Peppermint
mount /dev/sda5 /mnt/mnt/tmp
Once this is done, chroot yourself into the Slackware environment:

Code:
chroot /mnt
Now it should look like a normal prompt. I would probably regenerate your initrd, just in case...

Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh -k 4.4.14
Once you run this, it will output a command. You will want to change the -r from /dev/sda1 to "UUID=98ced7a0-7711-4a00-b5db-981f0bc543c7" (make sure you include the quotes). You can then run the command. It should store the new initrd in /boot/. Now that this is done, you should be able to test your configuration. You do that using lilo -t (it's normal to see a few warnings here, as long as there are no errors -- if there's errors report them back here before you run lilo by itself). If there's no errors, run lilo to save it and you should be able to reboot and have it work in both Virtualbox and as a direct boot device.

Good luck!
 
Old 05-23-2017, 02:01 AM   #40
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
Thanx bassmadrigal for the suggestion. I followed the instruction, unfortunately I get the same error when booting directly from the usb hd. As you can see in the attached pictures, the problem is that this disk is not recognized, strange since the boot process is starting from this disk! My lilo conf is as:

Code:
bash-4.3$ cat /etc/lilo.conf
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/disk/by-id/ata-VBOX_HARDDISK_VB4861a2c2-4471d1e3

#compact        # faster, but won't work on all systems.

# Boot BMP Image.
# Bitmap in BMP format: 640x480x8
  bitmap = /boot/slack.bmp
# Menu colors (foreground, background, shadow, highlighted
# foreground, highlighted background, highlighted shadow):
  bmp-colors = 255,0,255,0,255,0
# Location of the option table: location x, location y, number of
# columns, lines per column (max 15), "spill" (this is how many
# entries must be in the first column before the next begins to
# be used.  We don't specify it here, as there's just one column.
  bmp-table = 60,6,1,16
# Timer location x, timer location y, foreground color,
# background color, shadow color.
  bmp-timer = 65,27,0,255
# Standard menu.
# Or, you can comment out the bitmap menu above and
# use a boot message with the standard menu:
#message = /boot/boot_message.txt

# Append any additional kernel parameters:
append=" vt.default_utf8=0"
prompt
timeout = 50
# Normal VGA console
vga = normal
# Ask for video mode at boot (time out to normal in 30s)
#vga = ask
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# ramdisk = 0     # paranoia setting
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = "UUID=4a3a0168-9455-4d5a-b03d-c90e19b11395"
  label = Slackware
  initrd = /boot/initrd.gz
  read-only  # Partitions should be mounted read-only for checking
# Linux bootable partition config ends
ata-VBOX_HARDDISK_VB4861a2c2-4471d1e3 is the value returned by ls -la /dev/disk/by-id. I run mkinitrd adding usb-storage and usbcore modules but no success. I think I have reached a dead-end at this point.

Regards, Apostolos

UPDATE: Perhaps I am missing some usb drivers from the initrd. I am going to create again initrd with usbcore:usb-hid:hid:usb-storage:uas:ehci-hcd:xhci-pci:xhci-hcd and perhaps some others to see where it is going to get me.
Attached Thumbnails
Click image for larger version

Name:	IMG_0297.jpg
Views:	6
Size:	254.5 KB
ID:	25080   Click image for larger version

Name:	IMG_0296.jpg
Views:	5
Size:	250.4 KB
ID:	25081  

Last edited by apmount; 05-23-2017 at 03:43 AM.
 
Old 05-23-2017, 06:37 AM   #41
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,316

Rep: Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023Reputation: 5023
Quote:
Originally Posted by apmount View Post
Code:
bash-4.3$ cat /etc/lilo.conf
# Start LILO global section
boot = /dev/disk/by-id/ata-VBOX_HARDDISK_VB4861a2c2-4471d1e3
#compact        # faster, but won't work on all systems.
# Boot BMP Image.
  bitmap = /boot/slack.bmp
  bmp-colors = 255,0,255,0,255,0
  bmp-table = 60,6,1,16
  bmp-timer = 65,27,0,255

# Append any additional kernel parameters:
append=" vt.default_utf8=0"
prompt
timeout = 50
vga = normal
# End LILO global section

# Linux bootable partition config begins
image = /boot/vmlinuz
  root = "UUID=4a3a0168-9455-4d5a-b03d-c90e19b11395"
  label = Slackware
  initrd = /boot/initrd.gz
  read-only
# Linux bootable partition config ends
ata-VBOX_HARDDISK_VB4861a2c2-4471d1e3 is the value returned by ls -la /dev/disk/by-id. I run mkinitrd adding usb-storage and usbcore modules but no success. I think I have reached a dead-end at this point.

Regards, Apostolos

UPDATE: Perhaps I am missing some usb drivers from the initrd. I am going to create again initrd with usbcore:usb-hid:hid:usb-storage:uas:ehci-hcd:xhci-pci:xhci-hcd and perhaps some others to see where it is going to get me.
First, I would hardcode the /boot/vmlinuz to your actual generic kernel, since /boot/vmlinuz is just a symlink that will be adjusted if/when you install new kernel packages.

Next, are you using /usr/share/mkinitrd/mkinitrd_command_generator.sh to build your initrd? If so, can you paste the output of that command and the actual mkinitrd command you're running to build the initrd?

EDIT: And I removed most of the comments from the lilo.conf just to simplify reading it.

Last edited by bassmadrigal; 05-23-2017 at 06:39 AM.
 
Old 05-23-2017, 07:33 AM   #42
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
the generator output:

mkinitrd -c -k 4.4.14 -f ext4 -r /dev/sda1 -m jbd2:mbcache:ext4 -u -o /boot/initrd.gz

I have modified it a bit, so I replaced -r /dev/sda1 with the UUID and added some usb modules in -m.

In fact, extracting the initrd.gz I can see that the rootdev file has the value UUID=..., the uuid of the partition (sdX1 with X=a or b depending on how the disk is seeing from the system).

So far so good. But when I boot directly from this disk as usb attached device to a pc (or laptop) i reached to a point where in the emergency shell, I can not see /dev/sdb1 or anything other device disk except the /sda and /sda1 which is the windows disk.
 
Old 05-23-2017, 08:24 AM   #43
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (current), FreeBSD, Win10, It varies
Posts: 9,951

Rep: Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146Reputation: 2146
Quote:
Originally Posted by apmount View Post
the generator output:

mkinitrd -c -k 4.4.14 -f ext4 -r /dev/sda1 -m jbd2:mbcache:ext4 -u -o /boot/initrd.gz

I have modified it a bit, so I replaced -r /dev/sda1 with the UUID and added some usb modules in -m.

In fact, extracting the initrd.gz I can see that the rootdev file has the value UUID=..., the uuid of the partition (sdX1 with X=a or b depending on how the disk is seeing from the system).

So far so good. But when I boot directly from this disk as usb attached device to a pc (or laptop) i reached to a point where in the emergency shell, I can not see /dev/sdb1 or anything other device disk except the /sda and /sda1 which is the windows disk.
If you are going into an emergency shell, then that has to be Linux trying to boot off your LILO installed on that /dev/sdbx and it still for whatever strange reasons is getting changed to something else. If you got anoher hdd laying around. I'd personally, try installing Slack on that via USB PORT.

hdd ---> cable to plug into USB PORT ---> PC/Laptop ( in one usb port)
in the other usb port the USB STICK to install Sack. then just use the PC/Laptop as the through put - install Slack to external hdd and let it install LILO on the external hdd. reboot - see if that takes.

if it works you now have a basis for comparison.

because using a Virtual Box as a means for booting it too is addressing the situation differently I bet.
maybe something with how you installed it via the Vbox - some internal crazy shi& going on within Slack or Vbox that we cannot see.

because it is seeing it like this at some point
ata-VBOX_HARDDISK_VB4861a2c2-4471d1e3 is the value returned by ls -la /dev/disk/by-id.

Last edited by BW-userx; 05-23-2017 at 08:32 AM.
 
1 members found this post helpful.
Old 05-23-2017, 04:08 PM   #44
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
[SOLVED(?)] Installation from live usb on an external hdd (14.2), selecting target does not do anything

OK, after numerous tries again I believe I have reached a point that can be thought of as success, considering I am writing this post from the slackware that has been booted from an external hdd!!!

To achieve this I followed the instructions given on this link

http://www.linuxquestions.org/questi...how-to-919708/

(with the difference I use initrd and not recompiling the kernel plus I use grub and not lilo) with of course the instructions and wisdom of BW-userx and bassmadrigal. y

So far I managed to boot the system from the external hdd but using grub and not lilo. One strange thing was that on the second reboot I got a message about elf header to small or something like that at the very start of the grub. Using rescueCD i reinstalled grub and now after 4 or 5 reboots this message does no longer appear. However there is a strange behavior at boot time, where I still get the messages as before, but the process goes a bit further and I get the messages in the attached picture*. At this point if I press enter and type exit I get Kernel panic. If I wait some seconds and press enter and exit the system boots ok. What a strange behavior! I am attaching the dmesg as well if on is interested in having a look at it.

I will continue testing the system to see if it has a consistent behavior.

Regards, Apostolos.

EDIT: Unfortunatelly I can't attach the picture due to the size, the messages are again the "can't find /mnt in etc/fstab", "error: no /sbin/init found on rootdev" but the process continues up to "random nonblocking pool is initialized". There it stops and waits for me to do something.
EDIT2: Of course all these were done outside virtual box as BW-userx suggested. Just using the installation usb and the external hdd (but...wait! I did have an internal slackware running for making alterations, where else? under virtual box!)
Attached Files
File Type: log dmesg.log (63.8 KB, 5 views)

Last edited by apmount; 05-23-2017 at 04:46 PM.
 
Old 05-23-2017, 04:52 PM   #45
apmount
Member
 
Registered: Mar 2009
Location: Athens
Distribution: Slackware
Posts: 81

Original Poster
Rep: Reputation: 5
as for the original problem on the title, the question remains, can one use the live usb to install slackware to anything else except sdaX?

Last edited by apmount; 05-23-2017 at 04:57 PM.
 
  


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
AryaLinux installation USB external HDD failed without warning joellapointe1717 Linux - Newbie 28 10-15-2016 12:40 AM
Booting Problem. Windows and ubuntu on internal hdd. Centos on External USB hdd faisal59 Linux - Distributions 1 07-17-2013 08:19 AM
Slow USB transfer rates (60kb p/s) External HDD --> Internal HDD drfrostbyte Linux - Hardware 4 03-28-2011 01:20 AM
External ubuntu install on external USB HDD th3_tr00p3r Linux - Newbie 1 05-11-2008 02:56 PM
External installation - USB HDD petercockroach Linux - Newbie 1 11-04-2004 04:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - Installation

All times are GMT -5. The time now is 12:37 AM.

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
Open Source Consulting | Domain Registration