git://git.onelab.eu
/
plcapi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
2fb2ab9
)
/etc/plc.d/db dump-and-clean
author
Thierry Parmentelat
<thierry.parmentelat@inria.fr>
Sat, 26 Nov 2022 14:03:38 +0000
(15:03 +0100)
committer
Thierry Parmentelat
<thierry.parmentelat@inria.fr>
Sat, 26 Nov 2022 14:03:38 +0000
(15:03 +0100)
plc.d/db
patch
|
blob
|
history
diff --git
a/plc.d/db
b/plc.d/db
index
ccf9bf6
..
4d0ef8a
100755
(executable)
--- a/
plc.d/db
+++ b/
plc.d/db
@@
-188,6
+188,12
@@
migrate)
result "$MESSAGE"
;;
result "$MESSAGE"
;;
+stop)
+ MESSAGE="Ignoring request to stop myplc databases"
+ dialog "$MESSAGE"
+ result ""
+ ;;
+
dump)
MESSAGE=$"Dumping the databases in /var/lib/pgsql/backups"
dialog "$MESSAGE"
dump)
MESSAGE=$"Dumping the databases in /var/lib/pgsql/backups"
dialog "$MESSAGE"
@@
-197,6
+203,23
@@
dump)
result "$MESSAGE"
;;
result "$MESSAGE"
;;
+clean-dump)
+ MESSAGE=$"Cleaning old database dumps"
+ dialog "$MESSAGE"
+ # clean_dump has a builtin default, so no problem
+ clean_dump $2
+ result "$MESSAGE"
+ ;;
+
+dump-and-clean)
+ MESSAGE=$"dumping databases and cleaning old dumps"
+ dialog "$MESSAGE"
+ dump_planetlab_db
+ dump_drupal_db
+ clean_dump $2
+ result "$MESSAGE"
+ ;;
+
checkpoint)
MESSAGE=$"Checkpointing the databases"
checkpoint_planetlab_db $2
checkpoint)
MESSAGE=$"Checkpointing the databases"
checkpoint_planetlab_db $2
@@
-209,22
+232,8
@@
restore)
restore_drupal_db $3
;;
restore_drupal_db $3
;;
-clean-dump)
- MESSAGE=$"Cleaning old database dumps"
- dialog "$MESSAGE"
- # clean_dump has a builtin default, so no problem
- clean_dump $2
- result "$MESSAGE"
- ;;
-
-stop)
- MESSAGE="Ignoring request to stop myplc databases"
- dialog "$MESSAGE"
- result ""
- ;;
-
*)
*)
- echo "Usage: $0 [start|migrate|
dump|checkpoint|restore|clean-dump|stop
]"
+ echo "Usage: $0 [start|migrate|
stop|dump|clean-dump|dump-and-clean|checkpoint|restore
]"
exit 1
;;
esac
exit 1
;;
esac