Installing Python tools for Openstack

This procedure is to install the Openstack client on Linux. This requires Python 2.7.  We’ll also install and configure pip to download packages form PyPi

List of items

  • Install Python 2.7.14
  • Install Setup tools
  • Install Pip
  • Install pbr
  • Install Positional
  • Install pyton-openstackclient

Instructions

  • Install Python 2.7.14. Install from src
    • ./configure –prefix /usr/local;make; make install
  • Install Setup tools.  Install from src
    • pyton setup.py build;python setup.py install
  • Install Pip.  Install from src
    • python setup.py build; python setup.py install
    • To configure pip add the following to /root/.pip/pip.conf
      • [global]
        timeout=60
        index-url=https://<<address to pip or pip proxy>>
        trusted-host=<<fqdn_of_host>>
        [list]
        format=columns
  • Install pbr.  Install from pip
    • pip install pbr
  • Install Positional.  Install from src
    • python setup.py build; python setup.py install
  • Install pyton-openstackclient.  Install from pip
    • pip install python-openstackclient

Make sure that the time on your server is correct.  You might need to resync it to the ntp server.

Now you can test the openstack client.  Make sure that you source the appropriate profile to point to your Openstack cloud

# openstack –insecure server list

 

Using a proxy in Linux to download a file

There are times when you need internet access from a Linux system to download an RPM.  Say to download the latest version of elastisearch.

For example here’s the link to a recent version:  https://www.elastic.co/downloads/elasticsearch#ga-release

Now let’s say you want to download the file from a Linux system.  Typically Linux servers don’t have public access to the internet.  But you could leverage your corporate proxy.  So speak with your network admin to secure access to the proxy.  Sometimes the proxy is opened internally and sometimes you’ll need to use your Active Directory credentials.   Typically you can find out the IP of the proxy by looking at the Internet Explorer settings on your Windows  desktop.

Once you’ve identified the proxy you can configure it as follows

# export https_proxy=<hostname>:8080

Then you can download your RPM

# wget –no-check-certificate https://www.elastic.co/downloads/elasticsearch#ga-release