WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Configure Grub for TC in a single directory in an existing Linux installation  (Read 6040 times)

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
I read in the installation instructions:

Note: If you already have a Linux System booting, then you do not need to make a partition for Tiny Core! Tiny Core can run in a single directory in your existing Linux installation. To do so, at step 1, uncheck the option to "Install boot loader". At step 2, select an existing partition, and at Step 3, do not format it. Upon completion you will need to manually configure your existing boot loader.

Where can I find instructions for "Upon completion you will need to manually configure your existing boot loader. " I could not find those on this website.

Georg

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
Where can I find instructions for "Upon completion you will need to manually configure your existing boot loader. " I could not find those on this website.

By looking at the man pages for your boot loader and your existing configuration files you should be able to figure it out?

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
Well, I had hoped for some more detailed instructions. Maybe an example grub configuration file and some steps how to modify that to include a selection entry of the TC directory in there  and what to look out for.

Georg

gordonselfish

  • Guest
Question 1) so how about telling me what you mean by grub----legacy or grub2

Question 2) On your existing system do you have an independent /boot partition so for your host grub
your kernel or linux line does not show /boot/grub/blah blah .....but /grub/blah blah
or is boot a sub-folder to / partition?

Question 3) on which partition do you intend to have TC on

Question 4) It would be handy to see a list of your partitions and what formats they are

I have no experience of putting TC onto anything other than real Linux partitions
ext3 or 4.

good luck

 

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
Maybe you could copy and paste the contents of one of the following files here:

grub: /mnt/sda1/boot/grub/menu.lst

grub2: /mnt/sda1/boot/grub/grub.cfg

[substitute your actual partition for sda1]

..which would make it easier to suggest what you should do next

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
I have a partition with SUSE Linux on my PC. This is the partition I like to add TC to since there is sufficient space left. The menu.lst looks like this:

# Modified by YaST2. Last modification on Do Feb  9 19:16:39 CET 2012
# THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader
# For the new kernel it try to figure out old parameters. In case we are not able to recognize it (e.g. change of flavor or strange install order ) it it use as fallback installation parameters from /etc/sysconfig/bootloader

timeout 8
default 4
gfxmenu (hd0,3)/boot/message
##YaST - activate

###Don't change this comment - YaST2 identifier: Original name: linux###
title Desktop -- openSUSE 12.1 - 3.1.0-1.2
    root (hd0,3)
    kernel /boot/vmlinuz-3.1.0-1.2-desktop root=/dev/sda4 resume=/dev/disk/by-id/ata-SAMSUNG_HD502IJ_S13TJ90Q817745-part3 splash=silent  showopts vga=0x31a
    initrd /boot/initrd-3.1.0-1.2-desktop

###Don't change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe -- openSUSE 12.1 - 3.1.0-1.2 (desktop)
    root (hd0,3)
    kernel /boot/vmlinuz-3.1.0-1.2-desktop root=/dev/sda4 showopts ide=nodma apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 x11failsafe vga=0x31a nomodeset
    initrd /boot/initrd-3.1.0-1.2-desktop

###Don't change this comment - YaST2 identifier: Original name: linux###
title openSUSE 12.1 - 3.1.0-1.2
    root (hd0,3)
    kernel /boot/vmlinuz-3.1.0-1.2-default root=/dev/sda4 resume=/dev/disk/by-id/ata-SAMSUNG_HD502IJ_S13TJ90Q817745-part3 splash=silent  showopts vga=0x31a nomodeset
    initrd /boot/initrd-3.1.0-1.2-default

###Don't change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe -- openSUSE 12.1 - 3.1.0-1.2 (default)
    root (hd0,3)
    kernel /boot/vmlinuz-3.1.0-1.2-default root=/dev/sda4 showopts ide=nodma apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 x11failsafe vga=0x31a nomodeset
    initrd /boot/initrd-3.1.0-1.2-default

title Windows
    rootnoverify (hd0,0)
    makeactive
    chainloader +1


The following partitions are present:
sda1 NTFS
sda2 Extended
sda3 SWAP
sda4 EXT3
sda5 NTFS
sda6 FAT32
sda7 FAT16
sda8 FAT32

