debian9에 git을 설치할 수 없습니다(스트레치).

debian9에 git을 설치할 수 없습니다(스트레치).

다음을 입력하면 Debian 9(stretch) 컴퓨터에 git을 설치하고 싶습니다.

sudo apt install git-all

다음 메시지가 나타납니다.

Reading package lists... Done

Building dependency tree        Reading state information... Done 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 followi`ng information may help to resolve the situation:

The following packages have unmet dependencies:

 git-all : Depends: git (> 1:2.25.0) but it is not going to be installed
           Depends: git (< 1:2.25.0-.) but it is not going to be installed
           Depends: git-el but it is not going to be installed
           Depends: git-cvs but it is not going to be installed
           Depends: git-mediawiki but it is not going to be installed
           Depends: git-svn but it is not going to be installed
           Depends: git-email but it is not going to be installed
           Depends: git-gui but it is not going to be installed
           Depends: gitk but it is not going to be installed
           Depends: gitweb but it is not going to be installed
           Recommends: git-daemon-run but it is not going to be installed or
                       git-daemon-sysvinit but it is not going to be installed
E: Unable to correct problems, you have held broken packages

도움이 되었으면 좋겠습니다. 미리 감사드립니다.

편집하다

다음을 입력해도 아무 일도 일어나지 않습니다.

sudo dpkg --configure -a

이 명령의 결과:

sudo apt update && sudo apt upgrade

다음은 메시지입니다.

Hit:1 http://security.debian.org stretch/updates InRelease                                                                                           
Ign:2 http://deb.debian.org/debian stretch InRelease                                                                                                 
Ign:3 http://httpredir.debian.org/debian stretch InRelease                                                                                           
Hit:4 http://ppa.launchpad.net/git-core/ppa/ubuntu focal InRelease                                                                                   
Hit:5 http://deb.debian.org/debian stretch-updates InRelease                                                                                         
Ign:6 http://repo.mongodb.org/apt/debian stretch/mongodb-org/4.0 InRelease                                                                           
Hit:7 http://httpredir.debian.org/debian stretch Release                                                                                             
Hit:8 http://repository.spotify.com stable InRelease                                                                                                 
Hit:9 http://deb.debian.org/debian stretch Release                                                                                        
Hit:12 http://repo.mongodb.org/apt/debian stretch/mongodb-org/4.0 Release                                           
Hit:13 http://ppa.launchpad.net/webupd8team/java/ubuntu xenial InRelease 
Hit:16 http://ppa.launchpad.net/webupd8team/java/ubuntu bionic InRelease
Get:17 https://dl.yarnpkg.com/debian stable InRelease [17.1 kB]                
Get:18 https://deb.nodesource.com/node_9.x stretch InRelease [4,623 B]
Hit:19 http://ppa.launchpad.net/webupd8team/java/ubuntu cosmic InRelease                                                                             
Hit:20 https://repo.skype.com/deb stable InRelease                                                                                                   
Ign:10 https://get.docker.com/ubuntu docker InRelease                                                                                                
Get:21 https://get.docker.com/ubuntu docker Release [1,525 B]
Get:22 https://get.docker.com/ubuntu docker Release.gpg [473 B]
Ign:22 https://get.docker.com/ubuntu docker Release.gpg
Reading package lists... Done   
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11 (main/dep11/Components-amd64.yml) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11 (main/dep11/Components-all.yml) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11-icons (main/dep11/icons-64x64.tar) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: GPG error: https://get.docker.com/ubuntu docker Release: The following signatures were invalid: 36A1D7869245C8950F966E92D8576A8BA88D21E9
E: The repository 'http://get.docker.io/ubuntu docker Release' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11 (main/dep11/Components-amd64.yml) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11 (main/dep11/Components-all.yml) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1
W: Target DEP-11-icons (main/dep11/icons-64x64.tar) is configured multiple times in /etc/apt/sources.list:18 and /etc/apt/sources.list.d/base.list:1

답변1

문제는 이것이다:

http://ppa.launchpad.net/git-core/ppa/ubuntu focal

Debian 9에서는 Ubuntu Focus PPA를 사용할 수 없습니다. 구성에서 이를 제거하면 git을 설치할 수 있습니다.

아마도 당신에게도 필요하지 않을 것입니다 git-all.

sudo apt install git

그 정도면 충분합니다.

관련 정보