Debian ベースのオペレーティングシステムに Python3 パッケージをインストールできません。

Debian ベースのオペレーティングシステムに Python3 パッケージをインストールできません。

私はKali Linux(Debianベース)を使用しており、以下はuname -aコマンドの出力です。

Linux kali 5.3.0-kali2-amd64 #1 SMP Debian 5.3.9-3kali1 (2019-11-20) x86_64 GNU/Linux

次のpython3パッケージをインストールしたいが、apt-getはそのパッケージを見つけることができません。

python3-geoip
python3-whois

以下は、apt-getコマンドを使用してpython3-whoisパッケージをインストールしようとしたときの出力です。

# sudo apt-get install python3-whois
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package python3-whois

apt-getを更新するために、次のコマンドを実行しました。

sudo apt-get update
sudo apt-get upgrade

インストールされているPythonのバージョンは3.7.5で、python3は/usr/bin/python3パスにあります。

修正する:

これは私の/etc/apt/sources.listファイルの内容です。

# 

# deb cdrom:[Debian GNU/Linux 2019.4 _Kali-rolling_ - Official Snapshot amd64 LIVE/INSTALL Binary 20191125-10:47]/ kali-last-snapshot contrib main non-free

#deb cdrom:[Debian GNU/Linux 2019.4 _Kali-rolling_ - Official Snapshot amd64 LIVE/INSTALL Binary 20191125-10:47]/ kali-last-snapshot contrib main non-free

# This system was installed using small removable media
# (e.g. netinst, live or single CD). The matching "deb cdrom"
# entries were disabled at the end of the installation process.
# For information about how to configure apt package sources,
# see the sources.list(5) manual.

deb http://http.kali.org/kali kali-rolling main non-free contrib

/var/log/apt/history.logで適切な変更ログを確認しましたが、私が実行したapt-getインストールコマンドに対応する情報がありませんでした。

Kali Linuxはデフォルトでapt-getリポジトリを構成していないようです。

上記のpython3パッケージをインストールする方法は?

ありがとうございます。

ベストアンサー1

Pythonが自分のものだと仮定pipパッケージマネージャ正しくインストールして設定したら、試してみてください。

pip install python-geoip-python3
pip install python-whois

不足しているパッケージをインストールします。インストールに応じてバイナリをpip3

おすすめ記事