การหา Python path ใน CentOS สามารถทำได้หลายวิธี ดังนี้คือวิธีที่ง่ายที่สุด
เปิด terminal แล้วรันคำสั่ง python หรือ python3 (ขึ้นอยู่กับเวอร์ชันของ Python ที่คุณใช้)
python -c "import sys; print('\n'.join(sys.path))" python3 -c "import sys; print('\n'.join(sys.path))"
หรือ ถ้าคุณต้องการทราบที่ตั้งของตัวติดตั้ง Python ที่ใช้งานอยู่ คุณสามารถใช้คำสั่งนี้
which python which python3
คำสั่งนี้จะแสดง path ที่ใช้งานตัว interpreter Python ในขณะนี้