๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ
Issues

PuTTY | Permission denied (publickey,gssapi-keyex,gassapi-with-mic) ํ•ด๊ฒฐ

by YIAN 2021. 11. 25.
728x90

 

๐Ÿฅง ์š”๊ตฌ์‚ฌํ•ญ (Requirements)

 

Permission denied (publickey,gssapi-keyex,gassapi-with-mic).

 

PuTTY๋ฅผ ์‹คํ–‰ํ•˜๊ณ  PuTTY Configuration์—์„œ session์„ ์ƒ์„ฑํ–ˆ์Šต๋‹ˆ๋‹ค. AWS EC2 ์„œ๋ฒ„์— ์ ‘์†ํ•˜๋ ค๋Š”๋ฐ ์œ„์™€ ๊ฐ™์€ ๋ฉ”์‹œ์ง€๊ฐ€ ๋œน๋‹ˆ๋‹ค. Pageant(PuTTY authentication agent)์— ssh-rsa ํ‚ค๋„ ์ž˜ ์ถ”๊ฐ€ํ•ด ์คฌ๋Š”๋ฐ, ์•Œ๊ณ  ๋ณด๋‹ˆ ๋ฌธ์ œ๋Š” PuTTY ์„ค์ •์— ์žˆ์—ˆ์Šต๋‹ˆ๋‹ค. ์›์ธ์„ ์ž˜ ๋ชจ๋ฅด๊ฒ ๋‹ค๋ฉด, ํ•œ ๋ฒˆ์ฏค ์˜์‹ฌํ•ด ๋ณผ ๋งŒํ•œ ๋‚ด์šฉ์„ ์ž‘์„ฑํ•ด ๋ณด์•˜์Šต๋‹ˆ๋‹ค.

 

 

๐Ÿ’ ํ•ด๊ฒฐ๋ฐฉ๋ฒ• (Solution or Next step)

 

[Connection] > [SSH] > [Auth] > [Allow agent forwarding] ์˜ต์…˜ ์ฒดํฌ

 

PuTTY Configuration ์ฐฝ์—์„œ ์™ผ์ชฝ์— ์žˆ๋Š” Category ์ชฝ์„ ๋ด์ฃผ์„ธ์š”. [Connection] > [SSH] > [Auth]๋ฅผ ์„ ํƒํ•ด ์ฃผ์„ธ์š”. ๋ณด์‹œ๋ฉด ์ค‘๊ฐ„์— Authentication parameters ์ชฝ์— [Allow agent forwarding] ์˜ต์…˜์ด ์ฒดํฌ๋˜์–ด ์žˆ๋Š”์ง€ ํ™•์ธํ•ด ์ฃผ์„ธ์š”. PuTTY์—์„œ ์ฒ˜์Œ Session์„ ์ƒ์„ฑํ•  ๋•Œ ํ•ด๋‹น ์˜ต์…˜์— ์ฒดํฌ๊ฐ€ ๋˜์–ด ์žˆ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

 

[Session] > Session ์„ ํƒ > [Load] > [Save]๋กœ ๋ณ€๊ฒฝ ๋‚ด์—ญ ์ €์žฅ

 

๋‹ค์‹œ Category์—์„œ [Session] > [Load, save or delete a stored session] > [Save Sessions]์˜ ๋ฆฌ์ŠคํŠธ์—์„œ ์ ‘์†์ด ์•ˆ๋˜์—ˆ๋˜ Session์„ ์„ ํƒํ•ด ์ฃผ์„ธ์š”. ์˜ค๋ฅธ์ชฝ์— ์žˆ๋Š” [Load] ๋ฒ„ํŠผ์„ ๋ˆŒ๋Ÿฌ์„œ ์„ ํƒ๋œ Session์„ ํ™•์ธํ•˜์…จ๋‹ค๋ฉด [Save] ๋ฒ„ํŠผ์„ ๋ˆŒ๋Ÿฌ์ฃผ์„ธ์š”. ์œ„์—์„œ ์ฒดํฌ๋œ ๋ณ€๊ฒฝ ๋‚ด์—ญ์„ ์ €์žฅํ•ด์•ผ ๋‹ค์Œ์— ์ ‘์†ํ•  ๋•Œ ๊ฐ™์€ ์˜ค๋ฅ˜๊ฐ€ ๋‚˜์ง€ ์•Š์„ ๊ฒƒ์ž…๋‹ˆ๋‹ค.

 

 

๐Ÿฅ• ํšŒ๊ณ  (Retrospective)

 

์ €์˜ ๊ฒฝ์šฐ์—๋Š” ๋งค์šฐ ๊ฐ„๋‹จํ•œ ๋ฌธ์ œ์˜€์Šต๋‹ˆ๋‹ค. 'ํ˜น์‹œ private key๊ฐ€ ๋ฌธ์ œ์ธ๊ฐ€?', 'PEM ํŒŒ์ผ์—์„œ PPK ํŒŒ์ผ๋กœ ๋ณ€ํ™˜ํ–ˆ๋Š”๋ฐ ์ž˜๋ชป ๋ณ€ํ™˜ํ–ˆ๋‚˜?' ๋“ฑ ๋งŽ์€ ์˜์‹ฌ์œผ๋กœ ์‚ฝ์งˆ์„ ํ–ˆ์—ˆ๋Š”๋ฐ์š”. ์ธํ”„๋ผํŒ€์— ๋ฌธ์˜ํ•ด์„œ ๋กœ๊ทธ๊นŒ์ง€ ํ™•์ธํ•ด ๋ณด๋‹ˆ ๋งค์šฐ ๊ฐ„๋‹จํ•œ ๋ฌธ์ œ์˜€์Œ์„ ์•Œ๊ฒŒ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. PuTTY์— ๋งŽ์ด ์ต์ˆ™ํ•ด์ ธ์•ผ๊ฒ ๋‹ค๊ณ  ๋‹ค์งํ–ˆ๋˜ ์ด์Šˆ ํ•ด๊ฒฐ ๊ฑด์ด์—ˆ์Šต๋‹ˆ๋‹ค. ๐Ÿ˜…

 

ํƒœ๊ทธ

๋Œ“๊ธ€0