LinuxQuestions.org
Visit Jeremy's Blog.
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 02-16-2008, 11:12 PM   #1
skelter42
LQ Newbie
 
Registered: Jan 2008
Posts: 20

Rep: Reputation: 5
Possible: Install Slackware 11.0 onto a flash drive as a portable OS?


Hi folks,

I'm a student going through exposure to the open source world, and am having a ton of fun with it. For the last semester I've been using slax server edition for school, as it has almost everything a compsci student needs. Now one of my classes is delving into administration, using Slackware 11.0 as the platform.

To make this short, I have an 8 GB flash drive (lucky me!) and I want to install Slackware on it so I have a full, customizable, OS with me wherever I go.

Is this possible? I did a google and a forum search, but it seems everything pushes towards using a small live distro such as slax or dsl.

Thanks in advance if anyone can shove me in the right direction!

skelter
 
Old 02-17-2008, 12:30 AM   #2
PatrickNew
Senior Member
 
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Blog Entries: 1

Rep: Reputation: 48
I believe that ZipSlack is exactly what you're looking for.

Quote:
ZipSlack is a special edition of Slackware Linux that can be installed onto any FAT (or FAT32) filesystem with about 100 MB of free space. It uses the UMSDOS filesystem and contains most of the programs you will need. This means that you do not need to repartition your hard disk if you already have DOS or Windows installed. ZipSlack installs into a directory on your DOS filesystem. It can also be installed to and booted from a Zip disk.

This distribution is ideal for people who don't have a lot of hard disk space, do not have a fast Internet connection to download the entire distribution, or who want a Linux distribution they can carry around on a Zip disk.
from http://www.slackware.com/zipslack/

I don't think it's irrational to assume that you can swap out the word "zip drive" for "flash drive". In the worst case you would just need to update the kernel on the drive to one with usb support if the original is lacking.
 
Old 02-17-2008, 12:35 AM   #3
budword
Member
 
Registered: Apr 2003
Location: Wisconsin
Distribution: Switched to regualr Ubuntu, because I don't like KDE4, at all. Looks like vista on crack.....
Posts: 675

Rep: Reputation: 31
You don't want to use a regualar distro on a flash drive, as each sector on a flash drive can only support a limited number of writes, about 100K, before that sector dies. 100K seems like quite a few, but it really isn't. The specialized live distro's are built to handle this exact problem. If you won't keep anything important on there, and don't mind wasting that flash drive, well then go ahead, it'll be fun to see how long it lasts anyway. But if you aren't keeping anything worthwhile on there, what would be the point exactly ?

Good luck with that...

David
 
Old 02-17-2008, 09:22 AM   #4
skelter42
LQ Newbie
 
Registered: Jan 2008
Posts: 20

Original Poster
Rep: Reputation: 5
@ PatrickNew: thanks for the lead! I have confidence in the zip-type build as I have seen that work on flash drives before.

@budword: thanks for the warning; I knew that the lifetime of flash mem was limited by the writes, but not to what extent. If I go ahead with this, I'll do a minimal install on a smaller drive. I wouldn't want to ruin a large flash drive on an experiment. (At least not one that I paid for!)

Cheers
 
Old 02-17-2008, 11:18 AM   #5
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 11,445
Blog Entries: 4

Rep: Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505
Hi,

Quote:
Originally Posted by budword View Post
You don't want to use a regualar distro on a flash drive, as each sector on a flash drive can only support a limited number of writes, about 100K, before that sector dies. 100K seems like quite a few, but it really isn't. The specialized live distro's are built to handle this exact problem. If you won't keep anything important on there, and don't mind wasting that flash drive, well then go ahead, it'll be fun to see how long it lasts anyway. But if you aren't keeping anything worthwhile on there, what would be the point exactly ?

Good luck with that...

David
There is a difference between a flash drive (solid state drive/SSD) and flash memory (CF). The new flash drives have a large write cycle life and faster read/write than a flash memory.

I think the number you presented for the flash memory writes is to low. Depends on if the flash memory handles the writes in a zone mode or direct write. Some flash memory have over 3 million writes or even better. This will depend on several conditions. Those being average number of writes, write scheme and filesystem selection to just name a few. I would suggest that you google 'flash drive' and 'flash memory'.
 
Old 02-17-2008, 11:21 AM   #6
skelter42
LQ Newbie
 
Registered: Jan 2008
Posts: 20

Original Poster
Rep: Reputation: 5
Well I've been playing around with this, and need some more help. I'm trying to be verbose about what I've done so that any kind gurus will know exactly what I am messing up.

I decided to try a straightforward approach to this (outside of the slackzip method), deciding that as opposed to making the USB bootable per se, I would be willing to use a cd/fd boot disk and load the OS off of the usb.

