Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Slackware This Forum is for the discussion of Slackware Linux.


  Search this Thread
Old 07-30-2013, 04:36 AM   #16
Registered: Nov 2008
Location: Washington state, USA
Distribution: NetBSD, FreeBSD, OpenBSD, OpenSolaris, FreeSlack, Slackware, SalixOS, DOSBox, Replicant, Android
Posts: 301

Original Poster
Rep: Reputation: 26

Originally Posted by guanx View Post
The README only tells you something can be done in some way. It does not say other ways are forbidden.
Ok, let us get this straight. I am talking not only about the method I used, described at the wiki, which I think makes a FAT filesystem, but the official Slackware script in the directory BrianL mentioned, which you did not read; I will quote the script's explanation of itself, starting on line 45.

  echo "# Purpose #1: to use the content of Slackware's usbboot.img and"
  echo "#   transform a standard USB thumb drive with a single vfat partition"
  echo "#   into a bootable medium containing the Slackware Linux installer."
  echo "# "
  echo "# Purpose #2: to use the contents of a Slackware directory tree"
  echo "#   and transform a standard USB thumb drive with"
  echo "#   a single vfat partition and 2GB of free space into"
  echo "#   a self-contained USB installation medium for Slackware Linux."
I am not criticizing your alternative way of doing things, which of course is a way you can do things. I am criticizing the two methods I mentioned above, one of which is official, and one of which is unofficial, and both of which people use. Your method of doing things does not change the fact that these two methods exist, and that one is official, and people use them, and I am not talking about your way of doing things, except to say it should be the way things are done.

Last edited by dchmelik; 07-30-2013 at 04:38 AM.
Old 07-30-2013, 04:55 AM   #17
Registered: Sep 2012
Posts: 193

Rep: Reputation: Disabled
I am not sure any the criticism is really justified. As far as partitions go its the norm to include a partition table on larger USB devices. As to the type of partition that is little more than a couple of magic numbers at some specific byte offsets.

They have no effect on what you put in the partition, they might be viewed as simply informational, as far you are concerned. Some things like BIOS,UEFI and other software are looking for specific values, its easiest to just use them, and there is no real down side.

As far as the VFAT filesystem goes, there again its a very common choice for removable USB media. The installer works fine using that filesystem as a source AND you can plug that same media into a Windows, Mac, other Linux box, and just about anything else with a USB port and read it as well; which may be helpful if you need to review one of the docs. As others have mentioned this is also the filesystem type you can count on UEFI being able to boot.

A DOS or Windows partition type, with a VFAT filesystem is the way this should be done.
Old 07-30-2013, 04:58 AM   #18
Senior Member
Registered: Dec 2008
Posts: 1,044

Rep: Reputation: 150Reputation: 150
The word "purpose" means what it intends to do, and not how things should be done. Did I understand it wrong? Maybe I lost my English skills during my travaling worldwide. Now I go on to another traval. Bye!
Old 07-30-2013, 06:11 AM   #19
Registered: Sep 2012
Distribution: Slackware
Posts: 87

Rep: Reputation: Disabled
Originally Posted by TobiSGD View Post
BIOSes can't boot from any filesystem, they rely on finding executable code in the MBR of the medium you want to boot from.
/facepalm. I'm sorry for speaking nonsense. Thanks for correcting me, TobiSDG.
Old 11-16-2013, 03:46 AM   #20
Registered: Nov 2008
Location: Washington state, USA
Distribution: NetBSD, FreeBSD, OpenBSD, OpenSolaris, FreeSlack, Slackware, SalixOS, DOSBox, Replicant, Android
Posts: 301

Original Poster
Rep: Reputation: 26
Another reason I am critical of the FAT32 usage is because there is a process described to make a boot flash drive but keep the files you had already there, which can lead to unexpected inadequacies. For example, say one makes some scripts to do things after upgrading, or even to do the upgrade process (and then hopefully check it worked), or even that one will copy somewhere like /usr/local/bin, or something like ~/sh after installing. If you put the scripts on FAT32, they now have DOS newlines and will no longer run properly even when copied back onto EXT4. My point is, a POSIX-based OS installer should primarily run on a filesystem of its own, and only describe other partition usage to help people switch away from some other system. One does not need FAT32 on a USB flash drive by default, any more than for on your hard drive to boot from Loadlin or whatever may be used now.

Last edited by dchmelik; 11-16-2013 at 03:47 AM.
Old 11-16-2013, 04:21 AM   #21
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,890

Rep: Reputation: 569Reputation: 569Reputation: 569Reputation: 569Reputation: 569Reputation: 569
It uses a fat partition because that is the *most bootable* thing there is.
"finding executable code in the MBR" -should be "finding executable code in the device". Why? Because a CD does not have an MBR -but gets identified as being executable code.

