Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
iml-backup
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
iml-backup
Commits
fe6034d0
Commit
fe6034d0
authored
3 years ago
by
Hahn Axel (hahn)
Browse files
Options
Downloads
Patches
Plain Diff
remove ./ in output of localdump.sh restore; add db restore hint
parent
0c57c6c1
No related branches found
No related tags found
1 merge request
!13
remove ./ in output of localdump.sh restore; add db restore hint
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
localdump.sh
+13
-3
13 additions, 3 deletions
localdump.sh
with
13 additions
and
3 deletions
localdump.sh
+
13
−
3
View file @
fe6034d0
...
...
@@ -12,6 +12,7 @@
# 2017-03-27 ..... added first param for mode backup|restore
# 2018-02-09 ..... fix: restore-selection of target uses default on return only
# 2021-05-18 ..... move supported backup types to plugins/localdump/[service].sh
# 2021-07-13 ..... remove leading ./ in localdump.sh restore
# ======================================================================
...
...
@@ -169,15 +170,24 @@
if
[
-d
"
${
BACKUP_TARGETDIR
}
"
]
;
then
cd
"
${
BACKUP_TARGETDIR
}
"
if
[
-z
$1
]
;
then
find
-type
f |
sed
"s#__[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]-[0-9][0-9].*##g"
|
grep
-v
".meta"
|
sort
-ud
find
-type
f |
sed
"s#__[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]-[0-9][0-9].*##g"
|
grep
-v
".meta"
|
sort
-ud
|
sed
"s#^
\.
/##g"
else
ls
-ltr
"
$*
__"
*
ls
-ltr
"
$*
__"
*
|
sed
"s#^
\.
/##g"
fi
cd
-
>
/dev/null
else
color error
echo
ERROR: here are no backups
for
this db
type
echo
ERROR:
${
BACKUP_TARGETDIR
}
does not exist -
here are no backups
to restore.
color reset
echo
echo
You can try to restore dumps:
echo
"1) Restore dump files from a backup set"
echo
"
`
dirname
$0
`
/restore.sh
$BACKUP_BASEDIR
"
echo
"2) Move restored dumps into
$BACKUP_TARGETDIR
"
echo
"3) Start database restore again"
echo
"
`
dirname
$0
`
/localdump.sh restore"
echo
exit
1
fi
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment