EWX config

From CHG-Wiki
Revision as of 13:14, 18 December 2014 by Libby (talk | contribs) (Adding Windows transclusion.)
Jump to navigationJump to search

This page documents the process of installing EWX on different operating systems.

Windows Server 2008 r2

Updating EWX with EROS Python Requirements

Per ederer's request, Libby performed the following updates on chg2 to bring the EWX installation in line with the EROS setup:

  • Installed python27 (python27 was already installed as part of ArcGIS 10.1, but because that particular version may be needed by ArcGIS, python-2.7.8.amd64.msi was installed along side it).
  • Added a PYTHONPATH environment variable and added %PYTHONPATH% to path environment variable.
  • Tested python installation by
    • Opened DOS window
    • Entered 'python and enter'
      • Success!
  • Installed numpy using the installation provided in the 'EWX_package_for_Greg' folder in chg2's ftproot (it is an exe).
  • MS Visual C++ 2008 Redistributable 64x already installed (this is required by GDAL).
  • Installed GDAL core (used gdal-111-1600-x64-core.msi, 'package for Greg' version is gdal-110-1500-x64-core.msi)
    • Added GDAL (C:\Program Files\GDAL) to 'path' in environment variable.
    • Installed GDAL python binding ('package for Greg' version is GDAL-1.10.0.win-amd64-py2.7, installed GDAL-1.11.0.win-amd64-py2.7.msi)
    • Created environment variables (are we sure these aren't reversed?)
      • GDAL_DATA - C:\Program Files\GDAL\gdalplugins
      • GDAL_DRIVER_PATH - C:\Program Files\GDAL\gdal-data
    • Tested GDAL installation by
      • Opened DOS window
      • Entered 'gdalinfo' --version
      • Success!
  • Extracted geos-3.2.2-1.tar.bz2 (downloaded from www.filewatcher.com/m/geos-3.2.2-1.tar.bz2.427238-0.html before Libby was aware of the 'package for Greg' folder).
  • Added geos_c.dll to C:\Python27\Lib\site-packages\shapely\DLLs
    • Added GEOS_LIBRARY_PATH - C:\Python27\Lib\site-packages\shapely\DLLsgeos_c.dll environment variable.
  • Installed pip
    • Copied get-pip.py to python27 folder from EWX_package_for_Greg\PythonInstallation\pip.
    • In a command prompt, navigated to python27 folder and entered 'python get-pip.py'.
      • (to upgrade) python -m pip install -U pip
  • Installed Shapely
    • Used executable found in 'EWX_package_for_Greg\PythonInstallation\Shapely' (Shapely-1.3.0.win-amd64-py2.7.exe).
      • (to upgrade) python -m pip install Shapely --upgrade
  • Installed rasterstats module
    • Enter into command prompt:
python -m pip install https://pypi.python.org/packages/source/r/rasterstats/rasterstats-0.3.3.tar.gz 

(Downloads and install only when new version is needed.)

python -m pip install rasterstats 

(Downloads and installs.)

  • Replaced the rasterStats module with EROS's updated source code (found in 'package for Greg' folder) by placing main.py in C:\Python27\Lib\site-packages\rasterstats (old main.py saved as main-org.py)
  • Tested installation by running 'rasterstat_test.py' script to ensure it runs without errors ('rasterstat_test.py' ran with some errors, but they seem to be due to filepath issues originating from the fact that all EROS scripts are filepath specific for the EROS server and do not match chg2's.)
    • 'rasterstat_test.py is in 'EWX_package_for_Greg\PythonInstallation\scripts'.


Ubuntu 12.04.5 LTS (Precise Pangolin)

CentOS 6.5