NOTE: This blog assumes that your Linux system utilizes systemd as your system and service manager. Also, this blog assumes you’re SSH’ed into a Linux system from a separate client machine.
In contrast to its Windows counterpart, Linux users often spend their time in a terminal. Within ArcGIS Enterprise, many tools come with the capability to run silently or through a UI. For Linux users, there are times where the UI option is preferred, but what if you’re in a headless environment?
In this Monthly Linux Tip, we will look at how we can configure our Linux systems to view ArcGIS Enterprise tools using a UI within a headless environment. The table of contents below breaks down today’s blog:
- Headless or GUI-based environment?
- Understanding systemctl get-default
- Exporting the DISPLAY environment variable
- Running the desired tool
- Wrap-up
1. Headless or GUI-based environment?
The first point to start from is understanding the machine in which you’re working in; headless or GUI? “Headless Linux” is a term meant to describe a Linux system with no monitor or keyboard. Often, VMs have this configuration, unless customized to have GUI elements.
If you are within a GUI-based environment, then you have the flexibility to use both the terminal and GUI.
2. Understand systemctl get-default
In a nutshell, Linux environment have what are known as target units. These units allow a system to start services required for a specific purpose. To find the default target unit your machine has, run the command systemctl get-default:
It will differ machine to machine, but usually you will see graphical.target or multi-user.target. Assuming that you are in an SSH session from a client machine, the result does not matter too much. However, you can always modify your system to have your preferred default target unit if you choose to do so.
3. Exporting the DISPLAY environment variable
Let’s imagine you’re working on a separate client machine and you’re SSH’ed into your Linux machine. In this scenario, the DISPLAY environment variable will be our friend to accomplish our goal. All we will need to do is the following command: export DISPLAY=<IP address of your client machine>:0.0. An example is provided below:
The above export of the DISPLAY variable means that this will only last for the SSH session. This can be permanently configured in the .bashrc file, but that is not covered in this blog.
4. Running the desired tool
After we set the DISPLAY variable, we should be able to run any ArcGIS Enterprise tool. For example, let’s try the authorizeSoftware tool:
As seen, the UI for the tool now pops up! Similary, we should now be able to apply this same idea to other ArcGIS Enterprise tools.
5. Wrap-up
In this blog, we covered how to set up our system to view ArcGIS Enterprise tools in a UI. Please let me know what you would like to see more of in the comments. As always, thank you for reading this Monthly Linux Tip!
Excellent small series of blog posts about projections Heather!
Brief but really concise, clear and to the point. Should be of help to many.
Thank you very much!
This is excellent.
Thank you very much.
Just Perfect Heather
Hi,I am Mujuni Desdery ,Cartographer ,currently work with Geological Survey of Tanzania. I have challenge on using both Geographical Coordinate System & Projected Coordinate System Always I made Georeference Raster with GCS , I create a Layers with PCS ,(in File Geodatabase).Finally at Layout stage I should display both GCS & PCS There error on displaying both GCS & PCS on fixed final layout Map.Main displayed at GCS looks like miss or overlaping either Easting or Northing of GCS . but PCS looks perfect Any one who experience this fatal, please help me to overcome it. …May be I was… Read more »
Hi Mujuni,
This article about projection on the fly and transformations might help: https://www.esri.com/arcgis-blog/products/arcgis-pro/mapping/projection-on-the-fly-and-geographic-transformations/ It may be that a geographic transformation is not available or you need to use a different one.
I also recommend posting your question on GeoNet, where more people can see and respond: https://community.esri.com/groups/coordinate-reference-systems
Please include the coordinate system used by your map and each layer, and include a picture or two of the problem you are seeing.
Hi,
Great post for Coordinate System, just one comment for last section (What’s the difference between a spatial reference and a coordinate system?). Actually there are difference between them as follow:
– Spatial Reference for 2D data = Horizontal Projected Coordinate System +XY Resolution+ XY Tolerance
– Spatial Reference for 3D data = Horizontal Projected Coordinate System + XY Tolerance + Vertical Coordinate System + Z Resolution +Z Tolerance
based to this Documentation:
https://desktop.arcgis.com/en/arcmap/latest/manage-data/geodatabases/the-properties-of-a-spatial-reference.htm
Thanks,
Mohamed Magdy
Thanks for the informative article. Coordinate Systems and Projections are topics that we have to keep revisiting because they can be complicated and it is easy to forget some of the details. It is kind of like math in a way. You think you know it but when you dive in after a break you realize you don’t know it as well as you thought
Thank you for your hard working, Heather! It’s really great article 🙂
Hello everyone.
Thanks a lot for this beneficial article.
I just have a quick question. Should all the data and layers in a map have the same GCS and PCS? I have put together two layers in a map whit different GCS and PCS to see what happened and I am able to see both layers and apparently, it works well with the location.
Thanks a lot!
Sara
Hi Sara, The short answer is yes: once you’ve decided which data to use, it’s best to use the Project tool to make sure all data layers and the map use the same coordinate system. This answer is especially true if you’ll be doing any kind of spatial analysis. You can think of GIS analysis like a scientific experiment: you want to have full control over all of the variables, and the coordinate system is an important variable. Therefore, to have full confidence in your results, you should keep this variable consistent. But in my opinion, if you’re simply visualizing… Read more »
Thanks for your clear answer!