LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 07-19-2013, 07:38 AM   #1
steak1987
Member
 
Registered: Jan 2012
Posts: 130

Rep: Reputation: Disabled
Question Edit bootloader on USB, add option to boot off HDD.


I have TAILS 0.19 on a USB drive, and my main OS on my laptop HDD.

I have set the BIOS to boot from the flash drive. However, I would like to include the option in the bootloader on the USB drive to boot off the HDD. Is this possible ?


I found a file on my flash disk called 'live.cfg' inside the 'syslinux' directory of the flashdrive.

I used this as a reference:
http://kemovitra.blogspot.com.au/201...r-live-cd.html

and added to following to the file:

Code:
LABEL hd0
  MENU LABEL First Hard Drive
  LOCALBOOT 0x80


________________

Thus, now the contents of "live.cfg" look like:
Code:
label live
	menu label Live
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label livefailsafe
	menu label Live (failsafe)
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal


LABEL hd0
  MENU LABEL First Hard Drive
  LOCALBOOT 0x80

label live-686-pae
	menu label Live 686-pae
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label live-686-paefailsafe
	menu label Live 686-pae (failsafe)
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal






#label floppy
#	localboot 0x00

#label disk1
#	localboot 0x80

#label disk2
#	localboot 0x81

#label nextboot
#	localboot -1

The option that I added never shows up, its in the file after I reboot, so its been saved....

tl;dr : What do I need to do to edit a bootloader on a USB drive to have the option of booting off a HDD ?

Last edited by steak1987; 07-19-2013 at 07:42 AM.
 
Old 07-19-2013, 08:07 AM   #2
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: PCLinux, Slackware
Posts: 7,027

Rep: Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309Reputation: 1309
I've never hears of TAILS, I would guess it is a Linux OS? How did you put it on the flash drive? If you used a program like unetbootin or pendrivelinux, you have a Live CD on a flash drive which makes it a read-only file system. You can edit and make changes as much as you want and everything will be gone on reboot. That's the read-only part. If you did to an actual install to the flash as is normally done on a hard drive, that is a different problem. The live.cfg file would indicate to me that you have a LiveCD, read-only filesystem.
 
Old 07-19-2013, 05:15 PM   #3
jefro
Moderator
 
Registered: Mar 2008
Posts: 15,850

Rep: Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299Reputation: 2299
I'd think you'd have syslinux instead of isolinux but it may not matter for solution.

Some people install grub (and it may be installed already and I don't know).


See this for a solution maybe. http://reboot.pro/topic/11640-syslin...al-hard-drive/
 
1 members found this post helpful.
Old 07-20-2013, 07:34 AM   #4
steak1987
Member
 
Registered: Jan 2012
Posts: 130

Original Poster
Rep: Reputation: Disabled
Tails is a linux ISO specializing in private browsing and not being tracked on the internet. I used the USB creator found on ubuntu and mint distros.

https://wiki.ubuntu.com/usb-creator

As for the drive being read only, my changes persisted across reboots, and there is a persistance file that also saves changes.....


Ill try the comments on the thread you posted and update the thread.
 
Old 07-20-2013, 07:43 AM   #5
steak1987
Member
 
Registered: Jan 2012
Posts: 130

Original Poster
Rep: Reputation: Disabled
UPDATE: I edited the syslinux cfg file, but the changes persisted past reboots, but the menu didnt show on boot:

Code:
label select_menu
       com32 ifcpu64.c32
       append menu_686-pae -- menu_686-pae -- menu_486
label menu_686-pae
       kernel vesamenu.c32
       append live686.cfg
label menu_486
       kernel vesamenu.c32
       append live486.cfg
default select_menu
prompt 0

LABEL btl
MENU LABEL Boot to Nearby Next Loader
localboot -1

LABEL btw
MENU LABEL Boot Direclty to Windows 
com32 chain.c32
append hd1 1 swap
Im not sure that is whats important in the boot process, there seem to be other files that seem to be linked to the boot menu.

"menu.cfg"

Code:
prompt 0
timeout 40

menu hshift 15
menu width 49

menu title Boot Tails
include stdmenu.cfg
include tails.cfg
and "live.cfg"

Code:
label live
	menu label Live
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label livefailsafe
	menu label Live (failsafe)
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal


LABEL hd0
  MENU LABEL First Hard Drive
  LOCALBOOT 0x80

label live-686-pae
	menu label Live 686-pae
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label live-686-paefailsafe
	menu label Live 686-pae (failsafe)
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal






#label floppy
#	localboot 0x00

#label disk1
#	localboot 0x80

#label disk2
#	localboot 0x81

#label nextboot
#	localboot -1
 
Old 07-20-2013, 07:51 AM   #6
steak1987
Member
 
Registered: Jan 2012
Posts: 130

Original Poster
Rep: Reputation: Disabled
EDIT EDIT: I updated all three of those files, to look like the following, and it worked o_O...

Hey, its messy, but im hardly complaining.

syslinux.cfg

Code:
label select_menu
       com32 ifcpu64.c32
       append menu_686-pae -- menu_686-pae -- menu_486
label menu_686-pae
       kernel vesamenu.c32
       append live686.cfg
label menu_486
       kernel vesamenu.c32
       append live486.cfg
default select_menu
prompt 0

LABEL btl
MENU LABEL Boot to Nearby Next Loader
localboot -1

LABEL btw
MENU LABEL Boot Direclty to Windows 
com32 chain.c32
append hd1 1 swap
menu.cfg
Code:
prompt 0
timeout 40

menu hshift 15
menu width 49

menu title Boot Tails
include stdmenu.cfg
include tails.cfg

LABEL btl
MENU LABEL Boot to Nearby Next Loader
localboot -1

LABEL btw
MENU LABEL Boot Direclty to Windows 
com32 chain.c32
append hd1 1 swap
live.cfg
Code:
label live
	menu label Live
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label livefailsafe
	menu label Live (failsafe)
	kernel /live/vmlinuz
	append initrd=/live/initrd.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal


LABEL hd0
  MENU LABEL First Hard Drive
  LOCALBOOT 0x80

label live-686-pae
	menu label Live 686-pae
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  quiet

label live-686-paefailsafe
	menu label Live 686-pae (failsafe)
	kernel /live/vmlinuz2
	append initrd=/live/initrd2.img boot=live config live-media=removable nopersistent noprompt timezone=Etc/UTC block.events_dfl_poll_msecs=1000 splash nox11autologin module=Tails  noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal


LABEL btl
MENU LABEL Boot to Nearby Next Loader
localboot -1

LABEL btw
MENU LABEL Boot Direclty to Windows 
com32 chain.c32
append hd1 1 swap




#label floppy
#	localboot 0x00

#label disk1
#	localboot 0x80

#label disk2
#	localboot 0x81

#label nextboot
#	localboot -1
 
  


Reply

Tags
bootloader, grub2, usb


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
Need to add Windows 7 boot option to Debian Grub boot loader VRich Linux - Newbie 3 03-05-2012 08:44 AM
How to Edit Boot Option for 2 OS install arezemi Linux - Newbie 3 04-20-2011 04:03 AM
[SOLVED] deleted option to boot windows from bootloader sumeet inani Linux - Newbie 9 08-05-2010 09:06 AM
help to edit Edit my bootloader's config file from kernel prompt jagdishpandey Linux - Kernel 5 07-03-2007 06:59 AM
Mandrake 9 - Edit boot option in grub explorer Linux - Distributions 6 02-28-2003 03:36 PM


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