Ubuntu 18.04.5 hdmi external monitor problem. nvidia-driver-455.45.01

I have problems connecting my external monitor with Ubuntu 18.04.5. Basically the external screen is just black. I’m using the nvidia-driver-455. I tried to switch to lightdm, but it didn’t solve the problem.

Here are some of my settings:

~$ ubuntu-drivers devices
== /sys/devices/pci0000:00/0000:00:01.1/0000:01:00.0 ==
modalias : pci:v000010DEd00001F99sv00001025sd00001447bc03sc00i00
vendor : NVIDIA Corporation
driver : nvidia-driver-455 - distro non-free recommended
driver : nvidia-driver-450-server - distro non-free
driver : nvidia-driver-450 - distro non-free
driver : nvidia-driver-440-server - distro non-free
driver : xserver-xorg-video-nouveau - distro free builtin
== /sys/devices/pci0000:00/0000:00:02.2/0000:04:00.0 ==
modalias : pci:v00008086d00002723sv00008086sd00000084bc02sc80i00
vendor : Intel Corporation
manual_install: True
driver : backport-iwlwifi-dkms - distro free

~$ dmesg | grep -i nvidia
[ 10.981890] nvidia: loading out-of-tree module taints kernel.
[ 10.981897] nvidia: module license ‘NVIDIA’ taints kernel.
[ 10.998081] nvidia: module verification failed: signature and/or required key missing - tainting kernel
[ 11.004776] nvidia-nvlink: Nvlink Core is being initialized, major device number 234
[ 11.005186] nvidia 0000:01:00.0: enabling device (0400 -> 0403)
[ 11.005270] nvidia 0000:01:00.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=none:owns=none
[ 11.049600] NVRM: loading NVIDIA UNIX x86_64 Kernel Module 455.45.01 Thu Nov 5 23:03:56 UTC 2020
[ 11.242112] nvidia-modeset: Loading NVIDIA Kernel Mode Setting Driver for UNIX platforms 455.45.01 Thu Nov 5 22:55:44 UTC 2020
[ 11.304807] [drm] [nvidia-drm] [GPU ID 0x00000100] Loading driver
[ 11.304809] [drm] Initialized nvidia-drm 0.0.0 20160202 for 0000:01:00.0 on minor 0
[ 11.418520] nvidia-uvm: Loaded the UVM driver, major device number 510.
[ 11.606869] input: HDA NVidia HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:01.1/0000:01:00.1/sound/card0/input18
[ 11.606953] input: HDA NVidia HDMI/DP,pcm=7 as /devices/pci0000:00/0000:00:01.1/0000:01:00.1/sound/card0/input19
[ 11.606982] input: HDA NVidia HDMI/DP,pcm=8 as /devices/pci0000:00/0000:00:01.1/0000:01:00.1/sound/card0/input20
[ 11.607013] input: HDA NVidia HDMI/DP,pcm=9 as /devices/pci0000:00/0000:00:01.1/0000:01:00.1/sound/card0/input21

~$ xrandr
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 1920 x 1080, current 1920 x 1080, maximum 1920 x 1080
default connected primary 1920x1080+0+0 0mm x 0mm
1920x1080 77.00*

Many thanks if you have any suggestions how to solve this!

Kind regards

nvidia-bug-report.log.gz (353.5 KB)

The kernel 5.4 of Ubuntu 18.04 is too old to drive your AMD gpu. Please upgrade to 20.04. Afterwards, you’ll have to configure for hybrid graphics:
https://forums.developer.nvidia.com/t/nvidia-xconfig-doesnt-do-what-i-want-it-to-nor-does-nvidia-settings/107883/7?u=generix