หน้าเว็บ

วันอาทิตย์ที่ 21 มิถุนายน พ.ศ. 2552

apt-get /usr/bin/python does not match the python default version. It must be reset to point to python2.6

ถ้าเกิดว่าใช้คำสั่ง apt-get upgrade หรือ apt-get install แล้วใน error มีคำว่า
/usr/bin/python does not match the python default version. It must be reset to point to python2.6
และลงท้ายว่า E: Sub-process /usr/bin/dpkg returned an error code (1)

อาจเกิดจากการที่เราสั่งเปลี่ยน version ของ python ในระบบเรา ซึ่งถึงแม้เราเปลี่ยนกลับแล้วก็แก้ไม่ได้

ให้แก้โดย ลบ link python เดิมออก แล้วสร้าง softlink ใหม่ดังนี้
sudo rm /usr/bin/python && ln -s /usr/bin/python2.6 /usr/bin/python

ระบบที่ทดสอบ
OS: Ubuntu 9.04
Python: 2.6

ที่มา
http://www.linuxforums.org/forum/ubuntu-help/146571-solved-upgrade-doesn-t-work.html

ไม่มีความคิดเห็น: