Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to initial nvidia successfully?
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sun Jan 26, 2020 9:29 am    Post subject: How to initial nvidia successfully? Reply with quote

Code:

[  9967.404] (EE) NVIDIA: Failed to initialize the NVIDIA kernel module. Please see the
[  9967.405] (EE) NVIDIA:     system's kernel log for additional error messages and
[  9967.405] (EE) NVIDIA:     consult the NVIDIA README for details.
[  9967.415] Number of created screens does not match number of detected devices.
  Configuration failed.
[  9967.415] (EE) Server terminated with error (2). Closing log file.


[code]
modprob nvidia
[\code]

[code]
modprobe: ERROR: could not insert 'nvidia'; No such device
[\code]
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 23552
Location: here

PostPosted: Sun Jan 26, 2020 9:59 am    Post subject: Reply with quote

You can post dmesg with wgetpaste? You have followed instructions in related wiki page?
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Mon Jan 27, 2020 3:21 pm    Post subject: nvidia initial failed Reply with quote

http://dpaste.com/2SJCWAW
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Mon Jan 27, 2020 3:26 pm    Post subject: Reply with quote

Freed,

Code:
[   10.507043] nouveau ...

You may use nouveau or nvidia-drivers but not both.
nouveau has loaded first and grabbed the nvidia video card, so the NVIDIA kernel module cannot load.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 23552
Location: here

PostPosted: Mon Jan 27, 2020 3:52 pm    Post subject: Reply with quote

In linked wiki page
https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers#Kernel wrote:
Important
Now make sure the nouveau driver is disabled:

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Tue Jan 28, 2020 2:48 am    Post subject: Reply with quote

I
Code:
modprobe -r nouveau
and
Code:
echo blacklist nouveau > /etc/modprobe.d/blacklist.conf
. but it also cannot succeed. It is very comfusing. the Xorg.0.log is http://dpaste.com/3JHWPKM and i
Code:
lspci|grep VGA
cannot see nvidia, it is only intel. it is a bit strange. Thank you!
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 23552
Location: here

PostPosted: Tue Jan 28, 2020 7:02 am    Post subject: Reply with quote

You have a system with two graphics card? If yes see https://bbs.archlinux.org/viewtopic.php?pid=1791021#p1791021

Related wiki page:
https://wiki.gentoo.org/wiki/NVIDIA/Bumblebee
https://wiki.gentoo.org/wiki/NVIDIA/Optimus
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Tue Jan 28, 2020 11:38 am    Post subject: Reply with quote

Freed,

Code:
modprobe -r nouveau
will fail as nouveau is providing your console.
You may not unload a module that is in use.

Blacklisting nouveau may not work.
Modules can be built into the kernel, loaded from the initrd or loaded from the root filesystem after its mounted.
Built in modules cannot be blacklisted.
Initrd modules require the blacklist file to be in the initrd. It normally isn't. By the time the root filesystem is mounted and the blacklist file can be read, all your modules are loaded.

What you describe is expected behaviour.

There is another wart you have to take into account. You have an Optimus graphics system.
You must always use the Intel GPU as its the only one that can transfer the pixel buffer to the screen.
You may use either GPU for drawing the pixel buffer.

fedeliallalinea has already provided some links.

Attempting to use thu nVidia GPU alone will result in a blank screen as its not connected to the screen.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Wed Jan 29, 2020 8:56 am    Post subject: Reply with quote

emmm. now when i
Code:
xterm

i will get
Code:
xterm: Xt error: Can’t open display:
xterm: DISPLAY is not set

when i
Code:
twm
, i will get
Code:
twm: unable to open display

the most terrible is when i
Code:
xinit
, my computer screen will become black and don’t response whatever i press any key. Terrible!
Code:
/var/log/Xorg.0.log
ishttp://dpaste.com/2X9204T
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Wed Jan 29, 2020 5:53 pm    Post subject: Reply with quote

Freed,

Code:
[   559.305] (II) NVIDIA(0): Virtual screen size determined to be 640 x 480
[   559.305] (WW) NVIDIA(0): Unable to get display device for DPI computation.


That's expected.
Quote:
Attempting to use the nVidia GPU alone will result in a blank screen as its not connected to the screen.


You must follow one of the links that fedeliallalinea provided to configure you Optimus graphics.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sat Feb 01, 2020 7:29 am    Post subject: Reply with quote

now i
Code:
sudo startx
, i can enter xterm...after i add
Code:
Option "AllowEmptyInitialConfiguration"
to xorg.conf
but now i has met new problem... when i
Code:
gnome-session
, screen will occur
Code:
Terminated
. and after i
Code:
systemctl enable gdm.service
, everytime i turn on my PC, screen will occur
Code:
oh no! something has gone wrong. a problem has occured and the system cannot recover. please log out and try again.
log out
if i press enter to log out, screen will become blank...now i even cannot enter terminal...
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sat Feb 01, 2020 7:55 am    Post subject: Reply with quote

