Home
Main website
Display Sidebar
Hide Ads
Recent Changes
View Source:
vacuumdb(1)
Edit
PageHistory
Diff
Info
LikePages
VACUUMDB !!!VACUUMDB NAME SYNOPSIS DESCRIPTION USAGE ---- !!NAME vacuumdb - garbage-collect and analyze a PostgreSQL database !!SYNOPSIS __vacuumdb__ [[ ''connection-options''... ] [[ [[ __-d__ ] ''dbname'' ] [[ __--full__ | __-f__ ] [[ __--verbose__ | __-v__ ] [[ __--analyze__ | __-z__ ] [[ __--table '__''table'' [[ __(__ ''column'' __[[,...] )__ ]__'__ ] __vacuumdb__ [[ ''connection-options''... ] [[ __--all__ | __-a__ ] [[ __--full__ | __-f__ ] [[ __--verbose__ | __-v__ ] [[ __--analyze__ | __-z__ ] __INPUTS__ __vacuumdb__ accepts the following command line arguments: __-d__ ''dbname'' __--dbname__ ''dbname'' Specifies the name of the database to be cleaned or analyzed. __-a__ __--all__ Vacuum all databases. __-f__ __--full__ Perform ``full'' vacuuming. __-v__ __--verbose__ Print detailed information during processing. __-z__ __--analyze__ Calculate statistics for use by the optimizer. __-t__ ''table'' __[[ (__''column'' __[[,...]) ]__ __--table__ ''table'' __[[ (__''column'' __[[,...]) ]__ Clean or analyze ''table'' only. Column names may be specified only in conjunction with the __--analyze__ option. __Tip:__ If you specify columns to vacuum, you probably have to escape the parentheses from the shell. __vacuumdb__ also accepts the following command line arguments for connection parameters: __-h__ ''host'' __--host__ ''host'' Specifies the host name of the machine on which the server is running. If host begins with a slash, it is used as the directory for the Unix domain socket. __-p__ ''port'' __--port__ ''port'' Specifies the Internet TCP/IP port or local Unix domain socket file extension on which the server is listening for connections. __-U__ ''username'' __--username__ ''username'' User name to connect as __-W__ __--password__ Force password prompt. __-e__ __--echo__ Echo the commands that __vacuumdb__ generates and sends to the server. __-q__ __--quiet__ Do not display a response. __OUTPUTS__ __VACUUM__ Everything went well. __vacuumdb: Vacuum failed.__ Something went wrong. __vacuumdb__ is only a wrapper script. See VACUUM [[__vacuum__(l)] and psql(1) for a detailed discussion of error messages and potential problems. !!DESCRIPTION __vacuumdb__ is a utility for cleaning a PostgreSQL database. __vacuumdb__ will also generate internal statistics used by the PostgreSQL query optimizer. __vacuumdb__ is a shell script wrapper around the backend command VACUUM [[__vacuum__(l)] via the PostgreSQL interactive terminal psql(1). There is no effective difference between vacuuming databases via this or other methods. __psql__ must be found by the script and a database server must be running at the targeted host. Also, any default settings and environment variables available to __psql__ and the __libpq__ front-end library do apply. !!USAGE To clean the database test: $ __vacuumdb test __ To clean and analyze for the optimizer a database named bigdb: $ __vacuumdb --analyze bigdb __ To clean a single table foo in a database named xyzzy, and analyze a single column bar of the table for the optimizer: $ __vacuumdb --analyze --verbose --table 'foo(bar)' xyzzy __ ----
One page links to
vacuumdb(1)
:
Man1v
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.