LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Gentoo help plzzzzzz (https://www.linuxquestions.org/questions/linux-newbie-8/gentoo-help-plzzzzzz-724398/)

vibinlakshman 05-07-2009 08:44 AM

Gentoo help plzzzzzz
 
i had installed gentoo thru live cd , i just downloaded the image from the site and performed installation , everything was fine , installation success message came after long 20-25 min.
But one problem i cudnt get my gentoo start , my grub doesnt show any gentoo, actually i have Ubuntu , so GRUB contains windows and ubuntu flavours .

I had edited in /boot/grub/menu.lst like this
title Gentoo Linux 2.6.24-r5
# Partition where the kernel image (or operating system) is located
root (hd0,2)
kernel /boot/kernel-2.6.24-gentoo-r5 root=/dev/sda3

actually i just copied this from gentoo guide , and edited my root to (hd0,2)
i dont knw much about that second root so just left it with root=/dev/sda3
While selecting i get "error 13"

My gentoo is in (hd0,2) and my GRUB in (hd0,4)

So based on my assumption i dont need to copy my kernel image from cd to my location right !! Its already done by the installation , right guys

So plzz help me form this situation!!!!! Looks simpler for u , bizzare for me

trist007 05-07-2009 09:22 AM

I remember I had the same problem a while back, try

kernel /boot/kernel-2.6.24-gentoo-r5 root=/dev/sda5

or

keep kernel /boot/kernel-2.6.24-gentoo-r5 root=/dev/sda3
but change to
root (hd0,4)

it's one of those, good luck.

vibinlakshman 05-07-2009 09:36 AM

Quote:

Originally Posted by trist007 (Post 3533403)
I remember I had the same problem a while back, try

kernel /boot/kernel-2.6.24-gentoo-r5 root=/dev/sda5

or

keep kernel /boot/kernel-2.6.24-gentoo-r5 root=/dev/sda3
but change to
root (hd0,4)

it's one of those, good luck.

oops neither didnt work ... Have u installed thru livecd , great man , i have been trying for past one month , i think i need to install it in conventional way ..

i92guboj 05-07-2009 09:53 AM

I suggest installing the manual way, which is the only supported one. Anyway, you can consider it as an introductory course to Gentoo. If you can't read the handbook and go through it then you are going to have lots of problems to use Gentoo (you won't be able to administer it anyway). Having the will to read the handbook is just part of the process.

About your problem, did you edit the grub.conf in the Gentoo partition? Because if that's so then you did wrong. You need to edit the one in the ubuntu partition, since it's the one that's being used. That is, unless you have a shared independent /boot partition that you use for both Oses.

vibinlakshman 05-08-2009 06:28 AM

Quote:

Originally Posted by i92guboj (Post 3533439)
I suggest installing the manual way, which is the only supported one. Anyway, you can consider it as an introductory course to Gentoo. If you can't read the handbook and go through it then you are going to have lots of problems to use Gentoo (you won't be able to administer it anyway). Having the will to read the handbook is just part of the process.

About your problem, did you edit the grub.conf in the Gentoo partition? Because if that's so then you did wrong. You need to edit the one in the ubuntu partition, since it's the one that's being used. That is, unless you have a shared independent /boot partition that you use for both Oses.
Why that failed to mount /boot came ?

I'm not able to perform "make menuconfig" after chroot operation ,Is there any way to get menuconfig
For time being i made use of genkernel and executed genkernel all and this shows
vibin-laptop linux # zcat /proc/config.gz > /usr/share/genkernel/x86/kernel-config-2.6
bash: /bin/zcat: /bin/sh: bad interpreter: No such file or directory
vibin-laptop linux # /bin/zcat /proc/config.gz > /usr/share/genkernel/x86/kernel-config-2.6
bash: /bin/zcat: /bin/sh: bad interpreter: No such file or directory
vibin-laptop linux # genkernel all
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
egrep: /proc/mounts: No such file or directory
mount: error while loading shared libraries: libblkid.so.1: cannot open shared object file: No such file or directory
* WARNING: Failed to mount /boot!

* kernel: >> Running mrproper...
* ERROR: Failed to compile the "mrproper" target...

* -- Grepping log... --


* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
* WARNING: Failed to mount /boot!
--
make[2]: /bin/sh: Command not found
make: /bin/sh: Command not found
make: /bin/sh: Command not found
make: /bin/sh: Command not found
make: /bin/sh: Command not found
make: *** [clean] Error 127
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* ERROR: Failed to compile the "mrproper" target...

