Ubuntu: Made a mistake and deleted just some of the files in /usr/lib/x86_64-linux-gnu/ how do I restore the files? [duplicate]



Question:

This question already has an answer here:

I was going some testing and decided to delete some library files in

/usr/lib/x86_64-linux-gnu/

(Horrible idea I know) The side effect of deleting those files is that I am unable to open the gnome or unity control center for Ubuntu. When I open the control center by running unity-control-center -v

/usr/lib/x86_64-linux-gnu/libwebkit2gtk-4.0.so.37: undefined symbol: sqlite3_errstr  Failed to load module: /usr/lib/x86_64-linux-gnu/unity-control-center-1/panels/libinfo.so  ** (unity-control-center:9666): DEBUG: Enabling debugging  /usr/lib/x86_64-linux-gnu/libwebkit2gtk-4.0.so.37: undefined symbol: sqlite3_errstr  Failed to load module: /usr/lib/x86_64-linux-gnu/unity-control-center-1/panels/libinfo.so  

I have everywhere for this error and tried reinstalling many many diffrent libs but none seem to work. This is different from other questions because the libraries can be restored by installing the right packages Using Ubuntu 16.04.3 LTS


Solution:1

Two options here:

  1. You should try to fix this with debsums. You can find missed files with it and reinstall their packages with the following commands:

    sudo apt-get install debsums  sudo debsums_init  sudo debsums --changed --silent  

    then reinstall mentioned packages manually with

    sudo apt-get -f install  
  2. Or try to find all packages, which have files in /usr/lib/x86_64-linux-gnu/ with dpkg -S /usr/lib/x86_64-linux-gnu/ or combined with re-installation

    sudo apt-get install --reinstall `dpkg -S /usr/lib/x86_64-linux-gnu/ \  | sed 's/,/ /g' | head -c-28`  

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »