Can't update libdrm

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
oozekip
Level 1
Level 1
Posts: 1
Joined: Tue Sep 05, 2017 10:27 pm

Can't update libdrm

Post by oozekip »

Hi, I think I'm having the exact same problem, except the version numbers are a bit different:

Preparing to unpack .../libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb ...
1016 Unpacking libdrm-common (2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1) ...
1017 dpkg: error processing archive /var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb (--unpack):
1018 trying to overwrite '/usr/share/libdrm/amdgpu.ids', which is also in package libdrm-amdgpu1:amd64 2.4.82+git20170725.3876bc24-0ubuntu0ricotz~16.04.1

I've tried resolving this in ways people with similar issues (with different packages) seem to be having, at least ways that don't involve doing something that results in warnings about destabilizing my whole system, but I haven't had any luck so far and can't figure out what the issue is.
User avatar
WharfRat
Level 21
Level 21
Posts: 13909
Joined: Thu Apr 07, 2011 8:15 pm

Re: Can't update libdrm

Post by WharfRat »

oozekip,

Can you paste the results of inxi -r
Last edited by WharfRat on Tue Sep 05, 2017 11:38 pm, edited 1 time in total.
Reason: Fixed subject
ImageImage
User avatar
quantumquantum
Level 1
Level 1
Posts: 3
Joined: Tue Jan 10, 2017 1:05 pm

Re: Can't update libdrm

Post by quantumquantum »

I am also having this issue also. Has anyone been able to resolve it? '/usr/share/libdrm/amdgpu.ids' is apparently contained in libdrm-common and in libdrm-amdgpu1 so there is no way for the update to proceed. I tried removing libdrm-amdgpu1, but it had a huge dependency tree, so no go there either. Not sure how to resolve this.

Here is the output from a simple reinstall attempt.

Code: Select all

$ sudo apt-get install --reinstall libdrm-amdgpu1
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-4.4.0-83 linux-headers-4.4.0-83-generic
  linux-image-4.4.0-83-generic linux-image-extra-4.4.0-83-generic
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libdrm-common libdrm-dev libdrm-intel1 libdrm-intel1:i386 libdrm-nouveau2
  libdrm-nouveau2:i386 libdrm-radeon1 libdrm-radeon1:i386 libdrm2 libdrm2:i386
The following NEW packages will be installed:
  libdrm-common
The following packages will be upgraded:
  libdrm-amdgpu1 libdrm-dev libdrm-intel1 libdrm-intel1:i386 libdrm-nouveau2
  libdrm-nouveau2:i386 libdrm-radeon1 libdrm-radeon1:i386 libdrm2 libdrm2:i386
10 upgraded, 1 newly installed, 0 to remove and 9 not upgraded.
Need to get 0 B/619 kB of archives.
After this operation, 32.8 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 548184 files and directories currently installed.)
Preparing to unpack .../libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb ...
Unpacking libdrm-common (2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb (--unpack):
 trying to overwrite '/usr/share/libdrm/amdgpu.ids', which is also in package libdrm-amdgpu1:amd64 2.4.82+git20170725.3876bc24-0ubuntu0ricotz~16.04.1
Errors were encountered while processing:
 /var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Last edited by WharfRat on Sat Sep 16, 2017 1:50 pm, edited 1 time in total.
Reason: Added code tag
mr_raider
Level 7
Level 7
Posts: 1870
Joined: Sun Jun 20, 2010 9:50 am
Location: Montreal, QC

Re: Can't update libdrm

Post by mr_raider »

I dont even have a package called libdrm-common

What repo you guys running?

Never mind. xorg-edgers.

Live by the sword... die by the sword.
Image
User avatar
quantumquantum
Level 1
Level 1
Posts: 3
Joined: Tue Jan 10, 2017 1:05 pm

Re: Can't update libdrm

Post by quantumquantum »

Not sure if this is a good solution or not, but I was able to get the update to work with the following dpkg-divert command. I suspect this command is not entirely correct since the amdgpu.ids.divert file does not seem to exist. I hope this helps someone, it was painful to try to find a solution since I do not fully understand all the intricacies of apt-get. Fortunately someone helped me along.

Code: Select all

dpkg-divert --package libdrm-common --divert /usr/share/libdrm/amdgpu.ids.divert --rename /usr/share/libdrm/amdgpu.ids
User avatar
phd21
Level 19
Level 19
Posts: 9673
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Can't update libdrm

Post by phd21 »

Hi "oozekip",

You could use this PPA for an easy way to update "libdrm".

Updated and Optimized Open Graphics Drivers
https://launchpad.net/~oibaf/+archive/u ... cs-drivers
To install this using the PPA method, open a console terminal, type in, or copy & paste, each line below one by one:
Click "Select All" above command, right click the highlighted command, select Copy (or Ctrl+Insert), click in the console terminal window, and right click paste (or Shift+Insert), repeat for each command.

Code: Select all

sudo add-apt-repository ppa:oibaf/graphics-drivers

Code: Select all

sudo apt-get update
Probably a good idea to logout and log back in or restart.

Hope this helps ...
Phd21: Mint 20 and 19.2 Cinnamon & xKDE (Mint Xfce + Kubuntu KDE) & KDE Neon 64-bit (new based on Ubuntu 20.04) Awesome OS's, Dell Inspiron I5 7000 (7573) 2 in 1 touch screen, Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, Intel 4 Graphics.
minitux
Level 5
Level 5
Posts: 854
Joined: Tue Sep 12, 2017 10:05 am

Re: Can't update libdrm

Post by minitux »

quantumquantum wrote:Unpacking libdrm-common (2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb (--unpack):
trying to overwrite '/usr/share/libdrm/amdgpu.ids', which is also in package libdrm-amdgpu1:amd64 2.4.82+git20170725.3876bc24-0ubuntu0ricotz~16.04.1
Errors were encountered while processing:
/var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Usually resolves by forcing overwriting that fails

Code: Select all

sudo dpkg -i --force-overwrite /var/cache/apt/archives/libdrm-common_2.4.83+git20170905.d55d0804-0ubuntu0ricotz~16.04.1_all.deb
User avatar
gpunktschmitz
Level 1
Level 1
Posts: 9
Joined: Sat Sep 07, 2013 3:34 am
Contact:

Re: Can't update libdrm

Post by gpunktschmitz »

for me it worked to run

Code: Select all

sudo apt-get upgrade
to update all available packages

but unlike I expected the package was still shown in Update Manager - so I updated the package using Update Manager again and now it was updated successful with no error ...
Post Reply

Return to “Newbie Questions”