Aufgrund meiner Spielereien habe ich meine "Haupt"-Datenbank (solaranzeige) gelöscht und wollte aus der Datensicherung vom heutigen Tag die Datenbank zurückspielen. Geht nicht.
Meine Sicherung, mit dem Zusatz "-portable" erstellt, liegt auf:
/media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/ 167 Dateien mit verschiedenen Namen
erstellt mit:
influxd backup -portable -database solaranzeige -host 127.0.0.1:8088 ${BACKUP_PFAD}/dateien/databases/solaranzeige/$(date +\%d-\%m-\%y)/
Meine versuchten Befehle waren:
Code: Alles auswählen
pi@solaranzeige:~ $ influxd restore -portable -db solaranzeige /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23
2023/07/20 19:19:54 error updating meta: DB metadata not changed. database may already exist
restore: DB metadata not changed. database may already exist
Code: Alles auswählen
pi@solaranzeige:~ $ influxd restore -portable /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/
2023/07/20 19:10:38 error updating meta: DB metadata not changed. database may already exist
restore: DB metadata not changed. database may already exist
Code: Alles auswählen
pi@solaranzeige:~ $ influxd restore -database solaranzeige -datadir /var/lib/influxdb/data/solaranzeige /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/
2023/07/20 18:52:37 Restoring offline from backup /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/solaranzeige.*
restore: no backup files for /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/solaranzeige.* in /media/pi/sicherung-sda3/dateien/databases/solaranzeige/20-07-23/
Code: Alles auswählen
Usage: influxd restore -portable [options] PATH
Note: Restore using the '-portable' option consumes files in an improved Enterprise-compatible
format that includes a file manifest.
Options:
-portable
Required to activate the portable restore mode. If not specified, the legacy restore mode is used.
-host <host:port>
InfluxDB OSS host to connect to where the data will be restored. Defaults to '127.0.0.1:8088'.
-db <name>
Name of database to be restored from the backup (InfluxDB OSS or InfluxDB Enterprise)
-newdb <name>
Name of the InfluxDB OSS database into which the archived data will be imported on the target system.
Optional. If not given, then the value of '-db <db_name>' is used. The new database name must be unique
to the target system.
-rp <name>
Name of retention policy from the backup that will be restored. Optional.
Requires that '-db <db_name>' is specified.
-newrp <name>
Name of the retention policy to be created on the target system. Optional. Requires that '-rp <rp_name>'
is set. If not given, the '-rp <rp_name>' value is used.
-shard <id>
Identifier of the shard to be restored. Optional. If specified, then '-db <db_name>' and '-rp <rp_name>' are
required.
PATH
Path to directory containing the backup files.
restore: flag provided but not defined: -data-dir
Bitte dringend um Hilfe,
Jan