Change the default python version in ubuntu

Ubuntu automatically installs python 2.5 and uses it as the default python … I have crashed my system 2 times to solve this .. I wanted to make the default python to version 2.4.

This is the way

before begaining Thanks to (Luiz Rocha (lsdr) )



edit the /usr/share/python/debian_defaults, changing the default version arg to python2.4


$ sudo mv /usr/bin/python /usr/bin/python25
$ sudo ln -s /usr/bin/python2.4 /usr/bin/python


Work is fun!

Tagged with: , , , , , ,
Posted in Uncategorized
15 comments on “Change the default python version in ubuntu
  1. darkblue_b says:

    thank you for this simple tip

  2. tareqalam says:

    you are welcome

  3. Alex Marandon says:

    Thanks for this useful tip. It helped for switching from 2.6 back to 2.5 on Ubuntu 9.04 (Jaunty Jackalope) as well.

    The symlink can be updated with this single command:

    sudo ln -sf /usr/bin/python2.5 /usr/bin/python

  4. Bergen says:

    Thanks, appreciated.

  5. bashasha says:


  6. Ricardo says:

    awesome tip! save my work!! 😉

  7. Russ says:

    Fantastic. Simple and easy. Took me a while to find this information and was happy to find your site. Thanks!

  8. Russ says:

    Word of caution. After trying the same process with python 2.6 and 3.1.2, Ubuntu software center would not run. I am using Ubuntu 10.04 and the incompatibility of python 2 and 3 doesn’t allow a simple switching like this.

    I set it up to call python 3.1 and the system can’t some of the built in software that depends on python 2. I used the same process above to re-link the python command to python 2.6 and all is fixed.

  9. Milton Waddams says:

    Fantastic, just what I needed.

  10. Ariel says:

    Good respond in return of this issue with real arguments and telling everything on
    the topic of that.

  11. After I originally left a comment I appear to have clicked on
    the -Notify me when new comments are added- checkbox and now whenever a comment is added I get four emails with the exact
    same comment. Is there an easy method you are able
    to remove me from that service? Appreciate it!

  12. I am regular visitor, how are you everybody?
    This paragraph posted at this web site is really fastidious.

  13. I loved as much as you’ll receive carried out
    right here. The sketch is attractive, your authored subject matter
    stylish. nonetheless, you command get got an shakiness over
    that you wish be delivering the following. unwell unquestionably come
    more formerly again since exactly the same nearly very often inside case you shield this hike.

  14. If you would like to take much from this post then you have to apply such strategies to your
    won website.

  15. tareqalam says:

    not sure how to do that sorry 😦

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

All content provided on this "" blog is for informational purposes only. The owner of this blog makes no representations as to the accuracy or completeness of any information on this site or found by following any link on this site. The owner of [] will not be liable for any errors or omissions in this information nor for the availability of this information. The owner will not be liable for any losses, injuries, or damages from the display or use of this information.
November 2008
« Oct   Dec »

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 23 other followers

%d bloggers like this: