Tag Archives: Linux

Vagrant, CentOS 7 and VirtualBox

Using Vagrant and VirtualBox, a full CentOS 7 development environment can be generated.

Vagrant is an open-source tool that allows users to create a repeatable, portable, description of an environment in a single file. The environment can then be generated using a virtualization tool like VirtualBox. This case uses a Ubuntu 14.04 LTS host, though any modern Linux distribution should work.

This specific instance uses CentOS, an open source packaging of Red Hat Enterprise Linux, performs security/user/update tasks; and installs the development environment, GUI and Guest Additions.

All files can be found on GitHub.

Using grep to Find Files Containing Text

This command is used to find files in a directory structure containing a target search string. The command line utility ‘grep’ can be found on most modern Unix based systems.

$ grep --exclude=*\.{run,zip,tgz} -nr ./ -e "Hello World"
  • –exclude: multiple file types to ignore.
  • -nr: include line numbers in output display, recurse.
  • ./: search current directory.
  • -e: regular expression to search for follows.
  • “Hello World”: target search string.

Nothing ground-breaking here, this is more for my own documentation; I end up using this just not often enough to memorize it, but often enough I have to Google around a few minutes each time.

LaTeX Master’s Thesis for UCSC BSOE

A barebones Master’s thesis in LaTeX based on the documentation from the UCSC Graduate Handbook as of May 2011.

This project includes fully documented LaTeX code and cursory bibliography/figures/tables to show usage. The generated document has all the proper pages, page numbering, borders, formatting, etc.

‘BSOE’ is listed anywhere and everywhere, but keep in mind that this was put together with information from the Graduate Division. This LaTeX template can be used by ANY graduate student in ANY program at UCSC.

Continue reading

Blue Marble Mosaic

Recently, I decided to push www.olympianengine.com to Google App Engine. Google App Engine is a platform for building and hosting web applications on Google Web Servers (wikipedia).

I hit an immediate show-stopper: the maximum size for any single file is 1048576 bytes. I spent a night chopping up the bluemarble.tif from the GeoTIFF tutorial, such that I can load it in chunks, then realized I have large KML files on another website that I have no intention of chopping up.

Continue reading

GeoTIFF Creation

A common method for creating raster data that can be ingested into a GIS system, is to encode the data into a GeoTIFF. A GeoTIFF is a TIFF image file, with geographic tags that allow the image to have a geographic presence.

In this tutorial we will cover:
1. Creating a TIFF from a bitmap using libtiff.
2. Creating metadata and a world file for the GeoTIFF using libgeotiff.
3. Encoding the TIFF and metadata to make the GeoTIFF using libgeotiff.
4. Checking the correctness of the GeoTIFF.

Continue reading