i start PC from liveCD then
Code:
systemctl disable gdm.service
, now i can enter terminal after reboot. but i still don’t know how to solve
Code:
oh no! something has gone wrong. a problem has occured and the system cannot recover. please log out and try again.
log out
Back to top
View user's profile Send private message
hedmo
Veteran
Veteran


Joined: 29 Aug 2009
Posts: 1043
Location: halmstad

PostPosted: Sat Feb 01, 2020 9:13 am    Post subject: Reply with quote

Freed wrote:
now i
Code:
sudo startx
, i can enter xterm...after i add
Code:
Option "AllowEmptyInitialConfiguration"
to xorg.conf
but now i has met new problem... when i
Code:
gnome-session
, screen will occur
Code:
Terminated
. and after i
Code:
systemctl enable gdm.service
, everytime i turn on my PC, screen will occur
Code:
oh no! something has gone wrong. a problem has occured and the system cannot recover. please log out and try again.
log out
if i press enter to log out, screen will become blank...now i even cannot enter terminal...


Freed

as i have understand. you have manage to get in to X now but not gdm?.take one step at the time...if you have manage to get in to X via:

Code:

startx


modify xinitrc and try to start your DE from there(startx)


regards hedmo
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Sat Feb 01, 2020 12:20 pm    Post subject: Reply with quote

hedmo,

There is a step before there that may give useful information.
Code:
emerge -1av twm xterm xclock
then run startx with an empty or missing ~/.xinird

If all is well, three xterms and an analogue clock will appear, all wrapped in the default green twm.
Its ugly but it works. It shows that Xorg is working properly too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sat Feb 01, 2020 2:03 pm    Post subject: Reply with quote

i have install xterm and twm, they can work normally when i
Code:
sudo startx
. but when i
Code:
gnome-session
it will return
Code:
Terminated
and if i
Code:
sudo systemctl enable --now gdm.service
it will appear a GUI interface with text
Code:
oh no! something has gone wrong. a problem has occured and the system cannot recover. please log out and try again.
log out
i try to add exec gnome-session to .xinitrc but i is not useful...
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sun Feb 02, 2020 6:06 am    Post subject: Reply with quote

the picture see [img]https://pic4.zhimg.com/v2-f2f31532f3d226c0e037d18ba5f8a4f7_r.jpg[/img] and [img]https://pic1.zhimg.com/v2-8be05369c2299e7d3e4f3288314cd0f8_b.jpeg[/img]
Back to top
View user's profile Send private message
hedmo
Veteran
Veteran


Joined: 29 Aug 2009
Posts: 1043
Location: halmstad

PostPosted: Sun Feb 02, 2020 7:02 am    Post subject: Reply with quote

Freed

what i can see in the pictures.You are in X and trying to start gnome-session.this will not work because gnome-session wants X by it self.Put exec gnome-session
command in the xinitrc file :
Code:


echo "exec gnome-session" > /etc/X11/xinit/xinitrc



Restart your box,login and type startx


regards hedmo
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sun Feb 02, 2020 8:29 am    Post subject: Reply with quote

[quote=hedmo]Put exec gnome-session
command in the xinitrc file[/quote]
i did but it looks like not useful...[/url] the output of startx is http://dpaste.com/1YWPDK4
Back to top
View user's profile Send private message
hedmo
Veteran
Veteran


Joined: 29 Aug 2009
Posts: 1043
Location: halmstad

PostPosted: Sun Feb 02, 2020 10:15 am    Post subject: Reply with quote

Freed

can you post your xinitrc file

from what i can see is that you have X running but you cannot start the gnome-session.i have never worked with gnome and cannot help you there.when my DE(kde) dont work
i am using startx and and have lxde in the xinitrc file:

Code:


mya51 /home/hedmo # emerge -av lxde-meta

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R    ] lxde-base/lxde-meta-0.5.5-r6::gentoo  0 KiB

Total: 1 package (1 reinstall), Size of downloads: 0 KiB

Would you like to merge these packages? [Yes/No] n

Quitting.

mya51 /home/hedmo #cat /etc/X11/xinit/xinitrc
#!/bin/sh

exec startlxde



userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/Xresources
sysmodmap=/etc/X11/xinit/Xmodmap

# merge in defaults and keymaps

if [ -f $sysresources ]; then

####################################### cutting here to have a short reply


if you want to try to get lxde up and running .

regards hedmo
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Sun Feb 02, 2020 11:11 am    Post subject: Reply with quote

Freed,

Your images show that twm works as the first one shows you typing
Code:
gnome-session
in an xterm wrapped it twm.
That's progress. It shown that Xorg works.

Gnome wants a hardware accelerated graphics setup. It will not start without it.

