How do I perform PostgreSQL maintenance like vacuuming and reindexing?
- Open PgAdmin3.exe from either:
"C:\Program Files\AccessData\PostgreSQL\bin" (or)
- Go to File > Add Server
Name = FTK (or any unique name for the new connection)
Host = localhost
Port = the port PostgreSQL is running on
Password = the password chosen while first installing PostgreSQL
- Double-click the new "Server" entry created on the left
- Expand "Databases"
- For every "adg" and "case" database:
- Right-click on the database
- Select 'Maintenance'
- From here you can run the following
~Vacuum (Under Vacuum options use FULL)
After each run of the above options move to the next till all three are run on each database.
Keep in mind that any of these maintenance actions can take a while to complete and should not be interrupted, especially if you are trying to repair database corruption.
Performing maintenance on the database can sometimes help prevent or repair database corruption. Often times corruption can be identified by seeing error messages like the one below in either the FTK_log.txt file (located "C:\ProgramData\AccessData\Products\Forensic Toolkit\<version>") or the PostgreSQL logs (located "[drive]:\pgData93\pg_log")
could not read block 0 in file "pg_tblspc/642005/PG_9.3_201306121/16385/645221": read only 0 of 8192 bytes.