Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion NOTICE
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Apache Cloudberry (Incubating)
Copyright 2024-2025 The Apache Software Foundation
Copyright 2024-2026 The Apache Software Foundation

This product includes software developed at
The Apache Software Foundation (http://www.apache.org/).
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ Follow the directions [here](https://golang.org/doc/) for installation, usage
and configuration instructions. Make sure to set the [Go PATH environment
variable](https://go.dev/doc/install) before starting the following steps.

```
export GOPATH=$HOME/go
export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin
```

## Download & Build

1. Downloading the latest version:
Expand Down
2 changes: 1 addition & 1 deletion gpbackup.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
func main() {
var rootCmd = &cobra.Command{
Use: "gpbackup",
Short: "gpbackup is the parallel backup utility for Greenplum",
Short: "gpbackup is the parallel backup utility for Cloudberry",
Args: cobra.NoArgs,
Version: GetVersion(),
Run: func(cmd *cobra.Command, args []string) {
Expand Down
2 changes: 1 addition & 1 deletion gprestore.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
func main() {
var rootCmd = &cobra.Command{
Use: "gprestore",
Short: "gprestore is the parallel restore utility for Greenplum",
Short: "gprestore is the parallel restore utility for Cloudberry",
Args: cobra.NoArgs,
Version: GetVersion(),
Run: func(cmd *cobra.Command, args []string) {
Expand Down
8 changes: 4 additions & 4 deletions integration/gpexpand_not_running_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ var _ = Describe("gpexpand_sensor", func() {
}
}()

defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Greenplum expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`)
defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Cloudberry expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`)
restore.DoSetup()
})
It("should prevent gprestore from starting when gpexpand is in phase 2", func() {
Expand All @@ -54,7 +54,7 @@ var _ = Describe("gpexpand_sensor", func() {
testhelper.AssertQueryRuns(postgresConn, "CREATE TABLE gpexpand.status (status text, updated timestamp)")
testhelper.AssertQueryRuns(postgresConn, "INSERT INTO gpexpand.status VALUES ('IN PROGRESS', now())")

defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Greenplum expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`)
defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Cloudberry expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`)
restore.DoSetup()
})
It("should prevent gpbackup from starting when gpexpand is in phase 1", func() {
Expand All @@ -76,7 +76,7 @@ var _ = Describe("gpexpand_sensor", func() {
}
}()

defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Greenplum expansion currently in process, please re-run gpbackup when the expansion has completed`)
defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Cloudberry expansion currently in process, please re-run gpbackup when the expansion has completed`)
backup.DoSetup()
})
It("should prevent gpbackup from starting when gpexpand is in phase 2", func() {
Expand All @@ -89,7 +89,7 @@ var _ = Describe("gpexpand_sensor", func() {
testhelper.AssertQueryRuns(postgresConn, "CREATE TABLE gpexpand.status (status text, updated timestamp)")
testhelper.AssertQueryRuns(postgresConn, "INSERT INTO gpexpand.status VALUES ('IN PROGRESS', now())")

defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Greenplum expansion currently in process, please re-run gpbackup when the expansion has completed`)
defer testhelper.ShouldPanicWithMessage(`[CRITICAL]:-Cloudberry expansion currently in process, please re-run gpbackup when the expansion has completed`)
backup.DoSetup()
})
})
4 changes: 2 additions & 2 deletions report/report.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ func (report *Report) WriteBackupReportFile(reportFilename string, timestamp str
reportInfo := make([]LineInfo, 0)
reportInfo = append(reportInfo,
LineInfo{Key: "timestamp key:", Value: timestamp},
LineInfo{Key: "gpdb version:", Value: report.DatabaseVersion},
LineInfo{Key: "database version:", Value: report.DatabaseVersion},
LineInfo{Key: "gpbackup version:", Value: fmt.Sprintf("%s\n", report.BackupVersion)},
LineInfo{Key: "database name:", Value: report.DatabaseName},
LineInfo{Key: "command line:", Value: gpbackupCommandLine},
Expand Down Expand Up @@ -189,7 +189,7 @@ func WriteRestoreReportFile(reportFilename string, backupTimestamp string, start
reportInfo := make([]LineInfo, 0)
reportInfo = append(reportInfo,
LineInfo{Key: "timestamp key:", Value: backupTimestamp},
LineInfo{Key: "gpdb version:", Value: connectionPool.Version.VersionString},
LineInfo{Key: "database version:", Value: connectionPool.Version.VersionString},
LineInfo{Key: "gprestore version:", Value: fmt.Sprintf("%s\n", restoreVersion)},
LineInfo{Key: "database name:", Value: connectionPool.DBName},
LineInfo{Key: "command line:", Value: fmt.Sprintf("%s\n", gprestoreCommandLine)},
Expand Down
12 changes: 6 additions & 6 deletions report/report_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ data file format: Single Data File Per Segment`,
Expect(buffer).To(Say(`Apache Cloudberry Backup Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gpbackup version: 0\.1\.0

database name: testdb
Expand Down Expand Up @@ -127,7 +127,7 @@ types 1000`))
Expect(buffer).To(Say(`Apache Cloudberry Backup Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gpbackup version: 0\.1\.0

database name: testdb
Expand Down Expand Up @@ -159,7 +159,7 @@ types 1000`))
Expect(buffer).To(Say(`Apache Cloudberry Backup Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gpbackup version: 0\.1\.0

database name: testdb
Expand Down Expand Up @@ -248,7 +248,7 @@ incremental backup set:
Expect(buffer).To(Say(`Apache Cloudberry Restore Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gprestore version: 0\.1\.0

database name: testdb
Expand All @@ -269,7 +269,7 @@ restore error: Cannot access /tmp/backups: Permission denied`))
Expect(buffer).To(Say(`Apache Cloudberry Restore Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gprestore version: 0\.1\.0

database name: testdb
Expand All @@ -289,7 +289,7 @@ restore status: Success`))
Expect(buffer).To(Say(`Apache Cloudberry Restore Report

timestamp key: 20170101010101
gpdb version: 5\.0\.0 build test
database version: 5\.0\.0 build test
gprestore version: 0\.1\.0

database name: testdb
Expand Down
4 changes: 2 additions & 2 deletions utils/gpexpand_sensor.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ import (
)

const (
BackupPreventedByGpexpandMessage GpexpandFailureMessage = `Greenplum expansion currently in process, please re-run gpbackup when the expansion has completed`
BackupPreventedByGpexpandMessage GpexpandFailureMessage = `Cloudberry expansion currently in process, please re-run gpbackup when the expansion has completed`

RestorePreventedByGpexpandMessage GpexpandFailureMessage = `Greenplum expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`
RestorePreventedByGpexpandMessage GpexpandFailureMessage = `Cloudberry expansion currently in process. Once expansion is complete, it will be possible to restart gprestore, but please note existing backup sets taken with a different cluster configuration may no longer be compatible with the newly expanded cluster configuration`

CoordinatorDataDirQuery = `select datadir from gp_segment_configuration where content=-1 and role='p'`
GpexpandTemporaryTableStatusQuery = `SELECT status FROM gpexpand.status ORDER BY updated DESC LIMIT 1`
Expand Down