When the BIOS sees a device it tries to figure out if there is executable code there -executable code of the proper type(architecture). Different BIOS's use different methods to make this determination and they are all based on heuristics. As mentioned, not every bootable device has an MBR or partition table. Floppies have no MBR, they have executable code beginning at the very beginning of the device. CD's have 32k which is *empty* right at the start of the device. Hard disks of course have 446 bytes of executable code at the start, followed by 64 bytes of partition table. A Zip disk also has an MBR(446+64 bytes), but for it to be found 'bootable' the partition table must have the first partition as *partition 4* and it should be marked 'bootable'. Flash devices can either have an MBR or be formatted as a single whole-disk drive, or they may look like a floppy -executable code with no partition table.

BIOS's which can boot from USB devices distinguish between one or more drive types -floppy, hard-disk or zip drive. Incidentally, after the initial empty 32K of a CD, the executable boot code appears to be a 'large floppy', so a USB CD drive can boot also.

It is even possible to make a drive look like more than one type of device. The 'bootfat' project produces images for booting from USB devices and can make a single device look like a floppy, a ZIP-drive and a hard disk -all at the same time. This makes such an MBR the most bootable thing there is. Then, there is the isohybrid tool which is part of syslinux, which makes an iso image also look like a hard disk. This means you can burn it to a CD and it looks like a bootable CD, or you can 'dd' the same image to a hard-disk or flash drive and it appears to be a partitioned device. There have been efforts to something similar with bootable images using grub.

Something that looks like a floppy on a FAT filesystem is the most universally-bootable thing there is. This is why the syslinux bootloader is the most successful at booting many types of machines.

If the OP is willing to accept a system/CD/whatever being less bootable *than possible*, then using another alternative will still produce the desired effect -but less often.
Old 11-16-2013, 04:31 AM   #22
Didier Spaier
LQ Addict
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2.1 on Lenovo Thinkpad W520
Posts: 8,285

Rep: Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053Reputation: 3053
Well, I just put in an ISO image what I need using cdrecord, then run isohybrid on it, et voilą No need to compute image size nor worry about making a filesystem, the image is usable to make an usb installer, with or without packages. You can do that with dd on Linux of course, and "rufus" works well on Windows.

For the records, this is explained in /isolinux/README.TXT. All you have to do is choose the files and directories you want to exclude with -m or -x, and possibly customize the content using option -graft-points of cdrecord.

Just a warning: preferably use software versions shipped in 14.1, I had isohybrid failing on some big ISO images in 14.0.

Last edited by Didier Spaier; 11-16-2013 at 04:34 AM.
Old 11-16-2013, 04:46 AM   #23
Registered: Nov 2008
Location: Washington state, USA
Distribution: NetBSD, FreeBSD, OpenBSD, OpenSolaris, FreeSlack, Slackware, SalixOS, DOSBox, Replicant, Android
Posts: 301

Original Poster
Rep: Reputation: 26
Originally Posted by gnashley View Post
It uses a fat partition because that is the *most bootable* thing there is. [...]
People already argued against that above. I do not know if a BIOS could USB boot before UEFI did, but if I recall, there was various software that would either enable that or boot from something else, then enable USB, relatively regardless of what OS was on, when few/no BIOSes booted filesystems. There have been many types of systems over the decades--many still seriously used--that booted from removable media using all sorts of different OSes and filesystems, so people should not just treat Microsoft/obsolete stuff as standard. Some people still use non-UEFI mode, but despite someone's arguement above 'BIOSes do not boot filesystems', what you say may be becoming correct, but there is still the problem if one uses FAT32 for extra stuff.

In fact, the modern Unix (BSD, etc.) filesystems, and EXT4, are usable on more types of systems than FAT32 is. So, I do not care what new BIOSes do--Unix and EXT4 should become standard in popularity, besides versatility (as it is). There is also Coreboot, and all one needs to do to prevent issues like I described is use that and/or make a boot partition in a USB flash drive, which should be a standard option, all documented as the first or second suggestion in a table of contents (such as in README_USB.TXT, though perhaps there should be a Howto), until modern Unix and GNU/Linux become standard.

UPDATE: actually, now I agree with a post above that the problem is not critical. It was probably my UEFI BIOS that mounted the flash drive, and BIOS/UEFI/whatever booting things seems to be the way of things now, which I had not known except in the case of Coreboot, which I had never been able to try. Of course, if it searched for media's filesystems to mount, the same thing would happen. So, it is more of a modern BIOS problem, than a Slackware problem. I recall almost a decade or so ago, the same thing would have happened if I put in a 5.25" or 3.5" disc and took it out when the BIOS was doing I/O to it. So, my whole post was rather ridiculous, except later mentioning the other problems one could have booting from filesystems not designed for the OS, which is course still not critical.

Last edited by dchmelik; 11-16-2013 at 05:26 AM.


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 usb flash drive rng Slackware 2 06-28-2013 11:39 AM
[SOLVED] USB Flash drive issue utanja Linux - Virtualization and Cloud 3 06-15-2013 04:40 AM
Attempting to boot Slackware from USB flash drive, getting kernel panic error hairykoala Slackware 11 02-25-2009 07:46 PM
Strange USB flash drive issue ValidiusMaximus Linux - Software 2 01-05-2005 03:30 PM > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:11 AM.

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