I am not familar with the OpenGeo suite so I might not have the detail specific to you down but unless OpenGeo preloaded a template or sample database, you need to create a spatially enabled database yourself.
When I was learning how to effectively use PostGIS, this website had the easiest step-by-step instructions of how to setup yourself a spatially enabled template.
Linfiniti - Installing PostGIS2
If you have that all setup and just need command line access to PostgreSQL just type:
psql -d databasename
This will connect you to the database you want. Common options include:
-h for remote hosts, don't use if your server is on your local machine
-p to connect via non-standard port (which is 5432, fyi)
-U to login as a specific user other then your current user
-l list all available databses and templates and then quits
I hope this helps.
psqlbut it keeps giving me this error,psql: FATAL: Ident authentication failed for user "myname"– Sam007 Nov 21 '12 at 22:10psql -d databasename -U username -h hostname -p 5432– Sam007 Nov 21 '12 at 22:33postgres:sudo su postgresthen just typepsqlonce there typeadd user yourname with password 'password';and also giver your self admin rights over your database withgrant all privileges on database dbname to yourname;– RomaH Nov 21 '12 at 22:35add user yourname with password 'password';but got this errorERROR: syntax error at or near "add" LINE 1: add user username with password 'password';– Sam007 Nov 21 '12 at 22:40sudo su postgresbut now I am trying to get back to the original user and enteringsudo su mynamebut not sure what the password is?? – Sam007 Nov 21 '12 at 22:48su usernameyou are actually three bash shells deep. Which isn't bad but could be confusing later on. So your real idenitity is now You > Postgres > You in your current shell. The correct way to get out of asuis to type the facepalmingexit. :) Oops caught my error, Thanks. – RomaH Nov 21 '12 at 23:21