Debian: even after these steps, cannot install a package with Synaptic
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
If you want, we can go back to the basics, and start with:
Code:
sudo apt-get check
sudo dpkg --audit
Now I did read this:
Quote:
Originally Posted by man apt-get
Code:
check
check is a diagnostic tool; it updates the package cache and checks
for broken dependencies.
I guess it is not needed? In synaptic, menu edit > "reload package data" did exactly that? And Synaptic do not let us install anything if there are broken packages.
Quote:
Originally Posted by man dpkg
Code:
[...]
-V, --verify [package-name...]
Verifies the integrity of package-name or all packages if
omitted, by comparing information from the files installed by a
package with the files metadata information stored in the dpkg
database (since dpkg 1.17.2). The origin of the files metadata
information in the database is the binary packages themselves.
That metadata gets collected at package unpack time during the
installation process.
Currently the only functional check performed is an md5sum
verification of the file contents against the stored value in
the files database. It will only get checked if the database
contains the file md5sum. To check for any missing metadata inthe database, the --audit command can be used.
The output format is selectable with the --verify-format option,
which by default uses the rpm format, but that might change in
the future, and as such, programs parsing this command output
should be explicit about the format they expect.
-C, --audit [package-name...]
Performs database sanity and consistency checks for package-name
or all packages if omitted (per package checks since dpkg
1.17.10). For example, searches for packages that have been
installed only partially on your system or that have missing,
wrong or obsolete control data or files. dpkg will suggest what
to do with them to get them fixed.
[...]
Now I did both audit and verify with dpkg for all packages installed yesterday. Is the expected no output, if no problem found? I tried to find "verb" in 'man dpkg', not found. No option to force it being verbose?
Yes, no error or warning output from either command is good. You should run both commands (dpkg: not for specific packages but for your whole system as it was given), whether you think you need to or not.
I don't know the equivalent in Synaptic because I don't use it, to be honest. I just wanted to check your package basics, given that you had experienced problems with the package manager's directories and the lock file.
I thought so. That is good, but I wanted to confirm.
About your command, see some output from my terminal now. The command I used is inspired in yours:
Code:
me@here: /dev/shm
$ for i in /etc/apt/sources.list{,.d/*}; do \
echo file: $i; cat $i; echo ====; done
file: /etc/apt/sources.list
# deb cdrom:[Debian GNU/Linux 9.0.0 _Stretch_ - Official amd64
NETINST 20170617-13:06]/ stretch main
#deb cdrom:[Debian GNU/Linux 9.0.0 _Stretch_ - Official amd64
NETINST 20170617-13:06]/ stretch main
# Mudanças feitas seguindo:
# "[...] - why 'apt-get update' cannot write tmp files? "
# LQ: /questions/showthread.php?p=5794018#post5793944
deb http://deb.debian.org/debian/ stretch main
#deb http://httpredir.debian.org/debian stretch main
deb-src http://deb.debian.org/debian/ stretch main
#deb-src http://httpredir.debian.org/debian stretch main
#deb http://security.debian.org/ stretch/updates main
#deb-src http://security.debian.org/ stretch/updates main
# stretch-updates, previously known as 'volatile'
deb http://deb.debian.org/debian/ stretch-updates main
#deb http://httpredir.debian.org/debian stretch-updates main
deb-src http://deb.debian.org/debian/ stretch-updates main
#deb-src http://httpredir.debian.org/debian stretch-updates main
====
file: /etc/apt/sources.list.d/skype-stable.list
deb [arch=amd64] https://repo.skype.com/deb stable main
====
me@here: /dev/shm
$
Some lines are commented because I changed them, sometime ago, discussing here a similar problem. A key post that I followed (according to my comment in the apt source file shown above, because I do not remember clearly today) then is:
Nice adaptation of the command. For interest, if you install inxi, then inxi -r produces a nice repository listing.
Referring to the example sources.list at https://wiki.debian.org/SourcesList#...e_sources.list: given that you have decided not to include the contrib and non-free repos, that you have decided to disable the debian-security updates (why is that, out of interest? - I would have thought those were important) and, very pedantically, that you don't need the forward slash at the end of the urls, e.g. http://deb.debian.org/debian, all appears to look normal.
So, on to the next stage: checking that all your packages are fully installed:
Code:
dpkg -l | grep -v "^ii"
(if there are no packages listed under the equals signs then all is good)
Forgot to say before! 'apt-get check' reported no problem - just the successful progress lines.
Another small comment, to use just one post: most of the time, I prefer Synaptic instead of aptitude (not so easy and fluid interface) or the apt/dpkg commands. And I am thinking about asking the question: " 'apt-get check' and/or 'dpkg --audit' are done automatically by Synaptic?" in its mailing list.
You are right. Updates are not important for me, but I enabled security repos. Indeed a silly idea of "who" commented that...
inxi... never heard that name. Less than 600KiB? I installed it. :D But the problem happened again, exactly like I said in #3. The package had no dependencies and was installed fine - apparently normally, since we found no problem since I started this thread, except the (before) absent partial folder. I repeated/done a few commands now:
'apt-get check' output is only the 3 normal lines it usually do. Reinstalling the package (from synaptic) again *repeated* the error! That is very strange for me... the problem should have stopped.
/-:
I do not understand you. in post #3 you explained the following:
Quote:
W: Download is performed unsandboxed as root as file '/var/cache/apt/archives/partial/libqt5printsupport5_5.7.1+dfsg-3+b1_amd64.deb' couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permissão negada)
The solution is to make it available for the user _apt.
This problem is not related to the apt database and package consistency at all, therefore the commands posted/tried will not address it.
Actually I don't know what permission is missing from where (if the download was successful but the result was unreadable, or it was not downloaded at all).
The missing dir /var/cache/apt/archives/partial is a clear sign: your installation (at least the apt related structure) is corrupted, damaged. This may cause a huge amount of different and diverse error messages. I don't know how serious is it and if there was any way to find and fix all of these failures. apt itself will not able to detect them (it assumes the system was properly installed). By the way reinstalling apt (with dpkg) may help.
Until we've finished checking your system, you shouln't be using Synaptic. We're only half-way through. We will probably end up reinstalling Synaptic manually anyway (and, if necessary, apt etc. as pan64 mentions).
So, with that in mind, if you could run the command in post #19, that would be great.
$ dpkg -l | grep -v "^ii"
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Nome Versão Arquitectura Descrição
+++-=====================================-=================================-============-===============================================================================
rc ffmpeg 7:3.2.5-1 amd64 Tools for transcoding, streaming and playing of multimedia files
rc gstreamer0.10-plugins-good:amd64 0.10.31-3+nmu1ubuntu5.3 amd64 GStreamer plugins from the "good" set
rc libqt3-mt 3:3.3.8-e-0debian7.0.0+0 amd64 Qt GUI Library (Threaded runtime version), Version 3
rc libvdpau-va-gl1:amd64 0.4.2-1 amd64 VDPAU driver with OpenGL/VAAPI backend
rc opera 11.64.1403 amd64 Fast and secure web browser and Internet suite
rc pulseaudio 10.0-1 amd64 PulseAudio sound server
rc rtkit 0.11-4+b1 amd64 Realtime Policy and Watchdog Daemon
$
What 'ii' and 'rc' mean? There are a few lines... but it is not clear. Also, 'man dpkg' does not explain its listing.
"rc" means that you have removed a package but have not yet purged its residual configuration.
Which leads me to the question, why have you deleted pulseaudio and ffmpeg - did you have specific problems? I would expect these two packages to be present on a normal Mint/Ubuntu system, and perhaps a Debian one too (although I don't know much about Debian so can't be sure).
If these have been deleted intentionally, then we can continue with the purging of the packages. Either you can do this manually, one by one, with:
Code:
sudo apt-get purge package_name
or, to make things easier (but do check the list of packages before proceeding):
Files to check when each package was touched are just "/var/log/dpkg.log*" ?
Quote:
Originally Posted by hydrurga
"rc" means that you have removed a package but have not yet purged its residual configuration.
Which leads me to the question, why have you deleted pulseaudio and ffmpeg - did you have specific problems? I would expect these two packages to be present on a normal Mint/Ubuntu system, and perhaps a Debian one too (although I don't know much about Debian so can't be sure).
If these have been deleted intentionally, then we can continue with the purging of the packages. Either you can do this manually, one by one, with:
Code:
sudo apt-get purge package_name
or, to make things easier (but do check the list of packages before proceeding):
Sorry. I did let this thread several weeks needing attention.
I had not deleted or uninstalled those packages. The strangest thing, and probably the only one related to installed programs and packages, that happened to my computer is that I installed skype for linux in it. Without the dependencies being clearly pointed before installing (id est, they were not mentioned in the official page where I downloaded the installed package from). After installing it, I noted that several things, that I did not have, were installed. Wine is one - this is why I think that what I run today is the same that win users run.
I need examine my systems logs to point exactly which packages were added before (a few minutes, at most) skype was first installed.
Thank you also for saying what 'rc' in that context means. "residual configuration" -> So it is not as bad as I imagined from what you all said. Do any of you reading here think that this information (and others related) should be added to the dpkg documentation? A new bug report for that is a good idea?
I want to find what happened to uninstall packages. In the last week, I was about to install [something] and aptitude said that several packages needed to be updated. I found that very strange!
The files I need to look to check when each package I have were installed or removed are just "/var/log/dpkg.log*" ? Do those include all things installed in every possible ways, like synaptic, aptitude, etc.?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.