LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 08-26-2016, 03:10 PM   #1
tb75252
Member
 
Registered: Oct 2010
Posts: 167

Rep: Reputation: Disabled
Bootdisk


During the installation of Slackware 14.2 I was asked whether I wanted to create a USB bootdisk.

My PC is fairly old and its BIOS does not support booting up with a USB thumb drive, so I answered "Skip". (My BIOS supports booting up with a DVD.)

Now I am wondering whether there is a way to create a DVD bootdisk. What do the experts say?
 
Old 08-26-2016, 03:14 PM   #2
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
The DVD installation media IS the maintenance boot disk!

Just boot to your install DVD, mount the / partition of your hard drive and take it from there!
 
Old 08-26-2016, 03:29 PM   #3
tb75252
Member
 
Registered: Oct 2010
Posts: 167

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by astrogeek View Post
The DVD installation media IS the maintenance boot disk!

Just boot to your install DVD, mount the / partition of your hard drive and take it from there!
I see... I was hoping that a DVD bootdisk would be different than the DVD used for installation.
Why, you ask?
As a test, I booted up with the DVD install media and issued the following commands:
Code:
boot: huge.s root=/dev/sda1 rdinit= ro
Everything went fine until it reached the KDE login screen and discovered that my keyboard (USB wired) and mouse (USB wireless) were disabled and I could not do anything other than turn the PC off.
 
Old 08-26-2016, 04:02 PM   #4
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
Well, like that you are simply booting to your installed filesystem, read-only, for better or worse, as you found out.

For an emergency or recovery boot you want to boot to the DVD media, including the root filesystem on that media.

Then mount your installed root filesystem so that you can navigate, inspect and update it as required.

If you need to chroot into the mounted filesystem after boot, to run lilo for example, just do this (replace chroot dir with actual mount point)...

Code:
mount --bind /proc <chroot dir>/proc
mount --bind /dev <chroot dir>/dev

chroot <chroot dir>
At least, that is how I use it. Maybe someone else has other habits.

Last edited by astrogeek; 08-26-2016 at 04:10 PM.
 
Old 08-26-2016, 07:19 PM   #5
tb75252
Member
 
Registered: Oct 2010
Posts: 167

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by astrogeek View Post
Well, like that you are simply booting to your installed filesystem, read-only, for better or worse, as you found out.

For an emergency or recovery boot you want to boot to the DVD media, including the root filesystem on that media.

Then mount your installed root filesystem so that you can navigate, inspect and update it as required.

If you need to chroot into the mounted filesystem after boot, to run lilo for example, just do this (replace chroot dir with actual mount point)...

Code:
mount --bind /proc <chroot dir>/proc
mount --bind /dev <chroot dir>/dev

chroot <chroot dir>
At least, that is how I use it. Maybe someone else has other habits.
I must be doing something wrong... Say that my installation root directory is in /dev/sda1.
I issue these commands:
Code:
root@slackware:/# mount --bind /proc /dev/sda1/proc
I get the following:
Quote:
mount: mount point /dev/sda1/proc is not a directory
 
Old 08-26-2016, 07:46 PM   #6
suppy
Member
 
Registered: Mar 2012
Location: Sweden
Distribution: Slackware
Posts: 83

Rep: Reputation: 60
/dev/sda1 is a device node, not the <chroot dir> that you ought to have mounted it in
 
Old 08-26-2016, 08:13 PM   #7
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
Quote:
Originally Posted by tb75252 View Post
I must be doing something wrong... Say that my installation root directory is in /dev/sda1.
I issue these commands:
Code:
root@slackware:/# mount --bind /proc /dev/sda1/proc
I get the following:
Sorry if I confused you, I should have explicitly included the mount instead of simply saying "mount the installed filesystem".

So, lets assume that you have booted to the DVD and logged in as root, just as you did when you installed.

From that point lets mount your installed root system root filesystem on a directory named /myslack, which we will also create...

Code:
mkdir /myslack
mount /dev/sda1 /myslack

At this point you can navigate and edit your installed system through the /myslack path,
but you are still running the booted DVD. To actually run as your installed system...

mount --bind /proc /myslack/proc
mount --bind /dev /myslack/dev

This makes the device and process nodes of the booted system available to your installed system, then...

chroot /myslack
At this point you are running (almost) just as if you had booted into run-level 3 of your installed system, and you are logged in as root. (So be careful! You may want to similarly mount --bind /sys..., but not req'd for common tasks).

From there you can edit and reinstall lilo, for example, or fix anything that is broken on the installed system.

When done just type exit to "un-chroot" back to the booted DVD and shutdown, and reboot.

Last edited by astrogeek; 08-26-2016 at 08:27 PM.
 
2 members found this post helpful.
Old 08-28-2016, 09:34 PM   #8
tb75252
Member
 
Registered: Oct 2010
Posts: 167

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by astrogeek View Post
Sorry if I confused you, I should have explicitly included the mount instead of simply saying "mount the installed filesystem".

So, lets assume that you have booted to the DVD and logged in as root, just as you did when you installed.

From that point lets mount your installed root system root filesystem on a directory named /myslack, which we will also create...

Code:
mkdir /myslack
mount /dev/sda1 /myslack

At this point you can navigate and edit your installed system through the /myslack path,
but you are still running the booted DVD. To actually run as your installed system...

mount --bind /proc /myslack/proc
mount --bind /dev /myslack/dev

This makes the device and process nodes of the booted system available to your installed system, then...

chroot /myslack
At this point you are running (almost) just as if you had booted into run-level 3 of your installed system, and you are logged in as root. (So be careful! You may want to similarly mount --bind /sys..., but not req'd for common tasks).

From there you can edit and reinstall lilo, for example, or fix anything that is broken on the installed system.

When done just type exit to "un-chroot" back to the booted DVD and shutdown, and reboot.
Thanks for your help!
 
Old 08-28-2016, 10:32 PM   #9
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
You are very welcome!
 
  


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
Bootdisk Help Good2Go Linux - Newbie 2 01-27-2006 06:26 AM
Bootdisk? westverg Linux - Software 9 06-19-2005 09:37 AM
Bootdisk Soulful93 Linux - General 1 06-06-2004 05:40 PM
bootdisk gruddo Linux - Software 5 07-09-2003 05:10 PM
bootdisk blackcat Linux From Scratch 8 09-04-2002 10:52 PM

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

All times are GMT -5. The time now is 06:03 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
Open Source Consulting | Domain Registration