LinuxQuestions.org
Visit Jeremy's Blog.
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-11-2004, 05:27 PM   #16
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47

try
Code:
cp -r /tmp/boot /
 
Old 07-11-2004, 07:21 PM   #17
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
I am just using the mv command and that works now. Well. I moved the /boot folder back to root ( / ) and uncommented the boot. I also changed it from ext 3 to ext 2. (did this earlier with qtparted) Then I mounted it and it mounted fine.

Now, when I boot I get
Grub loading 1.5.
Grub loading, please wait...
ERROR 15

Why do I get the file not found error when I put everything back the way it was supposed to be??? The file is there, this makes no sense. Any advice on fixing this is greatly appreciated. I must be close though if I got everything the way it was..

Thanks
 
Old 07-11-2004, 08:44 PM   #18
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
I think I am just going to reinstall Debian. If I do, what should I do with the /boot folder? leave it? And do I really need a boot partition? When I reinstall it, should I just get rid of it or keep it?

Thanks
 
Old 07-11-2004, 09:20 PM   #19
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
anyone?
 
Old 07-12-2004, 12:12 AM   #20
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
You need to reinstall grub and update grub.conf(menu.lst) because now your grub.conf is at a different location. There's no need to reinstall the whole thing, it's only a 2 minute job if you know what to do.
Post your current grub.conf(menu.lst) and output of "/sbin/fdisk -l" if you can't figure out how to reinstall grub.

Last edited by Demonbane; 07-12-2004 at 12:14 AM.
 
Old 07-12-2004, 02:53 AM   #21
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
Thanks.
I am still a newb, so I will post it:


# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
default 0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 5

# Pretty colours
color cyan/blue white/blue


#
# examples
#
# title Windows 95/98/NT/2000
# root (hd0,0)
# makeactive
# chainloader +1
#
# title Linux
# root (hd0,1)
# kernel /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default optons below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specifiv kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
# kopt=root=/dev/hdc5 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd0,0)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
## alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
## lockalternative=false
# lockalternative=false

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
## altoptions=(recovery mode) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
## howmany=7
# howmany=all

## ## End Default Options ##

title Debian GNU/Linux, kernel 2.6.6-1-k7
root (hd0,0)
kernel /vmlinuz-2.6.6-1-k7 root=/dev/hdc5 ro
initrd /initrd.img-2.6.6-1-k7
savedefault
boot

title Debian GNU/Linux, kernel 2.6.6-1-k7 (recovery mode)
root (hd0,0)
kernel /vmlinuz-2.6.6-1-k7 root=/dev/hdc5 ro single
initrd /initrd.img-2.6.6-1-k7
savedefault
boot

title Debian GNU/Linux, kernel 2.6.5-1-k7
root (hd0,0)
kernel /vmlinuz-2.6.5-1-k7 root=/dev/hdc5 ro
initrd /initrd.img-2.6.5-1-k7
savedefault
boot

title Debian GNU/Linux, kernel 2.6.5-1-k7 (recovery mode)
root (hd0,0)
kernel /vmlinuz-2.6.5-1-k7 root=/dev/hdc5 ro single
initrd /initrd.img-2.6.5-1-k7
savedefault
boot

title Debian GNU/Linux, kernel 2.4.25-1-386
root (hd0,0)
kernel /vmlinuz-2.4.25-1-386 root=/dev/hdc5 ro
initrd /initrd.img-2.4.25-1-386
savedefault
boot

title Debian GNU/Linux, kernel 2.4.25-1-386 (recovery mode)
root (hd0,0)
kernel /vmlinuz-2.4.25-1-386 root=/dev/hdc5 ro single
initrd /initrd.img-2.4.25-1-386
savedefault
boot

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/hdd1
#title Windows 95/98/Me
#root (hd1,0)
#savedefault
#makeactive
#chainloader +1

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



======================================
**NOTE** /sbin/fdisk -l was taken from Knoppix which runs off a cd because I couldn't get it from my hd (no gui) Not sure if this still helps or not.
======================================


Disk /dev/hdc: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdc1 * 1 12 96358+ 83 Linux
/dev/hdc2 13 134 979965 83 Linux
/dev/hdc3 135 9729 77071837+ f W95 Ext'd (LBA)
/dev/hdc5 135 9729 77071806 83 Linux

Disk /dev/hdd: 41.1 GB, 41174138880 bytes
255 heads, 63 sectors/track, 5005 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdd1 * 1 5005 40202631 c W95 FAT32 (LBA)

