Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm newbie to linux, my question is that if I want to boot from flash disk i must know name of this device and use its name to create the proper bootable partition on it, is it right? when i refer to web pages about this, i didn't find appropriate in detailed way for formatting it,and i need so much help in using parted or fdisk to do it,
thanks to everyone who listened to me
please guide me as soon as possible,thanks alot
First, if you want to boot from a flashdisk, you must be sure your bios allows that.
It's NOT "usb floppy" but "usb harddrive" or another choice under harddrives, when you have the usb drive - already partitioned and with bootable flag set - attached to the box, while booting into bios setup.
Then, when you boot from, let's say a live linux cd like knoppix, you will find ("fdisk -l") there is another sdX drive entry which will show your pendrive.
To make sure it is always recognized the same way, no matter how many other partitioned devices are in place, you should use either filesystem labels or UUIDs instead of the plain /dev/sdX (X is variable). Watch out how to find them - places are in /dev/disk/by_whatever on a booted livecd - and how to create filesystem labels and/or to modify /etc/lilo.conf (run lilo afterwards) or /boot/grub/menu.lst.
I found a good description how to make systemrescuecd (live distribution) bootable from usbstick, on their homepage, and now I have it on a keychain
There is a site somewhere dedicated to pendrivelinux, which is a Mandriva distro, but they give a lot of good information on booting from pendrives, just google it.
I find my usb in path /dev/sdb and i've partitioned it with on boot flag with the type of vfat, i want to use it for root encrypted key, if you have better advise in this way , i'll be so glad to hear it!
but still another questions:
Quote:
Originally Posted by Woodypecker
To make sure it is always recognized the same way, no matter how many other partitioned devices are in place, you should use either filesystem labels or UUIDs instead of the plain /dev/sdX (X is variable).
i still don't know why i must use label or UUID instead of plain path, and in this way , what is "sun" label meaning? when i use parted to make partition bootable , i realize that sun label is the default label , but i don't know other available lables
Quote:
Watch out how to find them - places are in /dev/disk/by_whatever on a booted livecd - and how to create filesystem labels and/or to modify /etc/lilo.conf (run lilo afterwards) or /boot/grub/menu.lst.
do you mean that i must set /dev/desk/by-label or /by-uuid to use partition labels or uuids? but now i just can access partitions with their plain path and when i try lables , that was a message that "unable to open label-name",
and another question ,how can i create label for existing partitions?
Quote:
I found a good description how to make systemrescuecd (live distribution) bootable from usbstick
where is this good description?,please inroduce it to me
Well, for systemrescuecd it's on their homepage
To label a partition: for ext2/3 use e2label, for vfat mlabel should work.
Here a snippet from my /etc/fstab to show usage of labels:
# Entry for /dev/md2 :
LABEL=ROOT / reiserfs relatime,user_xattr,acl 1 1
and here for lilo.conf
image=/boot/vmlinuz-2.6.25.11-2tmb64Gdazuko
label="2.6.25.11-2tmb64Gdazuko"
root="LABEL=ROOT"
initrd=/boot/initrd-2.6.25.11-2tmb64Gdazuko.img
append="resume=UUID=cf459f26-bfee-4788-8085-d72a245799ad"
vga=1
where you may see label as well as UUID usage.
Btw. you can be perfectly happy with /dev/sdb1 as long as you have no 2nd harddrive installed,
in which case sdb may probably change to sdc - and you have to (cat tries to bite her tail) boot up "something" that allows you to access the usb stick r/w and change bootloader as well as fstab.
You can also use the UUID of the filesystem in place of the label. If you know the device node, for example, /dev/sdb1, then you can use the `udevinfo' program to print out the uuid:
udevinfo -q env -n /dev/sdb1
The reason you want to use the UUID or LABEL on removable devices is because a removable device may be given a different device node in the future. The LABEL or UUID are unique identifiers. The same can be true for fixed drives as well, if you repartition or add another drive. Imagine you add a drive to your desktop and need to change the cables around so they all reach. Using the UUID you don't need to fix up your old /etc/fstab entries. Otherwise, the boot process will bail out to the root shell it it gets that far at all.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.