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 06-30-2009, 06:25 AM   #1
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slack 12.2, debian-Trinity , openbsd
Posts: 729

Rep: Reputation: 56
Slackware on USB


Hi,

I want to install Slackware on USB stick (pen-drive). It seems to be
easy. What's the problem is how to boot it. Should I install lilo somewhere on the pen-drive? Or the system is booted via isolinux as
on CD\DVD?
 
Old 06-30-2009, 06:33 AM   #2
janhe
Member
 
Registered: Jul 2007
Location: Belgium
Distribution: slackware64 13.1, slackware 13.1
Posts: 369

Rep: Reputation: 45
AFAIK, you can put lilo on the USB stick. Just remember to put the name of the USB stick in the "boot =" line of /etc/lilo.conf . e.g.
Code:
boot = /dev/sdb
Do NOT put a number after it, like in /dev/sdb1
 
Old 06-30-2009, 07:21 AM   #3
XGizzmo
Member
 
Registered: Mar 2007
Distribution: Slackware
Posts: 264

Rep: Reputation: 68
You will also have to added something like rootdelay=10 to your lilo append line.
If you don't you will get errors about it can't mount the root file system.
 
Old 06-30-2009, 07:50 AM   #4
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slack 12.2, debian-Trinity , openbsd
Posts: 729

Original Poster
Rep: Reputation: 56
Quote:
Originally Posted by janhe View Post
AFAIK, you can put lilo on the USB stick. Just remember to put the name of the USB stick in the "boot =" line of /etc/lilo.conf . e.g.
Code:
boot = /dev/sdb
Do NOT put a number after it, like in /dev/sdb1
Why /dev/sdb ? I have four usb ports. Say /dev/sdc , sdb etc.
 
Old 06-30-2009, 10:35 AM   #5
janhe
Member
 
Registered: Jul 2007
Location: Belgium
Distribution: slackware64 13.1, slackware 13.1
Posts: 369

Rep: Reputation: 45
/dev/sdb is just an example
It could just as well be /dev/sda or /dev/sdc or /dev/sdh or something else (note the "e.g." right before the code in my post)

/dev/sd? (with a letter in place of the question mark) points to a hard drive. This could be the SATA hard drive in your computer (older ATA hard drives are named /dev/hda, /dev/hdb and so forth)

USB drives are treated as regular SATA hard drives, only they connect through USB. The name is given to the USB stick, not to the USB port it connects on.