Last edited by r3dhatter; 07-12-2004 at 02:55 AM.
 
Old 07-12-2004, 05:55 AM   #22
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
ok boot with Knoppix, mount your Debian root partition, chroot to it, run the grub executable(/sbin/grub) to get into the grub console then try enter the following:
Code:
grub> root (hd0,2)
This should point to your root partition which now contains /boot,
 I can't exactly remember how extended partitions are handled in grub so 
if (hd0,2) didnt return your root partition type try (hd0,3).
Once you've got it right,
Code:
grub> setup (hd0)
should reinstall it back into the mbr

One last thing you need to do is edit your menu.lst and add /boot to the path of your kernels and initrd, so for example you'll need to change the first entry to
Code:
kernel /boot/vmlinuz-2.6.6-1-k7 root=/dev/hdc5 ro
initrd /boot/initrd.img-2.6.6-1-k7

Last edited by Demonbane; 07-12-2004 at 05:56 AM.
 
Old 07-12-2004, 11:00 AM   #23
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
Thanks, well I almost got there.

I got to the part where it says:
grub>

but root (hd0,2) or root (hd0,3) didn't work.
It says Error 21: Selected disk does not exist to both.

Here's are the fstab lines for my linux partitions if that helps any.
/dev/hdc2 none swap sw 0 0
/dev/hdc1 /boot ext2 defaults 0 2
/dev/hdc5 / ext3 defaults,errors=remount-ro 0 1

Almost there though, thanks.

Last edited by r3dhatter; 07-12-2004 at 11:07 AM.
 
Old 07-12-2004, 11:14 AM   #24
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
If you did chroot in Knoppix it could be that you didn't mount /dev, but anyway try using this bootdisk instead:
http://demonbane.org/grubdisk.img
Code:
dd if=grubdisk.img of=/dev/fd0
It should take you to the grub prompt once booted, and from there you can enter the commands.
 
Old 07-12-2004, 12:24 PM   #25
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
Is there an easy way to put that img on a cdrom? fdformat /dev/fd0H1440 will format but then when it does the verify thing, it says problem input/output error, could not read cylinder or something like that.
 
Old 07-12-2004, 04:11 PM   #26
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
make sure your drive and the disk itself is working properly, you don't have to format the disk since dd writes in raw mode.
 
Old 07-12-2004, 04:21 PM   #27
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
ok, I will check those.

In the meantime..
Can I make it an iso file some how? because I think my floppy drive broke..it used to work under knoppix and now it doesn't.

EDIT::Nevermind, it seems it was just the floppies that were broken. Looks like they broke after I formatted them. oh well. I will try again with some others.

Last edited by r3dhatter; 07-12-2004 at 04:31 PM.
 
Old 07-12-2004, 04:47 PM   #28
r3dhatter
Member
 
Registered: Dec 2003
Distribution: Debian (testing)
Posts: 210

Original Poster
Rep: Reputation: 30
Cool, I got the grubdisk.img on a floppy. It boots, but when I do root (hd0,2) it says:

Filesystem type unknown, partition type 0xf

root (hd0,3) gives no partition found so its not on this one.


It may have something to do with when I used qtparted to format the /boot partition as ext 2 because after I did that, all I did was change ext 3 to ext 2 in the fstab.


It seems like I hit problems with every small step of the way to fixing it...

Last edited by r3dhatter; 07-12-2004 at 04:52 PM.
 
Old 07-12-2004, 09:28 PM   #29
vectordrake
Senior Member
 
Registered: Nov 2003
Location: NB,Canada
Distribution: Something alpha or beta, binary or source...
Posts: 2,280
Blog Entries: 4

Rep: Reputation: 47
If your partitions are on hdc, you'll never get booted unless you point to them. Remember the grub numbering goes with the # hard disks in the machine. So, if you have a hard drive at /dev/hda and you're trying to boot /dev/hdc1, then you'll have to boot
Code:
root (hd1,0)
to reflect hard disk #2 partition#1.

That should work.
 
  


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
Java Array's.... Making An array bigger??? Tru_Messiah Programming 11 08-17-2016 02:45 PM
Making a partition bigger Tsukasa7 Linux - Newbie 8 10-24-2005 01:41 PM
making linux partition bigger? M O L8ingN2dust Linux - Newbie 1 03-23-2005 04:47 PM
Making a partition bigger rverlander Linux - General 8 07-19-2002 09:49 PM
making patitions bigger than one harddrive saavik Linux - Software 3 11-10-2001 08:59 AM


All times are GMT -5. The time now is 01:58 PM.

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