Installation Guide: Difference between revisions
⚠️HuidaeCho (talk | contribs) |
|||
| (78 intermediate revisions by 14 users not shown) | |||
| Line 1: | Line 1: | ||
== General == | == General == | ||
:''Note: For compilation of GRASS GIS source code, see [[Compile and Install]]'' | |||
This page explains the installation of GRASS binaries. | |||
GRASS GIS requires a workstation running either some flavor of UNIX conforming to POSIX standards like Linux, Mac OS X, Solaris, IRIX, or BSD or MS-Windows. It is also possible to run GRASS in MS Windows by using UNIX translation software such as [[Cygwin]] or natively with MingGW. Ideally, you should have at least 500 Mb for data and 512 Mb RAM. The source code package needs around 270 MB uncompressed. The resulting binaries may need between 20 MB and 180 MB depending on your platform. During a full compilation you may need temporarily up to 150MB including the source code. | |||
The [https://grass.osgeo.org/download/ Software Download Section] of the main GRASS web site contains the latest binaries and source code for all supported platforms. That site also has general directions for installing GRASS manually. However, installation is slightly different on each operating system. Here you can find user-contributed pointers for installing GRASS on specific platforms. In particular, many operating systems have package management utilities that can greatly simplify GRASS installation. | |||
== MS Windows == | |||
The [ | :''The official download page [https://grass.osgeo.org/download/windows/ GRASS GIS for MS-Windows]'' | ||
There are two main flavours: | |||
* '''OSGeo4W installer''', for a broad set of open source geospatial software packages including GRASS GIS as well as many other packages (QGIS, GDAL/OGR, and more). Advantages include: 1) Whenever you run the OSGeo4W installer again, it updates the existing installation. 2) The OSGeo4W installer simplifies the installation of GDAL, which is needed for some GRASS tasks. | |||
* '''Standalone winGRASS installer''': install GRASS GIS for Windows with the required support packages. Note that if the version of the winGRASS installer does not include the GDAL package, it may be necessary to install it separately for certain GRASS tasks. The OSGeo4W installer is helpful for installing GDAL on Windows. | |||
=== OSGeo4W installer === | |||
OSGeo4W is an installer for a broad set of open source geospatial software packages including GRASS GIS as well as many other packages (QGIS, GDAL/OGR, and more). Advantages include: 1) Whenever you run the OSGeo4W installer again, it updates the existing installation. 2) The OSGeo4W installer simplifies the installation of GDAL which is needed for some GRASS tasks. | |||
* Install using [https://trac.osgeo.org/osgeo4w/ OSGeo4W installer] which installs all dependencies as well (PROJ, GDAL, GEOS, Python, etc.) | |||
==== Launch the OSGeo4W installer ==== | |||
Save and run the downloaded installer as an ''administrator'' (consider keeping it for convenient future updates). | |||
To ensure you are running the OSGeo4W installer as an administrator, it is recommended to right-click on the installer and select ''Run as administrator ''(rather than opening/running it directly, e.g. left-clicking or double-clicking). | |||
(This is because with Windows 11 the ''desktop'', ''download'', and ''documents'' directories are located in a standard user account directory, e.g. C:\User\username, that is created by default and ''do not have administrator privileges'' - even on personal, single-user laptops when the user is also the administrator.) | |||
"The installer must be run on a computer with internet access, as the installer downloads individual packages as needed." This means it may be necessary "to enable your software firewall to allow the installer to have outbound access." For example, pausing vpn security features before starting the installation (and for long enough for the duration of the installation). | |||
You can select either the grass (stable) or grass-daily (development) packages to install. | |||
[[Image:Osgeo4w_1.png|center|thumb|500px|Install with "Administrator" rights]] | |||
==== Variant A) Express installation ==== | |||
The "Express Desktop Install" mode installs the stable version of GRASS. The OSGeo4W Quick Start guidance recommends running the "Express Installation" over a 'full install in Advanced mode'. | |||
[[Image:Osgeo4w_2_express.png|center|thumb|500px|Use "Express installation" to select stable version]] | |||
For a GRASS GIS installation, select both GRASS and GDAL. | |||
[[Image:Osgeo4w_3_express.png|center|thumb|500px|The options you see with the current version of the OSGeo4W installer may differ from those in the image above - the important thing is to select both GRASS and GDAL for installation]] | |||
. | |||
The Express Installation will make a directory called OSGeo4W on the C drive and install the packages there. | |||
If there is a problem with the OSGeo4W installation, reading the generated log file is useful for identifying and resolving the issue(s). | |||
Commonly installed Python packages include: | |||
* python3-gdal | |||
* python3-matplotlib | |||
* python3-wx | |||
* python3-numpy | |||
* python3-pillow | |||
* python3-pip | |||
* python3-ply | |||
* python3-pyopengl | |||
* python3-psycopg2 | |||
* python3-six | |||
* python3-pywin32 | |||
The "Advanced Install" mode can be used after an initial "Express Install" to install additional useful packages (e.g. python3-pandas, msys). | |||
==== Variant B) Advanced installation ==== | |||
Use the "Advanced Install Mode" to customise the installation of the stable version or to install the development version of GRASS. Remember, the OSGeo4W installer should be run as an administrator (right-click to select the Run as administrator option), and internet security features/settings need to allow the installer internet access. | |||
If installing GRASS and GDAL using the Advanced Installation mode, do not attempt a full install (i.e., all options selected). Be selective, knowing that the OSGeo4W installer will alert you if key dependencies are missed and suggest they be added before proceeding with the installation. | |||
[[Image:Osgeo4w_2_advanced.png|center|thumb|500px|Use "Advanced installation" to select development version]] | |||
[[Image:Osgeo4w_3_advanced.png|center|thumb|500px| Please note that this image was from a former version of the OSGeo4W installer and GRASS (7.9), so it will look a little different for you now.]] | |||
Unlike the Express mode, the Advanced Installation mode allows you to specify the directory for installation of the OSGeo4W packages, but the installation will fail if there is a space in the name/path (e.g., Program Files). | |||
If you plan to use the OSGeo4W installer for future updates on Windows, keep the directory you selected for the installation in mind as the Express mode default is OSGeo4W on the C: drive. | |||
If there is a problem with the OSGeo4W installation of GRASS, reading the generated log file is useful for identifying and resolving the issue(s). | |||
=== winGRASS standalone installer === | |||
* Native winGRASS package installer is available [https://grass.osgeo.org/grass-stable/binary/mswindows/native/ here]. | |||
=== QGIS with winGRASS installer === | |||
* QGIS including native winGRASS packages are provided [https://www.qgis.org/wiki/Download here]. | |||
== GNU/Linux == | == GNU/Linux == | ||
:''The official page [https://grass.osgeo.org/download/linux/ GRASS GIS Download for GNU/Linux]'' | |||
=== Debian === | === Debian === | ||
| Line 16: | Line 104: | ||
apt-get install grass grass-doc | apt-get install grass grass-doc | ||
This is the easiest way to install GRASS on Debian. If you choose to install a binary version manually from the main web site, be sure to follow the instructions for making symlinks found as a note to the [[ | This is the easiest way to install GRASS on Debian. If you choose to install a binary version manually from the main web site, be sure to follow the instructions for making symlinks found as a note to the [[https://grass.osgeo.org/grass-stable/binary/linux/snapshot/ GRASS GIS stable weekly snapshot]] release. | ||
==== | ==== DebianGIS ==== | ||
There is also the | There is also the wonderful [https://wiki.debian.org/DebianGis DebianGIS] project which has a more recent GRASS version with its related packages. Read here for more [[GRASS in Debian |details]] | ||
==== Compiling GRASS from source ==== | |||
* See [[Compile and Install]] of Source Code | |||
=== | === Installation on Fedora === | ||
The [https://src.fedoraproject.org/rpms/grass Fedora project] provides RPM-packages for stable releases prepared to install on Fedora systems: | |||
= | <source lang="bash"> | ||
sudo dnf install grass grass-gui | |||
</source> | |||
=== Mageia === | |||
* [https://madb.mageia.org/package/show/name/grass/ Mageia] provides PROJ/GDAL/GRASS RPMs: | |||
urpmi grass | |||
=== openSUSE === | |||
* [https://build.opensuse.org/package/show/Application:Geo/grass openSUSE] provides GRASS and related RPM-packages: | |||
<source lang="bash"> | |||
sudo zypper refresh | |||
sudo zypper install grass | |||
</source> | |||
Alternatively, one can use the '''One-Click installer''': | |||
https://software.opensuse.org/package/grass | |||
=== Red Hat Enterprise Linux (RHEL, CentOS and EPEL) === | |||
* [https://src.fedoraproject.org/rpms/grass Fedora] offers GRASS and related binaries for CentOS and EPEL | |||
<source lang="bash"> | |||
dnf install grass | |||
</source> | |||
=== Ubuntu === | === Ubuntu === | ||
| Line 60: | Line 158: | ||
To get the latest version of GRASS on Ubuntu, compile the code from source. See the [[Compile and Install]] section for a shell script that makes this easy. | To get the latest version of GRASS on Ubuntu, compile the code from source. See the [[Compile and Install]] section for a shell script that makes this easy. | ||
== | == MacOS == | ||
Precompiled GRASS GIS packages for macOS can be found [https://grass.osgeo.org/download/mac here]. These are distributed as zipped *.dmg packages. Opening the dmg prompts the user to simply drag and drop the app into the Applications folder. In fact, they '''must''' be installed into the Applications folder and may not run properly in other locations. | |||
A brief introduction to how to install via [https://www.macports.org MacPorts]: [[Compiling on macOS using MacPorts]]. | |||
== Raspberry Pi == | |||
:''See the main page [[Raspberry Pi]].'' | |||
[[Category:Documentation]] | [[Category:Documentation]] | ||
[[Category:Installation]] | [[Category:Installation]] | ||
Latest revision as of 23:58, 15 April 2026
General
- Note: For compilation of GRASS GIS source code, see Compile and Install
This page explains the installation of GRASS binaries.
GRASS GIS requires a workstation running either some flavor of UNIX conforming to POSIX standards like Linux, Mac OS X, Solaris, IRIX, or BSD or MS-Windows. It is also possible to run GRASS in MS Windows by using UNIX translation software such as Cygwin or natively with MingGW. Ideally, you should have at least 500 Mb for data and 512 Mb RAM. The source code package needs around 270 MB uncompressed. The resulting binaries may need between 20 MB and 180 MB depending on your platform. During a full compilation you may need temporarily up to 150MB including the source code.
The Software Download Section of the main GRASS web site contains the latest binaries and source code for all supported platforms. That site also has general directions for installing GRASS manually. However, installation is slightly different on each operating system. Here you can find user-contributed pointers for installing GRASS on specific platforms. In particular, many operating systems have package management utilities that can greatly simplify GRASS installation.
MS Windows
- The official download page GRASS GIS for MS-Windows
There are two main flavours:
- OSGeo4W installer, for a broad set of open source geospatial software packages including GRASS GIS as well as many other packages (QGIS, GDAL/OGR, and more). Advantages include: 1) Whenever you run the OSGeo4W installer again, it updates the existing installation. 2) The OSGeo4W installer simplifies the installation of GDAL, which is needed for some GRASS tasks.
- Standalone winGRASS installer: install GRASS GIS for Windows with the required support packages. Note that if the version of the winGRASS installer does not include the GDAL package, it may be necessary to install it separately for certain GRASS tasks. The OSGeo4W installer is helpful for installing GDAL on Windows.
OSGeo4W installer
OSGeo4W is an installer for a broad set of open source geospatial software packages including GRASS GIS as well as many other packages (QGIS, GDAL/OGR, and more). Advantages include: 1) Whenever you run the OSGeo4W installer again, it updates the existing installation. 2) The OSGeo4W installer simplifies the installation of GDAL which is needed for some GRASS tasks.
- Install using OSGeo4W installer which installs all dependencies as well (PROJ, GDAL, GEOS, Python, etc.)
Launch the OSGeo4W installer
Save and run the downloaded installer as an administrator (consider keeping it for convenient future updates).
To ensure you are running the OSGeo4W installer as an administrator, it is recommended to right-click on the installer and select Run as administrator (rather than opening/running it directly, e.g. left-clicking or double-clicking).
(This is because with Windows 11 the desktop, download, and documents directories are located in a standard user account directory, e.g. C:\User\username, that is created by default and do not have administrator privileges - even on personal, single-user laptops when the user is also the administrator.)
"The installer must be run on a computer with internet access, as the installer downloads individual packages as needed." This means it may be necessary "to enable your software firewall to allow the installer to have outbound access." For example, pausing vpn security features before starting the installation (and for long enough for the duration of the installation).
You can select either the grass (stable) or grass-daily (development) packages to install.

Variant A) Express installation
The "Express Desktop Install" mode installs the stable version of GRASS. The OSGeo4W Quick Start guidance recommends running the "Express Installation" over a 'full install in Advanced mode'.

For a GRASS GIS installation, select both GRASS and GDAL.

.
The Express Installation will make a directory called OSGeo4W on the C drive and install the packages there.
If there is a problem with the OSGeo4W installation, reading the generated log file is useful for identifying and resolving the issue(s).
Commonly installed Python packages include:
- python3-gdal
- python3-matplotlib
- python3-wx
- python3-numpy
- python3-pillow
- python3-pip
- python3-ply
- python3-pyopengl
- python3-psycopg2
- python3-six
- python3-pywin32
The "Advanced Install" mode can be used after an initial "Express Install" to install additional useful packages (e.g. python3-pandas, msys).
Variant B) Advanced installation
Use the "Advanced Install Mode" to customise the installation of the stable version or to install the development version of GRASS. Remember, the OSGeo4W installer should be run as an administrator (right-click to select the Run as administrator option), and internet security features/settings need to allow the installer internet access.
If installing GRASS and GDAL using the Advanced Installation mode, do not attempt a full install (i.e., all options selected). Be selective, knowing that the OSGeo4W installer will alert you if key dependencies are missed and suggest they be added before proceeding with the installation.


Unlike the Express mode, the Advanced Installation mode allows you to specify the directory for installation of the OSGeo4W packages, but the installation will fail if there is a space in the name/path (e.g., Program Files).
If you plan to use the OSGeo4W installer for future updates on Windows, keep the directory you selected for the installation in mind as the Express mode default is OSGeo4W on the C: drive.
If there is a problem with the OSGeo4W installation of GRASS, reading the generated log file is useful for identifying and resolving the issue(s).
winGRASS standalone installer
- Native winGRASS package installer is available here.
QGIS with winGRASS installer
- QGIS including native winGRASS packages are provided here.
GNU/Linux
- The official page GRASS GIS Download for GNU/Linux
Debian
A binary version of GRASS is available from the apt repository. As root type:
apt-get install grass grass-doc
This is the easiest way to install GRASS on Debian. If you choose to install a binary version manually from the main web site, be sure to follow the instructions for making symlinks found as a note to the [GRASS GIS stable weekly snapshot] release.
DebianGIS
There is also the wonderful DebianGIS project which has a more recent GRASS version with its related packages. Read here for more details
Compiling GRASS from source
- See Compile and Install of Source Code
Installation on Fedora
The Fedora project provides RPM-packages for stable releases prepared to install on Fedora systems:
sudo dnf install grass grass-gui
Mageia
- Mageia provides PROJ/GDAL/GRASS RPMs:
urpmi grass
openSUSE
- openSUSE provides GRASS and related RPM-packages:
sudo zypper refresh
sudo zypper install grass
Alternatively, one can use the One-Click installer: https://software.opensuse.org/package/grass
Red Hat Enterprise Linux (RHEL, CentOS and EPEL)
- Fedora offers GRASS and related binaries for CentOS and EPEL
dnf install grass
Ubuntu
GRASS Binaries are available from apt/synaptic. From a terminal type:
sudo apt-get install grass grass-doc
or alternatively, search for and install these packages from Synaptic. This is the easy way to get GRASS on your system. Even if you choose to install binaries from another source, you may want to install this version just so that all (most) dependencies are installed as painlessly as possible.
To get the latest version of GRASS on Ubuntu, compile the code from source. See the Compile and Install section for a shell script that makes this easy.
MacOS
Precompiled GRASS GIS packages for macOS can be found here. These are distributed as zipped *.dmg packages. Opening the dmg prompts the user to simply drag and drop the app into the Applications folder. In fact, they must be installed into the Applications folder and may not run properly in other locations.
A brief introduction to how to install via MacPorts: Compiling on macOS using MacPorts.
Raspberry Pi
- See the main page Raspberry Pi.