python3-pip has no installation candidate - python-3.x

I am having an error after typing:
sudo apt-get install python3-pip
This is the error:
Package python3-pip is not available but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'python3-pip' has no installation candidate
What should I do?

You need to update source list first,
Try running
sudo apt-get update
sudo apt-get upgrade #Optional
sudo apt install python3-pip

hi I had same issue but I ran the following commands to fix it
sudo add-apt-repository universe
sudo apt-get update
sudo apt install python3-pip
and it solved the problem

The solution is to add the universe repository:
sudo add-apt-repository universe
Then update apt:
sudo apt update
And try again:
sudo apt install python3-pip

in Debian 11, part of this answer helped me (I invite you to upvote it unix.stackexchange.com, please): https://unix.stackexchange.com/questions/522758/how-to-install-software-properties-common-in-debian-9/522770#522770
Summarizing, add to /etc/apt/sources.list the next line (replacing by the right Debian version name, as stretch or bullseye):
deb http://deb.debian.org/debian/ <version-name> main
In my case,
deb http://deb.debian.org/debian/ bullseye main
After this, I cold install my missing packages, as software-properties-common python3-pip vim tree

Related

Error in installing libssl-dev and libssl1.0-dev in Ubuntu

I am trying to install libssl-dev and libssl1.0-dev in Ubuntu 18.04 via the following command:
sudo apt-get -y install build-essential openssl libssl-dev libssl1.0 libgl1-mesa-dev libqt5x11extras5
I am getting the following output:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libssl1.0-dev' for regex 'libssl1.0'
Note, selecting 'libssl1.0.0' for regex 'libssl1.0'
Note, selecting 'libssl1.0.2' for regex 'libssl1.0'
build-essential is already the newest version (12.4ubuntu1).
libqt5x11extras5 is already the newest version (5.9.5-0ubuntu1).
libqt5x11extras5 set to manually installed.
libgl1-mesa-dev is already the newest version (20.0.8-0ubuntu1~18.04.1).
libgl1-mesa-dev set to manually installed.
libssl-dev is already the newest version (1.1.1-1ubuntu2.1~18.04.20).
libssl1.0.0 is already the newest version (1.0.2n-1ubuntu5.10).
openssl is already the newest version (1.1.1-1ubuntu2.1~18.04.20).
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
**The following packages have unmet dependencies:
libssl-dev : Conflicts: libssl1.0-dev but 1.0.2n-1ubuntu5.10 is to be installed
libssl1.0-dev : Conflicts: libssl-dev but 1.1.1-1ubuntu2.1~18.04.20 is to be installed
E: Unable to correct problems, you have held broken packages.**
How do I solve these errors?
There are three ways to install libssl1.0-dev on Ubuntu. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.
Install libssl1.0-dev Using apt-get
sudo apt-get update
sudo apt-get -y install libssl1.0-dev
Install libssl1.0-dev Using apt
sudo apt update
sudo apt -y install libssl1.0-dev
Install libssl1.0-dev Using aptitude
sudo aptitude update
sudo aptitude -y install libssl1.0-dev
The following sequence of commands should work to resolve dependencies.
# Fix broken dependencies on your system.
sudo apt-get install -f
# Reconfigure all unpacked packages.
sudo dpkg -–configure -a
# Fix broken dependencies in your system.
sudo apt-get install -f
# Install package on the system.
sudo apt-get install <package_name>

Installing kernel headers packages missing error

I am trying to install kernel-headers but getting this error
E: Unable to locate package linux-headers-5.9.0-kali1-amd64
E: Couldn't find any package by glob 'linux-headers-5.9.0-kali1-amd64'
E: Couldn't find any package by regex 'linux-headers-5.9.0-kali1-amd64'
I have updated and uncommented this line in sources.list
deb-src http://http.kali.org/kali kali-rolling main contrib non-free
but errors thats can't locate regex or glob. what I am missing?
Here's what you may need to do
sudo apt-get update # This will update the repositories list
sudo apt-get upgrade # This will update all the necessary packages on your system
sudo apt-get dist-upgrade # This will add/remove any needed packages
reboot # You may need this since sometimes after a upgrade/dist-upgrade, there are some left over entries that get fixed after a reboot
sudo apt-get install linux-headers-$(uname -r) # This should work now
from what am guessing linux-headers-5.9.0 is not available in the kali repository.
you can always use apt-cache search linux-headers to know if it available
but to update to the latest linux headers
sudo apt-get update
sudo apt-get dist-upgrade
then search for Linux-headers available using apt search Linux-headers.
so you install the latest version using
sudo apt-get install -y linux-headers-$(uname -r)

How to install Python package installer PIP on Ubuntu 20.04 Linux

