LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Error 15 : File not found (https://www.linuxquestions.org/questions/linux-newbie-8/error-15-file-not-found-715702/)

hifun 03-31-2009 02:56 AM

Error 15 : File not found
 
Hi,
I am using Fedora-8 and currently learning about grub.
On booting my system,in grub shell I typed
find /boot/grub/stage1
It flashes an error
Error 15: File not found
Then I simply boot my system and checked stage1 file.It was there.
Why it was not showing in grub shell?

alan_ri 03-31-2009 04:17 AM

Welcome to LQ!
That would be because that file is hidden from GRUB or you're not running that command as root..You can run
Code:

grub> unhide (hd0) 
grub> find /boot/grub/stage1

Maybe you'll need to change the code to (hd0,x).It should show something then.
This could be because you maybe have Windoze on some other partition and not on the first one.

hifun 03-31-2009 06:29 AM

Thanks alan_ri,
I am running this command as superuser
I've tried your solution. While unhide (hd0),an error was falsing.
Error 30: Invalid Argument
My Windows is on first partition ie (hd0,0).
How to solve this?:confused:

alan_ri 03-31-2009 06:45 AM

Try
Code:

grub> unhide (hd0,0)
Or use Fedora's partition number in the code,but remember,for example /dev/hda5 would be (hd0,4).

hifun 03-31-2009 07:07 AM

alan_ri
while unhide (hd0,4) an error was shown
Error 5: Partition table invalid or corrupt
One magic happened:
before running unhide, on fdisk -l all /dev/sda1 to /dev/sda5 was there, but after running unhide, fdisk -l only showing upto /dev/sda4,with and error
Warning: invalid flag 0x0000 of partition table 5 will be corrected by w(rite)
Then I did fdisk /dev/sda and press w(rite) , it again gave an error
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.

What is this?
I think, my system is full of errors and warnings.:scratch:

alan_ri 03-31-2009 07:33 AM

Please reboot and post the output of
Code:

fdisk -l
and
Code:

gedit /boot/grub/grub.conf

hifun 03-31-2009 09:10 AM

alan_ri,
strange things are happening:confused:
I rebooted my system and after linux kernel uncompressed, hell lot of errors were there.
Code:

monut: Could not find the filesystem '/dev/mount
setuproot: moving /dev/failed :No such file or directory
setuproot: error mounting /proc :No such file or directory
setuproot: error mounting /sys :No such file or directory
switchroot: mount failed :No such file or directory

and system hangs.
I am posting this from windows_XP:o, how to fix the problem?

alan_ri 03-31-2009 10:14 AM

You wrote a new partition table with fdisk and you messed up some things.That's why it's not good to use commands that you don't understand completly what they can do.
Do you have some program in Windoze to see your current hard disk state (partitions) and can you say how your disk was partitioned before this?
On what partition was Fedora installed and did you maybe had a separate /boot partition?

hifun 04-01-2009 10:52 PM

alan_ri,
I have no such software. I have one ext2-fsd which shows linux partition on windows.But now, it says unavailable location to linux and swap partition.But yes, seprate /boot partition is good. I can still see /boot in windows.
How can I get back my linux.

alan_ri 04-02-2009 01:13 AM

Have a look here;1,2.Remember,you must know where is your /root partition and point Grub to it,so that Fedora would run,also you must know where is /boot partition,so that Grub would be installed on the right partition.Maybe you should install Grub to MBR.
Have a look here,too.

hifun 04-02-2009 03:36 AM

alan_ri,
Thank you man. Testdisk worked. :)
My grub need not be reinstalled as only partition table was corrupted( only pointers were lost may be) , i think. One more question,while installing grub stage1 is installed in MBR, does this file do anything with 64 bytes of partition table?:confused:
And yes, my previous query was still not solved., ie GRUB shell still not able to find /boot/grub/stage1.:confused:

hifun 04-02-2009 04:00 AM

alan_ri,
Also I didnt understand working of Test-Disk. It was showing 4 partitions . I analysed with it and re-write partition table. Then there were 5. How ?

alan_ri 04-02-2009 04:06 AM

Grub stage1 only points to Grub stage2.
Have you tried
Code:

find /stage1
It was 5 because you said that you had 5 before.

hifun 04-02-2009 06:37 AM

alan_ri,
Code:

grub> find /stage1

Error 15: File not found

grub> find /boot/grub/stage1

Error 15: File not found

after exiting from grub
Code:

[root@localhost ~]# ls -ld /boot/grub/stage1
-rw-r--r-- 1 root root 512 Apr  2 13:53 /boot/grub/stage1
[root@localhost ~]#

Now where's the problem ?:confused:

alan_ri 04-02-2009 07:00 AM

Please post the output of /boot/grub/grub.conf.
Also ls -l in /boot/grub directory and fdisk -l.


All times are GMT -5. The time now is 09:21 AM.