https://bugs.contribs.org/show_bug.cgi?id=10655
Bug ID: 10655
Summary: runmysql hard coded directory ignore backupdir key
Classification: Contribs
Product: SME Contribs
Version: 9.2
Hardware: ---
OS: ---
Status: CONFIRMED
Severity: normal
Priority: P3
Component: smeserver-automysqlbackup
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
Target Milestone: ---
Whilst looking at https://bugs.contribs.org/show_bug.cgi?id=10654 I also
noticed that runmysql has hardcoded chown and chmod which will ignore a change
in the backupdir key
Backupdir=/root/backup/db
chown root:root /root/backup/db* -R
find /root/backup/db* -type f -exec chmod 400 {} \;
find /root/backup/db* -type d -exec chmod 700 {} \;
I have done a little patch like this to set a dir in case the config is empty,
but to use the config dir if set:
-chown root:root /root/backup/db* -R
-find /root/backup/db* -type f -exec chmod 400 {} \;
-find /root/backup/db* -type d -exec chmod 700 {} \;
+DB=$(/sbin/e-smith/db configuration getprop automysqlbackup Backupdir)
+
+if [ -z "$DB" ]; then
+ DB="/root/backup/db";
+fi
+
+chown root:root $DB* -R
+find $DB* -type f -exec chmod 400 {} \;
+find $DB* -type d -exec chmod 700 {} \;
I'll push it to testing once Terry has finished the last one.
--
You are receiving this mail because:
You are the QA Contact for the bug._______________________________________________
Mail for each SME Contribs bug report
To unsubscribe, e-mail [email protected]
Searchable archive at https://lists.contribs.org/mailman/public/contribteam/