gs_uninstall
Background
openGauss provides the gs_uninstall tool to uninstall a cluster.
Syntax
Uninstalling openGauss
gs_uninstall [--delete-data] [-L] [-l LOGFILE]
Display help information.
gs_uninstall -? | --help
Display the version number.
gs_uninstall -V | --version
Parameter Description
--delete-data
Deletes the data file.
-L
Uninstalls the local host only. If a host in openGauss is uninstalled, openGauss cannot be performed full uninstallation.
-l
Specifies a log file name and its absolute path that can be accessed. A timestamp will be added automatically to the log file name.
When -l is not specified and gaussdbLogPath is not set in the XML file, the default value of the -l parameter is $GAUSSLOG/om/gs_uninstall-YYYY-MM-DD_hhmmss.log.
When -l is not specified but gaussdbLogPath is set in the XML file, the default value of the -l parameter is gaussdbLogPath/Username/om/gs_uninstall-YYYY-MM-DD_hhmmss.log.
NOTE: When executing gs_uninstall, the system will automatically delete the directories related to openGauss. You are advised to set the log file path to a path outside the openGauss database.
-?, --help
Displays help information.
-V, --version
Displays version information.
Example
Execute the gs_uninstall script as a database user to uninstall openGauss.
gs_uninstall --delete-data
Checking uninstallation.
Successfully checked uninstallation.
Stopping the cluster.
Successfully stopped the cluster.
Successfully deleted instances.
Uninstalling application.
Successfully uninstalled application.
Uninstallation succeeded.