So as far as I understand TC will install from the CD to a directory on sda3. How would the entry for that in menu.lst look like so I can boot from the GRUB menu on boot?

Georg

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
You need to add something like:
Code: [Select]
title tinycore
    root (hd0,3)
    kernel /boot/vmlinuz
    initrd /boot/core.gz

Note that (hd0,3) is sda4

gordonselfish

  • Guest
Juanito is very nice.

I being more selfish would suggest

1) Whenever suse updates your kernel or grub, a bootloader script appears to want to over-write your existing menu.lst
---so make notes so you can re-edit it after this scenario occurs please

2) The TC kernel and initrd (=core.gz) can be put at the root of your sda4 so it could look like
title tinycore
    root (hd0,3)
    kernel /vmlinuz tce=sda4 (plus other bootcodes if needed)
    initrd /core.gz

that way you can keep simple kernel name vmlinuz in case you ever want to sym link your suse
from vmlinuz-some-long name  to vmlinuz  ---in your boot/grub folder

good luck


Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
Thank you very much for your help!

As gordonselfish expected, SUSE has already put a sym link called vmlinuz to their suse vmlinuz-3.1.0-1.2-desktop file into the boot directory. I do not know if this is needed by any program included within SUSE.

The menu in the TC installer only offers to select the path for core.gz:
http://tinycorelinux.net/install.html

Will that also change the path for vmlinux?

Georg

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
The installer is asking for the source path to core.gz, not the destination path.
Core.gz and vmlinuz are in the same directory on the CD.

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
Re: Configure Grub for TC in a single directory in an existing Linux installation
« Reply #10 on: September 14, 2013, 11:02:00 AM »
I see. If I make a directory sda4/tinycore/boot on my existing partition using SUSE can I somehow select that as the destination directory for TC when installing from the CD?

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
Re: Configure Grub for TC in a single directory in an existing Linux installation
« Reply #11 on: September 14, 2013, 01:20:45 PM »
After apparently frustrating all experts with my questions I found this image:
http://distro.ibiblio.org/tinycorelinux/architecture.html
and decided to try it manually. This is what I did:

1. boot SUSE Linux in sda4
2. log in as root
3. insert the CD and copy core.gz from the CD to sda/boot
4. copy vmlinuz from the CD to sda/boot giving it the new name vmlinuz-tce
5. enter the grub directory and add this entry into the menu.lst file:
title TinyCoreLinux
  root(hd0,3)
  kernel /boot/vmlinuz-tce vga=0x31a nomodeset
  initrd /boot/core.gz
6. copy the cde directory from the CD to /
7. make a tce directory in / copying the files and directory from cde to it

Then boot and select TinyCoreLinux and it works!

Now my question: does TC use the cde or the tce directory now and which one can I erase? What determines which directory TC will use?

Thank you for your help!

Georg


Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14815
Re: Configure Grub for TC in a single directory in an existing Linux installation
« Reply #12 on: September 14, 2013, 01:28:44 PM »
Use the /tce directory

gordonselfish

  • Guest
Re: Configure Grub for TC in a single directory in an existing Linux installation
« Reply #13 on: September 14, 2013, 07:52:44 PM »
OFFTOPIC
Quote
nomodeset

Have you had video troubles with Suse?
Do you have a nvidia or radeon chipset?

On first boot, you are only going to find TC with Xvesa or vesa standard graphics so no need for that boot code.

Since I know you have read the core concepts, you know you don't have to load any video card driver other than the one you want.
We don't force a whole to lot load. So no problems with nouveau or radeon etc.

Offline georgp24

  • Jr. Member
  • **
  • Posts: 58
Re: Configure Grub for TC in a single directory in an existing Linux installation
« Reply #14 on: September 15, 2013, 02:05:27 AM »
Yes, I had video trouble with my SUSE version, IIRC the screen turned black or similar. Then I read in a SUSE forum that this problem was well known and the nomodeset parameter would cure it - what it did. So I added that here thinking this would do no harm with TC.