Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Multiple kernel related problems (grub2, X, upgrading)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Cecillian
n00b
n00b


Joined: 28 Jul 2015
Posts: 14

PostPosted: Thu Jun 02, 2016 5:53 am    Post subject: Multiple kernel related problems (grub2, X, upgrading) Reply with quote

So, I broke a bunch of things after doing

Code:
#emerge -puavDN @world


Because it updated my nvidia drivers, which went fine I think, but after the update, portage mentioned something about changing something in xorg.conf being necessary, and I followed that and restarted my computer, when I logged in and typed startx, I got this

Code:

    $ tail -n 14 /var/log/Xorg.0.log
    [ 87728.297] (II) Module "ramdac" already built-in
    [ 87728.313] (EE) NVIDIA: Failed to initialize the NVIDIA kernel module. Please see the
    [ 87728.313] (EE) NVIDIA:     system's kernel log for additional error messages and
    [ 87728.313] (EE) NVIDIA:     consult the NVIDIA README for details.
    [ 87728.313] (EE) No devices detected.
    [ 87728.313] (EE)
    Fatal server error:
    [ 87728.313] (EE) no screens found(EE)
    [ 87728.313] (EE)
    Please consult the The X.Org Foundation support
             at http://wiki.x.org
     for help.
    [ 87728.313] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
    [ 87728.313] (EE)


It says to check the system's kernel log but there are no files in /var/log/kernel/ so I'm not quite sure what it's talking about.


I figured since I was going to be working in the console I might as well fix the resolution into something I could work with, and I accidentally switched from legacy to grub2, but I got grub2 to have the right resolution which doesnt fix the original problem at all. In fact, I don't even have any /dev/fb0 files or whatever to work with so things like fbterm just tell that it can't open the framebuffer device.
However, I somehow installed grub2 wrong and it was looking for grub.cfg in the wrong place. I fixed that by typing something along the lines of configfile (hd0,gpt2)/boot/grub/grub.cfg.
That let me boot back in again where I decided to emerge world again. That pulled in kernel 4.4.6 and I figured I should switch to it in the midst of this, but it was my first kernel upgrade so I botched it somehow. I built it and did a make install and such and while /boot/ is full of exclusively 4.4.6 kernel files uname -r still tells me I'm on 4.0.5-gentoo so I'm a bit confused with that. Also after doing that, my grub2 error message changed to VFS 0,0 unknown block which is also remedied by dropping to the grub2 command line and typing configfile (hd0,gpt2)/boot/grub/grub.cfg.

I've found this great boot configuration script on ubuntu's forums while looking for a solution: http://ubuntuforums.org/showthread.php?t=1291280

Results here: http://pastebin.ca/3615512 (expires june 9th 2016)

I really don't mean to have any of you necessarily solve my problems for me, but if you could at least point me in the right direction that'd be great. I can provide any other info necessary ofc.
Back to top
View user's profile Send private message
DawgG
l33t
l33t


Joined: 17 Sep 2003
Posts: 814

PostPosted: Thu Jun 02, 2016 11:03 am    Post subject: Reply with quote

the nvidia-binary-drivers need to match your kernel-version. _after_ every kernel-upgrade you have to re-emerge them for the new kernel-version - even if there is no new version of the drivers.
the symlink /usr/src/linux has to point to the kernel-version you want to install the nvidia-drivers for (there is a usflag symlink for sys-kernel/gentoo-sources which automatically set this symlink, but better check again.)
so if you have booted kernel 4.0.5 and want nvidia-drivers for it, set this symlink accordingly and (re-)emerge nvidia-drivers. if the sources are freshly installed they have to be configured (and compiled i think) before nvidia-drivers can be emerged. change into their directory (if the symlink is set correctly, this is /usr/src/linux; if not, best set it), then do
Code:
zcat /proc/config.gz >.config
make oldconfig
make all
(assuming /proc/config.gz is enabled in your running kernel). after this is finished,
Code:
emerge -av nvidia-drivers
and if it was successful, do
Code:
modprobe nvidia
and check if the nvidia-module is loaded with
Code:
lsmod | grep nvidia
then you should be able to start X.
if you run kernel 4.0.5 and have emerged the drivers this way, you can emerge them the same way for a different kernel-version before rebooting.
also if you have not deleted the kernel-image in /boot and its modules in /lib/modules/<VERSION> then you should be able to start the previous kernel with all modules intact. i always keep at least the previous version - just in case.
no need to re-emerge world.
GOOD LUCK!
_________________
DUMM KLICKT GUT.
Back to top
View user's profile Send private message
ct85711
Veteran
Veteran


Joined: 27 Sep 2005
Posts: 1696

PostPosted: Thu Jun 02, 2016 3:27 pm    Post subject: Reply with quote

Quote:
I built it and did a make install and such and while /boot/ is full of exclusively 4.4.6 kernel files uname -r still tells me I'm on 4.0.5-gentoo so I'm a bit confused with that.


Chances are for this, that you did not mount your boot partition when you copied/installed your new kernel to /boot after compiling.

Note: Just because you don't mount a partition, does not mean you won't see the mount location, as in you will still see a /boot (but it's contents would be different when you mount the boot partition)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum