Ubuntu 18.04 + Ryzen + GTX 1060 = Spontaneous PCIe Bus Error

Hello all,

I have been seeing this error message in my system for quite some time…

Jan  2 04:24:01 ryzen kernel: [  232.253597] pcieport 0000:00:03.1: AER: Corrected error received: id=0000
Jan  2 04:24:01 ryzen kernel: [  232.253604] pcieport 0000:00:03.1: PCIe Bus Error: severity=Corrected, type=Data Link Layer, id=0019(Transmitter ID)
Jan  2 04:24:01 ryzen kernel: [  232.253610] pcieport 0000:00:03.1:   device [1022:1453] error status/mask=00001000/00006000
Jan  2 04:24:01 ryzen kernel: [  232.253614] pcieport 0000:00:03.1:    [12] Replay Timer Timeout

I have tried to fix this issue by setting these grub params, but I am not getting any luck…

pci=noaer
pci=nomsi
pci=nommconf
pcie_aspm=off

I am using GIGABYTE AB350M-DS3H AM4 motherboard, and I am using its latest BIOS F24…
I am also using this driver for my GTX 1060:

$ ubuntu-drivers devices
== /sys/devices/pci0000:00/0000:00:03.1/0000:08:00.0 ==
modalias : pci:v000010DEd00001C03sv00003842sd00006163bc03sc00i00
vendor   : NVIDIA Corporation
model    : GP106 [GeForce GTX 1060 6GB]
driver   : nvidia-driver-390 - distro non-free recommended
driver   : xserver-xorg-video-nouveau - distro free builtin

I have tried using Gen 2 option for my PCI slot, but it hasn’t fixed my issue :(

Can someone please help me out how to debug this issue?
My system is spontaneously getting spammed by this error message, and I can’t even SSH into the server…

I think this might be the Kernel issue…

I will try to update my Kernel to version 4.19

So, after a long investigating… I have learned that

sudo nano /etc/defaults/grub
sudo update-grub

was not updating my /boot/grub/grub.cfg file properly…

Somehow my /etc/default/grub.d/50-curtin-settings.cfg file was overwriting my GRUB_CMDLINE_LINUX_DEFAULT

So, I have just updated

sudo nano /etc/default/grub.d/50-curtin-settings.cfg
sudo update-grub

I hope other people with Ubuntu 18.04 doesn’t struggle with this issue like me… :)

Here is the bug ticket from grub2 package…