-bash: python: command not found

1 개요[ | ]

-bash: python: command not found
python installed in ubuntu but python command not found
root@wsl:~# python -V
-bash: python: command not found
root@wsl:~# python3 -V
Python 3.9.2

2 방법1: alias 등록[ | ]

root@wsl:~# echo alias python='python3' >> ~/.bashrc
root@wsl:~# source ~/.bashrc
Docker is running.
root@wsl:~# python -V
Python 3.9.2

3 방법2: 심볼릭링크 생성[ | ]

root@wsl:~# which python3
/usr/bin/python3
root@wsl:~# ln -s /usr/bin/python3 /usr/bin/python
root@wsl:~# python -V
Python 3.9.2

4 같이 보기[ | ]

5 참고[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}