* -- End log... --

* Please consult /var/log/genkernel.log for more information and any
* errors that were reported above.

* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* /var/log/genkernel.log so that your issue can be dealt with effectively.
*
* Please do *not* report compilation failures as genkernel bugs!
*

so i foud out that it lacks /bin/sh but /bin/bash exist , so i done a weird operation i think so , that is i copied form my Ubuntu machine /bin/sh to /mnt/gentoo/bin , so after that i get this result

ls /bin/sh
/bin/sh
vibin-laptop / # genkernel all
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
egrep: /proc/mounts: No such file or directory
mount: error while loading shared libraries: libblkid.so.1: cannot open shared object file: No such file or directory
* WARNING: Failed to mount /boot!

* kernel: >> Running mrproper...
* config: Using config from /usr/share/genkernel/x86/kernel-config-2.6
* Previous config backed up to .config.bak
* >> Running oldconfig...
* kernel: >> Cleaning...
* kernel: >> Making dependencies...
* ERROR: Failed to compile the "prepare" target...

* -- Grepping log... --


* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
* WARNING: Failed to mount /boot!
--
Second extended fs support (EXT2_FS) [Y/n/?] y
Ext2 extended attributes (EXT2_FS_XATTR) [N/y/?] (NEW) aborted!

Console input/output is redirected. Run 'make oldconfig' to update configuration.

make[2]: *** [silentoldconfig] Error 1
make[1]: *** [silentoldconfig] Error 2
*** Warning: make dep is unnecessary now.
--
Second extended fs support (EXT2_FS) [Y/n/?] y
Ext2 extended attributes (EXT2_FS_XATTR) [N/y/?] (NEW) aborted!

Console input/output is redirected. Run 'make oldconfig' to update configuration.

make[2]: *** [silentoldconfig] Error 1
make[1]: *** [silentoldconfig] Error 2
make: *** No rule to make target `include/config/auto.conf', needed by `include/config/kernel.release'. Stop.
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* ERROR: Failed to compile the "prepare" target...

* -- End log... --

* Please consult /var/log/genkernel.log for more information and any
* errors that were reported above.

* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* /var/log/genkernel.log so that your issue can be dealt with effectively.
*
* Please do *not* report compilation failures as genkernel bugs!
*

Plz help me i'm stucked , i'm eagerly waiting to get Gentoo installed .
Why these error came , is there any way to get /bin/sh installed after that i need to perform genkernel all operation .
I think one step more to get gentoo installed

i92guboj 05-08-2009 09:01 AM

You are failing at least on one of the steps.

Did you uncompress the stage3 file correctly? Did you mount the /proc and /dev directories into the gentoo partition? Did you chroot correctly?

Be very careful when doing these steps and be alert for any error. Make sure that you check the integrity of the stage3 file as well with md5sum. A corrupt file will do you no good.

You have to follow the handbook step-by-step, and if one step doesn't work (or you don't understand it) don't continue blindly, come hear and ask for help.

vibinlakshman 05-08-2009 11:14 AM

Quote:

Originally Posted by i92guboj (Post 3534586)
You are failing at least on one of the steps.

Did you uncompress the stage3 file correctly? Did you mount the /proc and /dev directories into the gentoo partition? Did you chroot correctly?

Be very careful when doing these steps and be alert for any error. Make sure that you check the integrity of the stage3 file as well with md5sum. A corrupt file will do you no good.

You have to follow the handbook step-by-step, and if one step doesn't work (or you don't understand it) don't continue blindly, come hear and ask for help.

root@vibin-laptop:~# mount /dev/sda2 /mnt/gentoo/
root@vibin-laptop:~# mount -t proc none /mnt/gentoo/proc/
root@vibin-laptop:~# mount -o bind /dev /mnt/gentoo/dev/
root@vibin-laptop:~# chroot /mnt/gentoo/ /bin/bash
vibin-laptop / # ls /bin/sh
/bin/sh
vibin-laptop / # genkernel all
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
mount: error while loading shared libraries: libblkid.so.1: cannot open shared object file: No such file or directory
* WARNING: Failed to mount /boot!

