debian10にmysqlをインストールする

debian10にmysqlをインストールする

私はDebianを初めて使用してmysqlをインストールしようとしていますが、次のコマンドを実行したとき:

sudo apt-get update
sudo apt-get upgrade 
sudo apt-get install mysql-server 

これにより、次のエラーが表示されます。

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package mysql-server 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 'mysql-server' has no installation candidate

また、sudo apt-get update コマンドを使用すると、次のエラーが発生します。

Ign:8 https://repo.mysql.com/apt/debian/dists/buster/mysql-8.0/binary-amd64/Packages buster InRelease
Ign:9 https://repo.mysql.com/apt/debian/dists/buster/mysql-tools/binary-i386/Packages buster InRelease
Err:10 https://repo.mysql.com/apt/debian/dists/buster/mysql-8.0/binary-amd64/Packages buster Release
  Redirection from https to 'http://www.mysql.com/downloads/embargo.html' is forbidden [IP: 2.20.149.25 443]
Ign:11 http://ppa.launchpad.net/webupd8team/atom/ubuntu eoan InRelease                      
Err:12 https://repo.mysql.com/apt/debian/dists/buster/mysql-tools/binary-i386/Packages buster Release
  Redirection from https to 'http://www.mysql.com/downloads/embargo.html' is forbidden [IP: 2.20.149.25 443]
Err:13 http://ppa.launchpad.net/noobslab/apps/ubuntu eoan Release                           
  404  Not Found [IP: 91.189.95.83 80]

ベストアンサー1

Debian では、MySql は標準リポジトリで使用できません。 MariaDBとそのパッケージと同等のものがありますmariadb-server。エラーに関しては、いくつかのチュートリアルに従い(私の考えでは)、リポジトリにいくつかの混乱を引き起こしたことに違いありません。リポジトリリストに何が追加されたのか、何がインストールされたのか、何が削除されるのかを正確に把握するようにしましょう。この情報は、シェル履歴およびパッケージ管理ログから入手できます。

より包括的な回答を提供するには、MySql を使い続け、インストーラからインストールすることをお勧めしますが、実際にそうすることを確認してください。これは Debian のデフォルトの MariaDB よりも難しいアプローチです。

おすすめ記事