Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HPCasCode
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
hpc-team
HPCasCode
Commits
bfc7405e
Commit
bfc7405e
authored
6 years ago
by
Simon Michnowicz
Browse files
Options
Downloads
Patches
Plain Diff
modified for new architecture
Former-commit-id:
c1428d9d
parent
c6dab723
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
roles/slurm_sql_bk/templates/backup_mysql_for_slurm.sh.j2
+6
-6
6 additions, 6 deletions
roles/slurm_sql_bk/templates/backup_mysql_for_slurm.sh.j2
roles/slurm_sql_bk/templates/mysql.conf.j2
+2
-2
2 additions, 2 deletions
roles/slurm_sql_bk/templates/mysql.conf.j2
with
8 additions
and
8 deletions
roles/slurm_sql_bk/templates/backup_mysql_for_slurm.sh.j2
+
6
−
6
View file @
bfc7405e
#!/bin/sh
#!/bin/sh
#
#
# mysql dump for slurm.
# mysql dump for slurm.
# S.Michnowicz
# 20/Jan/2016
#
#
TIME
=
$(
date
'+%y-%m-%d'
)
TIME
=
$(
date
'+%y-%m-%d'
)
DIR
={{
SQL_BK_DIR
}}
BIN_DIR
={{
MGMT_BIN_DIR
}}
NAME
=
"
$DIR
/mysql_dump_20
${
TIME
}
.sql"
DATA_DIR
={{
SQL_BK_DATA_DIR
}}
NAME
=
"
$DATA_DIR
/mysql_dump_20
${
TIME
}
.sql"
sudo
mysqldump
--defaults-file
=
$DIR
/mysql.conf slurm_acct_db
>
$NAME
cd
$DATA_DIR
sudo
mysqldump
--defaults-file
=
$BIN_DIR
/mysql.conf
--host
={{
SQL_IP
}}
slurm_acct_db
>
$NAME
sudo chmod
go-r
$NAME
sudo chmod
go-r
$NAME
sudo gzip
-f
$NAME
sudo gzip
-f
$NAME
#scp file to dummy user @ Destination Node and Directory
#scp file to dummy user @ Destination Node and Directory
scp
${
NAME
}
.gz
{{
SQL_USER
}}
@
{{
SQL_BK_DEST_HOST
}}
:
{{
SQL_BK_DEST_DIR
}}
scp
-i
~/.ssh/slm_db_backup
${
NAME
}
.gz
{{
SQL_USER
}}
@
{{
SQL_BK_DEST_HOST
}}
:
{{
SQL_BK_DEST_DIR
}}
rm
-f
${
NAME
}
.gz
rm
-f
${
NAME
}
.gz
This diff is collapsed.
Click to expand it.
roles/slurm_sql_bk/templates/mysql.conf.j2
+
2
−
2
View file @
bfc7405e
[client]
[client]
password="{{ sql
root
Passwd }}"
password="{{ sqlPasswd }}"
user=
root
user=
"{{ sqlUsername }}"
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