This is an automated email from the ASF dual-hosted git repository.
djwang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cloudberry.git
The following commit(s) were added to refs/heads/main by this push:
new 897c057bea7 Improve error message when COORDINATOR_DATA_DIRECTORY is
unset
897c057bea7 is described below
commit 897c057bea7d584b4daae6bf45ee49db3e990dde
Author: water32 <[email protected]>
AuthorDate: Tue Dec 23 13:52:04 2025 +0800
Improve error message when COORDINATOR_DATA_DIRECTORY is unset
This commit updates gpstop and gpstart to use shared logic when
determining the coordinator data directory.
By relying on the common helper, users receive clearer and more
actionable error messages when COORDINATOR_DATA_DIRECTORY is unset
or invalid, making startup and shutdown failures easier to diagnose.
---
gpMgmt/bin/gpstart | 4 +---
gpMgmt/bin/gpstop | 4 +---
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/gpMgmt/bin/gpstart b/gpMgmt/bin/gpstart
index 0165c0cc371..bc1f60b6c3d 100755
--- a/gpMgmt/bin/gpstart
+++ b/gpMgmt/bin/gpstart
@@ -902,9 +902,7 @@ class GpStart:
if is_external_fts:
if options.fts_hosts is None:
- coordinator_data_directory =
os.getenv('COORDINATOR_DATA_DIRECTORY')
- if coordinator_data_directory is None:
- coordinator_data_directory =
options.coordinatorDataDirectory
+ coordinator_data_directory = gp.get_coordinatordatadir()
options.fts_hosts = coordinator_data_directory + '/config' +
'/fts_host'
return GpStart(options.specialMode, options.restricted,
diff --git a/gpMgmt/bin/gpstop b/gpMgmt/bin/gpstop
index e8e8e3855a9..ab7655597c9 100755
--- a/gpMgmt/bin/gpstop
+++ b/gpMgmt/bin/gpstop
@@ -959,9 +959,7 @@ class GpStop:
if is_external_fts:
if options.fts_hosts is None:
- coordinator_data_directory =
os.getenv('COORDINATOR_DATA_DIRECTORY')
- if coordinator_data_directory is None:
- coordinator_data_directory =
options.coordinatorDataDirectory
+ coordinator_data_directory = gp.get_coordinatordatadir()
options.fts_hosts = coordinator_data_directory + '/config' +
'/fts_host'
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]