Hot answers tagged

6

I was able to solve the error myself by forcing the file override when installing the .deb package with dpkg. Here's my workaround to install openjdk-9-jdk on Ubuntu 16.04 Xenial (not tested on other releases) despite the error message about not overwriting a file provided by its dependency openjdk-9-jdk-headless: Normally try to install the ...


3

You can directly do sudo apt-get -o Dpkg::Options::="--force-overwrite" install openjdk-9-jdk. If you are here, you already tried the installation without the -o Dpkg::Options::="--force-overwrite" and you know which files will be silently overwritten.


2

The lock is used to ensure that only one process can change the apt database at time. If another process was installing a package and one was installing one they could end up getting very confused and corrupt the database. for more on this concept google 'database transactions' or 'atomicity'. You can avoid the locks by downloading the packages yourself ...


2

UPDATE: sorry, my fault. apt-get download package-name only download the package-name to the current directory. then it is not an answer to your question. apt-get download is also not download the package dependencies. an alternative to download the packages and dependencies, but not install would: sudo apt-get -d install package-name but it also does not ...


2

No, dpkg-reconfigure on 16.04 (but also on 15.10) does not have the option --all any more, although it was present in 14.04 (not sure about 14.10). You could have verified that yourself by checking the command's manpage: man dpkg-reconfigure On a 16.04 (or 15.10) system, this manual page will not list an --all argument, while on 14.04 one is present. If ...


2

Execute man apt-get and go down (/) to the install function. This is worth reading. By the way, did you try the following? sudo apt-get install gunicorn=19.3.0 (one equal sign, not two) As the man page states, use this feature with care. I don't know why you'd want an older version of a package on your installation but I'd guess that it would ...


1

To easily fix your sources.listfile you can copy the following block and paste it into your terminal after you switched to be root by sudo su (you need to hit return once after pasting to be back as your normal user): cp /etc/apt/sources.list /etc/apt/sources.list.repairbackup cat > /etc/apt/sources.list << EOF # deb cdrom:[Ubuntu 16.04 LTS _Xenial ...


1

try - import apt_pkg apt_pkg.init() arch_location = apt_pkg.config.find_file('Dir::cache::archives') http://apt.alioth.debian.org/python-apt-doc/library/index.html


1

Run this: sudo dpkg -r account-plugin-google unity-scope-gdrive sudo apt-get -f install


1

Use uname -r to show your currently running kernel. DO NOT DELETE anything with this version number. You can find which packages the kernels in /boot belong to: for i in /boot/vmlinuz* ; do dpkg -S $i| egrep -v $(uname -r) done You can remove these packages with sudo apt-get purge packagename .... You can find more packages related to the ...


1

The answer is in the comments, but I think It is worth to post it there. I downloaded mysql-apt-config_0.7.2-1_all.deb (MySQL APT repository - dev.mysql.com/downloads/repo/apt) from dev.mysql.com and during config I have chosen Ubuntu Wily since 16.04 was not on the list. And that was the problem, Xenial already has MySQL 5.7 in its official repositories. ...


1

You can do that with << example: libvtk6-dev (>= 6.0.0), libvtk6-dev (<< 6.2.0) This way you have locked the range between 6.0.0 and 6.1.0. The same way you have to specify for each package individually, there is no if this dependency is this then ask for that.


1

If you have security updates set to auto-install this will happen frequently. I literally wait 30 seconds and it fixes the issue. Just throwing this out there in case anyone else encounters this issue.


1

I don't see this answer anywhere above but on Ubuntu 16.04, I encountered this problem as well. The cause was the time on my computer was set into the future. (This is because I'm on a Windows+Ubuntu dual boot system and I guess I have messed up local time vs UTC time.) One odd thing was that the locked file's date and time was the exact date and time ...



Only top voted, non community-wiki answers of a minimum length are eligible