There is a link about installing slackware 12.1 to a USB stick (http://linuxconfig.dyndns.org:1184/l...vable_USB_disk) in the Slackware (R) links (http://wiki.linuxquestions.org/wiki/...21.27.27.27.22).

If you want more information about the Slackware (R) links, please contact onebuck.
 
Old 06-30-2009, 10:29 PM   #6
zrdc28
Member
 
Registered: Dec 2007
Location: Alabama USA
Distribution: Slackware current
Posts: 249

Rep: Reputation: 40
unetbootin

unetbootin will do exactly what you want, It will download the iso, copy it from cd or from the computer. Just change cmos to boot from usb and you are ready to go.It will run live from usb or install.
 
Old 07-01-2009, 01:27 AM   #7
Nille_kungen
Member
 
Registered: Jul 2005
Posts: 213

Rep: Reputation: 43
Quote:
Originally Posted by zrdc28 View Post
unetbootin will do exactly what you want, It will download the iso, copy it from cd or from the computer. Just change cmos to boot from usb and you are ready to go.It will run live from usb or install.
Well unetbootin doesn't make a persistence liveCD?
Or does it?
 
Old 07-01-2009, 01:58 AM   #8
Skaperen
Senior Member
 
Registered: May 2009
Location: WV, USA
Distribution: Slackware, CentOS, Ubuntu, Fedora, Timesys, Linux From Scratch
Posts: 1,777
Blog Entries: 20

Rep: Reputation: 115Reputation: 115
The unetbootin program can make a bootable flash drive from an ISO, if the flash drive is already formated with the FAT filesystem (as most USB memory sticks are). But then you just have the same system as if you were booting from the ISO. That could be what a lot of people want so they don't have to use an optical disk. It's good for netbooks that don't have an optical drive. This would be the device to boot to do an install to somewhere else.

You can install Slackware (or other distributions) to a flash drive just like any other hard drive. It looks like a hard drive attached via the USB bus, so it should work anywhere USB can be activated. As mentioned earlier, do use the root delay because the kernel doesn't see all devices on USB busses immediately. You would just choose the USB drive like any other drive. But you probably should repartition it, and definitely reformat it. Choose the boot loader in exactly the same way you would with any other device.

Sometimes USB devices show up at different device addresses. So you should make sure /etc/fstab filesystems by label or UUID instead of device name.

I have 2 16GB USB memory sticks, one with slackware-current and the other with slackware64-current, installed. I created these by doing the installation inside a qemu virtual machine targeting an emulated drive that was a file created exactly the same size as the USB memory sticks. After the installation was done, I make a compressed archive of those 16GB images (size went down to about 2GB). Then I just copied the image uncompressed to the USB memory stick devices directly.
 
Old 07-01-2009, 07:19 AM   #9
vharishankar
Senior Member
 
Registered: Dec 2003
Posts: 3,142
Blog Entries: 4

Rep: Reputation: 121Reputation: 121
It's all very well to install of a USB stick or a USB hard drive, but does your BIOS recognize the device when you boot up? If it does, you can load the bootloader on the Stick itself. The installer usually loads the kernel and device drivers for storage devices including USB, so the installer has no problem detecting the device.

On the other hand, if the BIOS does not detect the device, you'll have a hell of a time booting it, because unless a kernel is loaded with the USB hardware module drivers, even LILO or GRUB cannot help you boot the device when you boot the system. I don't know how others got it to work with LILO (maybe LILO loads the Linux kernel modules when it runs, but I doubt it) but it definitely doesn't work with GRUB for me. The device simply is non-existent for me. Even though the BIOS claims to be able to "boot off an external USB drive" it just doesn't work at all.

That is the biggest problem.

Because if any of you have actually got it to work by using the regular boot-loader off the hard disk, I'd like to know what you did to get it to work. Right now, I cannot boot off an external hard disk or USB stick because the BIOS simply ignores the device at boot time and without a kernel already loaded with appropriate USB device drivers, the boot manager cannot help boot off the device either.

Last edited by vharishankar; 07-01-2009 at 07:45 AM.
 
Old 07-04-2009, 09:09 AM   #10
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slack 12.2, debian-Trinity , openbsd
Posts: 729

Original Poster
Rep: Reputation: 56
Hi for all of you,

I read carefully your opinions. Tried several options
according your suggestions.

At this moment I succed only in one
thing: I installed LILO on USB and LILO boots the kernel
installed on the same USB.

However the kernel is unable to mount the root partition.
It panics:

Kernel panic: .....
 
Old 07-04-2009, 09:14 AM   #11
linus72
Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,060

Rep: Reputation: 330Reputation: 330Reputation: 330Reputation: 330
Just to clarify igadoter; are you trying to run a full-hd install From a USB
meaning the filesystem complete is in USB
Or just trying to run slack install cd live?
 
Old 07-04-2009, 12:44 PM   #12
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 11,203
Blog Entries: 3

Rep: Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432
Hi,
Quote:
Originally Posted by igadoter View Post
Hi for all of you,

I read carefully your opinions. Tried several options
according your suggestions.

At this moment I succed only in one
thing: I installed LILO on USB and LILO boots the kernel
installed on the same USB.

However the kernel is unable to mount the root partition.
It panics:

Kernel panic: .....
You may need to create a 'initrd' for your kernel. Read the '/boot/README.initrd' to understand;

Quote:
excerpt from '/boot/README.initrd';

2. Why do I need an initrd?

The usual reason to use an initrd is because you need to load kernel
modules before mounting the root partition. Usually these modules are
required to support the filesystem used by the root partition (ext3,
reiserfs, xfs), or perhaps the controller that the hard drive is attached
to (SCSI, RAID, etc). Essentially, there are so many different options
available in modern Linux kernels that it isn't practical to try to ship
many different kernels to try to cover everyone's needs. It's a lot more
flexible to ship a generic kernel and a set of kernel modules for it.

3. How do I build the initrd?
See the rest of the file to understand how to create the 'initrd'.
 
Old 07-05-2009, 01:37 AM   #13
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slack 12.2, debian-Trinity , openbsd
Posts: 729

Original Poster
Rep: Reputation: 56
Quote:
Originally Posted by linus72 View Post
Just to clarify igadoter; are you trying to run a full-hd install From a USB
meaning the filesystem complete is in USB
Or just trying to run slack install cd live?
What am I trying to do is a portable and extentible OS, in the sense that
I will be able to add additional applications, say compile sources
from SlackBuild.org. Complete and a fully functional system on USB.
Just plug and play.

So, a distro liveCD is of no use. Most of them are rahter weakly equipped and as I suppose one cannot add other applications. But,
perhaps I am wrong in this.

So, at now I hope to make a full-hd install on USB.
 
Old 07-05-2009, 01:45 AM   #14
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slack 12.2, debian-Trinity , openbsd
Posts: 729

Original Poster
Rep: Reputation: 56
Quote:
Originally Posted by onebuck View Post
Hi,


You may need to create a 'initrd' for your kernel. Read the '/boot/README.initrd' to understand;



See the rest of the file to understand how to create the 'initrd'.
I partitioned USB with ext2 file system. The kernel installed on
USB is full-featured hugesmp.s.

So I have no idea which additional kernel modules should be loaded.
 
Old 07-05-2009, 08:13 AM   #15
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 11,203
Blog Entries: 3

Rep: Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432Reputation: 1432
Hi,

The 'initrd' would load the required modules for the filesystem or any support modules for the specified modules.
 
  


Reply

Tags
flash drive, qemu


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
Conflicting USB mouse & usb pendrive on Slackware 11.0 aruntom55 Slackware 3 08-26-2007 01:34 AM
HP Deskjet (USB) & CUPS & Slackware 9.1: Unable to open USB device "usb:/dev/usb/lp0&qu arnostienen Slackware 2 01-29-2004 03:22 PM
slackware 9.1 USB mouse and other usb devices not working jimMC Linux - Hardware 11 01-24-2004 10:58 AM


All times are GMT -5. The time now is 09:42 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration