개요
플레이북 실행시 아래와 같은 에러가 발생
fatal: [ansible-jenkins]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the host via ssh: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r\n@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @\r\n@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r\nIT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also possible that a host key has just been changed.\r\nThe fingerprint for the ED25519 key sent by the remote host is\nSHA256:WWibrEBMsHoAr2OOFEWjOufI+p4LUgzMy8IgkrfA0Kg.\r\nPlease contact your system administrator.\r\nAdd correct host key in /var/lib/jenkins/.ssh/known_hosts to get rid of this message.\r\nOffending ECDSA key in /var/lib/jenkins/.ssh/known_hosts:3\r\n remove with:\r\n ssh-keygen -f \"/var/lib/jenkins/.ssh/known_hosts\" -R \"ansible-jenkins\"\r\nPassword authentication is disabled to avoid man-in-the-middle attacks.\r\nKeyboard-interactive authentication is disabled to avoid man-in-the-middle attacks.\r\nUpdateHostkeys is disabled because the host key is not trusted.\r\nseo@ansible-jenkins: Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password,keyboard-interactive).", "unreachable": true}
원인
- ansible-jenkins라는 서버가 물리적으로 교체되었는데 이에따라 SSH키가 변경되어서 기존에 저장된 SSH키와 매칭이 안되어 오류가 발생
해결방법
CENTOS와 다르게 우분투에서의 젠킨스 KNOWN_HOSTS파일은 암호화가 되어있어
아래명령어로 제거를 해줘야한다.
'인프라 > 젠킨스(jenkins)' 카테고리의 다른 글
[JENKINS] html 코드 markup format 적용 안될 때 해결방법 (0) | 2024.02.08 |
---|---|
[JENKINS] 젠킨스 에러 We trust you have received the usual lecture from the local System (0) | 2024.02.02 |
[JENKINS] CENTOS 젠킨스 업그레이드 2.443 (0) | 2024.01.31 |
[JENKINS] 젠킨스 audit로그 로그인 기록 설정하기 (0) | 2023.12.05 |
[jenkins] 젠킨스 credentials 패스워드 평문 확인하기 (0) | 2023.09.12 |
댓글