As hedmo says, you cannot use the gnome-session command the way you tried.
Code:
exec gmome-session
may work. If it does, you will get some tekt in the xterm, then the xterm will hang.
That's good. Gnome will have started a new X session on another VT, probably VT-8
Press Ctl-Alt-F8 to see VT-8.
Press Ctl-Alt-F7 to see VT-7, which is probably where twm is running.

So that we can check if your Xorg is using hardware accelerated graphics, go back to your working twm and xterm.
Now pastebin /var/log/Xorg.0.log

/var/log/Xorg.0.log after a failed attempt to start Gnome may be useful too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sun Feb 02, 2020 12:19 pm    Post subject: Reply with quote

this is output of
Code:
journalctl -b
:http://dpaste.com/1K8TCTG. I use default xinitrc. i doubt the problem is related with gdm but i still not solve it. if i still fail to start gnome, i will take another DE in consideration. Thank you!
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Sun Feb 02, 2020 1:13 pm    Post subject: gnome-session-failed: Fatal IO error 11 Reply with quote

this is my ~/.xinitrc
Code:
export XDG_CURRENT_DESKTOP=GNOME-Classic:GNOME
export GNOME_SHELL_SESSION_MODE=classic
exec gnome-session --session=gnome-classic


this is a part of output of
Code:
journalctl -b

Quote:
Feb 02 20:38:58 gentoo dbus-daemon[2017]: [session uid=1000 pid=2015] Activating service name='org.a11y.Bus' requested by ':1.0' (uid=1000 pid=2018 comm="/usr/libexec/gnome-session-check-accelerated " label="kernel")
Feb 02 20:38:58 gentoo dbus-daemon[2017]: [session uid=1000 pid=2015] Successfully activated service 'org.a11y.Bus'
Feb 02 20:38:58 gentoo org.a11y.Bus[2017]: dbus-daemon[2025]: Activating service name='org.a11y.atspi.Registry' requested by ':1.0' (uid=1000 pid=2018 comm="/usr/libexec/gnome-session-check-accelerated " label="kernel")
Feb 02 20:38:58 gentoo dbus-daemon[2017]: [session uid=1000 pid=2015] Activating service name='org.gtk.vfs.Daemon' requested by ':1.2' (uid=1000 pid=2018 comm="/usr/libexec/gnome-session-check-accelerated " label="kernel")
Feb 02 20:38:58 gentoo org.a11y.Bus[2017]: dbus-daemon[2025]: Successfully activated service 'org.a11y.atspi.Registry'
Feb 02 20:38:58 gentoo org.a11y.Bus[2017]: SpiRegistry daemon is running with well-known name - org.a11y.atspi.Registry
Feb 02 20:38:58 gentoo dbus-daemon[2017]: [session uid=1000 pid=2015] Successfully activated service 'org.gtk.vfs.Daemon'
Feb 02 20:38:59 gentoo gnome-session[2010]: gnome-session-binary[2010]: WARNING: software acceleration check failed: Child process exited with code 1
Feb 02 20:38:59 gentoo gnome-session-binary[2010]: WARNING: software acceleration check failed: Child process exited with code 1
Feb 02 20:39:01 gentoo gnome-session-f[2040]: gnome-session-failed: Fatal IO error 11 (Resource temporarily unavailable) on X server :0.
Feb 02 20:39:01 gentoo org.a11y.Bus[2017]: X connection to :0 broken (explicit kill or server shutdown).
Feb 02 20:39:01 gentoo org.gtk.vfs.Daemon[2017]: A connection to the bus can't be made

after startx it will be [img]https://pic1.zhimg.com/v2-8be05369c2299e7d3e4f3288314cd0f8_b.jpeg[/img]

Help!

Merged by NeddySeagoon as its the same problem from the same user and this topic has lots of useful background
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44959
Location: 56N 3W

PostPosted: Sun Feb 02, 2020 1:31 pm    Post subject: Reply with quote

Freed,

Pastebin the two Xorg logs I requested above.

So far, it looks like Gnome fails to start because hardware acceleration is not available to you.
The logs will confirm that and perhaps point to why.

wgetpaste can help you with your pastebins.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Mon Feb 03, 2020 2:37 am    Post subject: Reply with quote

the xorg.0.log after startx is http://dpaste.com/2B597DX
i have seen the log but i did not know any probable problem. Thank you!
Back to top
View user's profile Send private message
Freed
n00b
n00b


Joined: 19 Jan 2020
Posts: 18

PostPosted: Mon Feb 03, 2020 6:10 am    Post subject: Reply with quote

i find if i
Code:
glxinfo
in xterm, i will get error
Quote:
name of display:0
Error: couldn't find RGB GLX visual and fbconfig
Segmentation fault(core dumped)

it indicated that perhaps i make some error in some thing on driver?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
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