* kernel: >> Running mrproper...
* config: Using config from /usr/share/genkernel/x86/kernel-config-2.6
* Previous config backed up to .config.bak
* >> Running oldconfig...
* kernel: >> Cleaning...
* >> Compiling 2.6.28-gentoo-r5 bzImage...
* >> Compiling 2.6.28-gentoo-r5 modules...
* ERROR: Failed to compile the "modules" target...

* -- Grepping log... --


* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
* WARNING: Failed to mount /boot!
--
CC lib/crc32.o
LD lib/built-in.o
AR lib/lib.a
LD vmlinux.o
MODPOST vmlinux.o
WARNING: modpost: Found 1 section mismatch(es).
--

The present kernel configuration has modules disabled.
Type 'make config' and enable loadable module support.
Then build a kernel with module support enabled.

make: *** [modules] Error 1
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* ERROR: Failed to compile the "modules" target...

* -- End log... --

* Please consult /var/log/genkernel.log for more information and any
* errors that were reported above.

* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* /var/log/genkernel.log so that your issue can be dealt with effectively.
*
* Please do *not* report compilation failures as genkernel bugs!
*
vibin-laptop / # ln -sf /bin/bash /bin/sh
vibin-laptop / # genkernel all
* Gentoo Linux Genkernel; Version 3.4.10
* Running with options: all

* Linux Kernel 2.6.28-gentoo-r5 for x86...
mount: error while loading shared libraries: libblkid.so.1: cannot open shared object file: No such file or directory
* WARNING: Failed to mount /boot!

* kernel: >> Running mrproper...

i92guboj 05-08-2009 11:22 AM

Did you install the proper stage3 file? Are you sure it was correct? The contents of the partition seems to be completely messed up.

vibinlakshman 05-08-2009 10:51 PM

Quote:

Originally Posted by i92guboj (Post 3534708)
Did you install the proper stage3 file? Are you sure it was correct? The contents of the partition seems to be completely messed up.

Now understood this line of command makes problem for me

zcat /proc/config.gz > /usr/share/genkernel/x86/kernel-config
gzip: /proc/config.gz: No such file or directory

i'm not able to perform , this what all mess started i think .. , i had mounted /proc but not able to view config.gz , thats why i'm not able to perform "genkernel all "

See below in my /proc there is no config.gz , so how will genkernel calls default kernel configuration?
cd proc/
vibin-laptop proc # ls
1 2974 5017 55 5701 5996 interrupts scsi
10 3 5027 5502 5702 6 iomem self
11 3349 5028 5505 5709 6010 ioports slabinfo
1345 4 5043 5506 5714 7 irq stat
1346 4403 5076 5510 5715 8 kallsyms swaps
1407 4404 5083 5513 5716 9 kcore sys
1457 4407 5084 5515 5717 acpi key-users sysrq-trigger
1459 4408 51 5521 5766 asound kmsg sysvipc
1460 4409 5116 5536 5768 buddyinfo kpagecount timer_list
155 4595 5138 5541 5774 bus kpageflags timer_stats
159 4626 5157 5585 5778 cgroups latency_stats tty
2 4628 5162 5599 5781 cmdline loadavg uptime
204 4719 5174 5600 5793 cpuinfo locks version
205 4770 5177 5605 5795 crypto meminfo version_signature
206 4772 5181 5672 58 devices misc vmallocinfo
2176 4795 5197 5683 5824 diskstats modules vmcore
2180 4817 52 5684 5869 dma mounts vmstat
2181 4818 5231 5685 5870 dri mtrr zoneinfo
2318 4865 5259 5687 5873 driver net
248 4932 5340 5696 5874 execdomains pagetypeinfo
249 4935 54 5697 5897 fb partitions
2492 4936 5445 5699 5909 filesystems sched_debug
2884 5 5462 57 5965 fs schedstat

i92guboj 05-08-2009 11:25 PM

That's very strange. It should be there. But well, I really never tried to use genkernel, in like 6 years of Gentoo I've built my kernels as I always did before.

One thing that you could try is to copy it from the /proc of the cdrom itself, instead of the /proc of the chroot. Assuming that you mounted the gentoo partition in /mnt/gentoo as you said above, the process would be this way:
  • run "exit" to exit the chroot
  • zcat /proc/config.gz > /mnt/gentoo/usr/share/genkernel/x86/kernel-config
  • chroot /mnt/gentoo/ /bin/bash
  • env-update && source /etc/profile
    # you are on the chroot again