1. Using fdisk I partitioned a 2GB flash drive as 1 large partition, active, 83 and then formatted it in ext2 (I didn't want to use a journaling FS to reduce the number of writes to the drive).

2. Using a Slackware 11.0 setup disk I installed the A, AP, and N packages onto the flash drive.

3. Then I used the setup disk as a boot disk, and passed the boot parameter: sata.i root=/dev/sda1 noinitrd ro (just like the cheatcode hint text, but for the appropriate "scsi" drive). Keep in mind I am very new to linux; but as I understand it this means: use the default kernel which is located on device sda1, don't load into ram, and load as read only. This is the kernel I defaulted to during the install process.

4. The kernel panicked (that phrase always makes me want to make bad jokes); reading through the dmesg, I'm guessing that this might be due to USB support not being enabled prior to the boot trying to load the OS. It didn't find sda1, since sda1 isn't really a scsi drive, but my usb flash drive.

Edit: the error was something like "VFS Unable to load fs something something 08:01" I took this to mean, hey bub, there is no kernel where you said it would be.

The solution, if my diagnoses of the problem is correct, would be to enable usb support prior to the kernel loading. I went sniffing for a method to do this and did find some helpful parameter sites. There were references to the [knl] usb option and the rootwait option. I tried to use these, but failed.

Questions:

1. Is my assessment of the problem correct?

2. If so, how can I resolve the problem?

3. If the solution involves the parameters, what is the correct syntax for employing them?

Thanks again,

skelter

Last edited by skelter42; 02-17-2008 at 11:25 AM.
 
Old 02-17-2008, 01:24 PM   #7
zux
Member
 
Registered: Jul 2006
Location: latvia
Distribution: slackware
Posts: 127

Rep: Reputation: 16
i think the error means that either the filesystem or the device is no recognized.
try the huge.s kernel or compile your own with the needed drivers (those drivers are built as modules in the sata.i kernel)

the root=/dev/sda1 option means that /dev/sda1 will be mounted as /
 
Old 02-17-2008, 01:41 PM   #8
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 11,445
Blog Entries: 4

Rep: Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505Reputation: 1505
Hi,

I would suggest you look at Alien_Bob's 'SlackwareŽ 12.0 USB_Install' as to how he did it with Slackware 12. This will give some insight and methods to possibly use with 11. Sure the easy way would be just use the Slackware 12 USB_Install.
 
Old 02-17-2008, 03:03 PM   #9
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,775

Rep: Reputation: 481Reputation: 481Reputation: 481Reputation: 481Reputation: 481
The kernel panik happens because the usb drivers have not finished initializing by the the time the kernel tries to mount the indicated root partition. You need to pass rootdelay=seconds (with seconds being usually at least 3 and maybe more depending on the number of partitions on the drive. Make sure the sub modules are builtin to the kernel or use an initrd that loads them as modules for you.
There is/was a project called runt linux which is a modified zipslack installation for usb drives, using the umsdos file system which makes it very easy. But you can not use this with kernel-2.6.x at all.

As far as the durability of the drive, don't expect it to last more than a few months. You can increase the life of it by mounting all partitions with the noatime option(this means you have to use a filesystem format which supports it) and by disabling all swapping.

If you are serious about doing this and having it last and be useful, you should dave your bucks and buy a real usb hard drive. Your system will still be slow compared to running from an internal hard drive, but at least it will last for much longer. (Applications take a long time to start over USB because the bus speeds are very low compared to IDE, but once a program starts you won't notice too much difference.
 
Old 02-17-2008, 04:09 PM   #10
skelter42
LQ Newbie
 
Registered: Jan 2008
Posts: 20

Original Poster
Rep: Reputation: 5
@gnashley:

Thanks for the advice; I'll try to get it to work the way you suggested. I am serious about very little, including this project. But once I get on something, I like to take it through. I probably will not end up using this method as I had planned, but instead use a USB HD as you suggested. However, at this point I've put enough time in I want to make it work at least once!

Thanks again for everyone's help.

skelter
 
Old 02-19-2008, 08:26 PM   #11
techyranger
LQ Newbie
 
Registered: May 2006
Location: Tennessee
Distribution: Redhat and alike
Posts: 20

Rep: Reputation: 0
It's cool if you can get straight Slackware 11 to boot and run from a USB flash, but a distribution called Wolvix can save you the time. It's a bootable live CD built from Slackware 11 and uses a 2.6.x kernel. Once you burn it to CD and boot, go to it's control panel and their's a utility to install Wolvix to a USB drive.

http://wolvix.org/
 
  


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
I need a 1.5 version of slackware for a flash drive rob.rice Slackware 3 11-02-2007 04:26 AM
Newbie trying to install Slackware 10.1 on flash drive Quasix Linux - Kernel 2 05-01-2006 11:15 PM
Slackware on USB flash drive adds2one Slackware 5 03-19-2006 07:20 AM
LXer: EDGE Tech Corp Announces Portable Flash Drive With Muscle - the New 8GB DiskGO!(TM) Now Available; Swap and Go With This Secure Thumb-Sized Flash Drive LXer Syndicated Linux News 0 12-14-2005 03:16 AM


All times are GMT -5. The time now is 11:04 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration