Child pages
  • Installing Python Modules In Linux
Skip to end of metadata
Go to start of metadata

Central Installation

We install various python modules for use on the SoIC unified Linux systems.  In addition, we have multiple versions of python available via environment modules.  The default version of python that is installed may have fewer available modules than the versions available via modules so you are encouraged to try the other versions using environment modules.

If you need a python module installed, please just submit a service request letting us know what modules you need.  In your request, please let us know if you are using the stock version of python or a newer version we make available via environment modules.  The advantages of having the IT staff install python modules centrally include 1) you don't have to do it yourself and take up your own disk quota, 2) they are available to all users, and 3) they are available on all of the unified linux systems we manage.

Personal Installation

In some cases, you may want to just install python modules yourself.  If you want to do this, it is very simple and does not require any special root/sudo permissions.  All you need to do is just use the --user option to pip and it will be installed in your own home directory and be automatically accessible by you (but not other users).  For example, if you wanted to install a module into your own python library directory you would just run:

 

pip install --user package_name

You just need to replace package_name with the official name of the python module.

When you use the --user option, pip will install the module into a default location for that system.  For example, on the RHEL 7 systems with the stock python 2.7, the module will end up being written into your ~/.local/lib/python2.7 and/or ~/.local/bin directories.