I would like to update PostgreSQL and PostGIS on Opengeo CE to a newer version, maybe the other apps too (geoserver, openlayers, etc). Can it be done? Can someone point me the right direction?
If you go to your Documentation, section 2.7 is about upgrading the postgis database. Hard or soft upgrade options are available.
I:\Program Files (x86)\OpenGeo\OpenGeo Suite\webapps\docs\postgis\index.html
However note that there is no mention of 9.0 in the opengeo suite.
The really short answer:
Use the upgrade, but I'm not sure if this upgrades PostgreSQL/PostGIS to 9.x and 1.5 respectively.
I think the simplest path would be to upgrade using the latest installer, and if you want the latest version of Postgres/PostGIS you can read the 'Short answer' and 'Long Answer' sections below.
The OpenGeo Suite uses a custom build (made by OpenGeo) of PostgreSQL and PostGIS. One way to update to newer versions is to back up your database(s) with the pg_dump command.
You can then install a newer version such as PostgreSQL 9.0 and PostGIS 1.5 and import the database backup into the new database.
I do not recommend this since the new apps may have different directory path dependencies It would be easier to install the new version then upgrade Postgres/PostGIS.
It is probably a good idea to uninstall Postgres 8.4 or at the very least turn it off via the Dashboard or use pg_ctl to shut it down. To remove it from OSX or Linux you can
Depending on you operating system, there are a number of options for installing a new version. You can install Postgres/PostGIS from EnterpriseDB for most operating systems using their Stackbuilder, use apt-get or yum for Linux, and the Kyng Chaos site offers an OSX port as well.
If you upgrade to PostgreSQL 9.x, PGAdmin III should also be updated as well.
In some instances (EnterpriseDB, OSX Kyng Chaos) a postgis template is not automatically created so you will need to create one.
If you use the Dashboard, you will need to edit the paths to postgis on the config.ini file. In OSX and Linux, this is found in your home directory (or the home directory of the account used to install the OpenGeo Suite) under the .opengeo directory. In Windows it is found in C:\Documents and Settings\.opengeo\