Maybe there's a valid config.gz there. I have no idea why it doesn't appear on the chroot though. If it doesn't appear there I guess that you will need to pick it from elsewhere.

vibinlakshman 05-08-2009 11:34 PM

Quote:

Originally Posted by i92guboj (Post 3535175)
That's very strange. It should be there. But well, I really never tried to use genkernel, in like 6 years of Gentoo I've built my kernels as I always did before.

One thing that you could try is to copy it from the /proc of the cdrom itself, instead of the /proc of the chroot. Assuming that you mounted the gentoo partition in /mnt/gentoo as you said above, the process would be this way:
  • run "exit" to exit the chroot
  • zcat /proc/config.gz > /mnt/gentoo/usr/share/genkernel/x86/kernel-config
  • chroot /mnt/gentoo/ /bin/bash
  • env-update && source /etc/profile
    # you are on the chroot again

Maybe there's a valid config.gz there. I have no idea why it doesn't appear on the chroot though. If it doesn't appear there I guess that you will need to pick it from elsewhere.

Yea one day i'll also compile kernel myself like u buddy , but before i need to learn that why looked for better linux
But i didnt understand one thing what to copy from cdrom , i dont have anything like that in my cd drive , or r u mentioning something else?

i92guboj 05-08-2009 11:58 PM

Quote:

Originally Posted by vibinlakshman (Post 3535178)
Yea one day i'll also compile kernel myself like u buddy , but before i need to learn that why looked for better linux
But i didnt understand one thing what to copy from cdrom , i dont have anything like that in my cd drive , or r u mentioning something else?

Sorry, from where are you installing? Are you booting from another distro that's already installed or from the gentoo livecd? I mean, before you chroot you have to boot another linux.

vibinlakshman 05-09-2009 01:09 AM

Quote:

Originally Posted by i92guboj (Post 3535195)
Sorry, from where are you installing? Are you booting from another distro that's already installed or from the gentoo livecd? I mean, before you chroot you have to boot another linux.

I'm doing this from my Ubuntu 8.10 , so any problem , but i come to know that gentoo can be installed from any distro , right ? Any problem while doing so ?
Can u specify actually where the kernel configuration stored in Ubuntu , coz i think that might be the problem , zcat i think didnt worked coz of that ?

i92guboj 05-09-2009 07:49 AM

Quote:

Originally Posted by vibinlakshman (Post 3535221)
I'm doing this from my Ubuntu 8.10 , so any problem , but i come to know that gentoo can be installed from any distro , right ? Any problem while doing so ?

Sorry for the delay, even I have to sleep sometimes ;)

No problem. Maybe ubuntu kernels doesn't have the option to export the config in /proc/config.gz. Can you look into the /boot directory of your ubuntu installation? Maybe the config files are also stored there. Another common place could be /etc/kernels/ or something similar. Check these locations and see if you can find any *config* file around. If not then I will try to pick a generic config file form a gentoo cd or something for you.

vibinlakshman 05-09-2009 09:51 AM

Quote:

Originally Posted by i92guboj (Post 3535407)
Sorry for the delay, even I have to sleep sometimes ;)

No problem. Maybe ubuntu kernels doesn't have the option to export the config in /proc/config.gz. Can you look into the /boot directory of your ubuntu installation? Maybe the config files are also stored there. Another common place could be /etc/kernels/ or something similar. Check these locations and see if you can find any *config* file around. If not then I will try to pick a generic config file form a gentoo cd or something for you.

Its ok , now everything worked fine .. But still making problem .. This Gentoo is really a hard nut

What i'm now performing is "make menuconfig" options , and i selected whatever options which i feel suitable and make && make module_install everything worked fine , i think so , but whenever i select an option i couldnt figure whether that particular option was selected or not , leave it for a moment , but performed make && make module_install
And i've performed everything step by step from handbook
Now the problem is GRUB
I had emerged GRUB , but i thought why shud i edit gentoo grub , i've my Ubuntu GRUB and i edited that file

title Gentoo Linux 2.6.28
# Partition where the kernel image (or operating system) is located
root (hd0,2)
kernel /boot/gentoo-2.6.28 root=/dev/sda3

/boot/gentoo-2.6.28 that i copied image , OK . and root(hd0,2) where i made my GENTOO , root i just copied from handbook , coz i dont knw much abt that

Still not working .........!!!!!!!!!!!!!!!!!!


All times are GMT -5. The time now is 04:14 PM.