Trying to install pip with Ubuntu version 20.04, Python version 3.8 on my Oracle virtual box.
Tried everything to install pip but failed
Steps tried
$ sudo apt update
$ sudo apt install python3-pip
Also tried
$ sudo apt-get install python3-pip
Error both times
python3-pip is not available but is being used by another candidate. This may mean that the package has been obsolete, has been missing or is only available from another source.
E: Package 'python3-pip' has no installation candidate
Option 1
1.vim /etc/apt/sources.list
2.add these lines in the above file.
deb http://http.kali.org/kali kali-rolling main non-free contribs
deb http://kali.cs.nctu.edu.tw/kali kali-rolling main contrib non-free
deb-src http://http.kali.org/kali kali-rolling main non-free contrib
sudo apt update
sudo apt install python3-pip
Option 2
sudo apt-get update
sudo apt-get upgrade
sudo apt install python3-pip
Option 3
https://stackoverflow.com/a/59922280/11741464
Source:
facing problem in kali linuix python3-pip

Dependency issue: sun-java6-jdk (bindiff)

I am trying to install bindiff. When I try to install through archive manager I am welcomed by the following message "Dependency is not satisfiable: sun-java6-jre". (I am running ubuntu 12.10)
I have tried adding a repository
sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
sudo add-apt-repository ppa:ferramroberto/java
This did not work.
I also currently have java 7 installed, and have done sudo apt-get update
I tried "sudo apt-get install sun-java6-jdk" and I receive the following:
sudo apt-get install sun-java6-jdk Reading package lists... Done Building dependency tree
Reading state information... Done Package sun-java6-jdk is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source
E: Package 'sun-java6-jdk' has no installation candidate
SOLVED:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get remove java-common
sudo apt-get install oracle-java6-installer
sudo apt-get purge java common
Use the following terminal commands:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get remove java-common
sudo apt-get install oracle-java6-installer
sudo apt-get purge java common

Using 'sudo apt-get install build-essentials'

I was trying to use sudo apt-get install build-essentials to install the g++ compiler on my Ubuntu Linux box. But it gave me the following message:
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package build-essentials
How do I fix this problem?
Drop the 's' off of the package name.
You want sudo apt-get install build-essential
You may also need to run sudo apt-get update to make sure that your package index is up to date.
For anyone wondering why this package may be needed as part of another install, it contains the essential tools for building most other packages from source (C/C++ compiler, libc, and make).
In my case, simply "dropping the s" was not the problem (although it is of course a step in the right direction to use the correct package name).
I had to first update the package manager indexes like this:
sudo apt-get update
Then after that the installation worked fine:
sudo apt-get install build-essential
Try
sudo apt-get update
sudo apt-get install build-essential
(If I recall correctly the package name is without the extra s at the end).
I know this has been answered, but I had the same question and this is what I needed to do to resolve it. During installation, I had not added a network mirror, so I had to add information about where a repo was on the internet. To do this, I ran:
sudo vi /etc/apt/sources.list
and added the following lines:
deb http://ftp.debian.org/debian wheezy main
deb-src http://ftp.debian.org/debian wheezy main
If you need to do this, you may need to replace "wheezy" with the version of debian you're running. Afterwards, run:
sudo apt-get update
sudo apt-get install build-essential
Hopefully this will help someone who had the same problem that I did.
The package is called build-essential without the plural "s". So
sudo apt-get install build-essential
should do what you want.
Try 'build-essential' instead.
To auto-generate the "source.list" file I suggest to use:
https://debgen.simplylinux.ch/
Where you can select the country, the distribution, ..etc
After that, all you need to do is to replace (take a backup of the file first) your original source.list file with the generated one and do as mentioned in other answers:
sudo apt-get update
sudo apt-get install build-essential
Manifest for installing rust and build-essentials on ubuntu 20.04.03
rustup self uninstall
apt-get update
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) main universe"
apt-get -u dist-upgrade
apt install aptitude
sudo aptitude install libc6=2.31-0ubuntu9
sudo aptitude install build-essential
apt-get update
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain none -y
rustup toolchain install nightly --allow-downgrade --profile minimal --component clippy
rustup default stable
rustup update nightly
rustup update stable
rustup target add wasm32-unknown-unknown --toolchain nightly
sudo apt install -y cmake pkg-config libssl-dev git gcc build-essential clang libclang-dev
rustc --version
source $HOME/.cargo/env
#No tested on me Fast Installation: Install all the required dependencies with a single command. (Be patient, this can take up to
30 minutes)
curl https://getsubstrate.io -sSf | bash -s -- --fast
Finally step test:
https://doc.rust-lang.org/cargo/getting-started/first-steps.html
#ArmanRiazi.Blockchain#Substrate#Dr.GavinWood

Resources