Restoring pg_dump hangs
This:

psql -U postgres -d utrechtTest &gt; backupTest2.sql


runs psql and writes its stdout to backupTest2.sql, which will be overwritten.

You meant:

psql -U postgres -d utrechtTest &lt; backupTest2.sql


which is better written as:

psql -U postgres -d utrechtTest -f backupTest2.sql


because if you use -f then psql can show line numbers.