The other day I was loading a shapefile of approximately 11 million
records into a PostGIS database (stay tuned for more on that later) and
I wanted to know when shp2pgsql was done. Instead of continually
checking the console, I decided to ‘watch’ the process using the *nix
command watch
. I discovered this handy tool a while ago, and have
found that for long running processes, I can use watch
to notify me
when the process has finished, using the following command:
watch -ben 1 "ps u -C shp2pgsql"