For the record, there is a wiki page that contains info on the dbsetup
stuff... see:
If you have the source code, you can run dbsetup to reset your
database.
git checkout the source, make sure your maven settings.xml is setup
properly (see etc/m2/settinsg.xml in the source for an example) then:
cd modules/core/dbutils
mvn -Ddbsetup -Dmaven.test.skip install
This will drop all tables, then recreate them from scratch - you'll lose
all inventory and data when you do this - you start as if you just
installed the RHQ Server anew. Make sure you stop the RHQ Server before
doing this, obviously. After dbsetup finishes (takes a few seconds),
restart the RHQ Server.
If you don't want to bother going thru this setup of the build from
source, just do an initial install of your RHQ Server (i.e. unzip the
distro, run it, go through the UI installer to install the server), then
backup the DB. When you want to restart, just stop the RHQ Server,
revert your DB backup, then restart the RHQ Server. I do this alot on
Postgres - its really easy to backup and restore on Postgres using their
admin tool.
On 05/05/2011 11:59 AM, John Hollland wrote:
> We are going to be doing some testing of time sensitive data using
> RHQ. We want to run successive tests with a internal NTP server
> making the servers think they are always in the same time period. That
> is, we will reset the NTP clock back before each test. This is because
> the data being
> tested has business logic that relates to the current time.
>
> We want to purge the RHQ server of data from each previous test so the
> identically-timestamped data don't collide. Is this viable? Would it be
> a matter
> of truncating certain tables? Or would it be better to snapshot the
> whole machine?
_______________________________________________
rhq-users mailing list
rhq-users(a)lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/rhq-users