Skip to content

Commit eada4d5

Browse files
ltangvaldprashanttekriwal
authored andcommitted
Bug#24761774 PACKAGE UPGRADE FROM 5.6.33 TO 34 FAILING DUE TO SECURE-FILE-PRIV PROBLEMS
Added creation of missing directory to server postinst (cherry picked from commit e23c9bd1a18e4914b0371be049a2af8ee01e6e02)
1 parent f2cdf7b commit eada4d5

File tree

4 files changed

+40
-4
lines changed

4 files changed

+40
-4
lines changed

packaging/deb-jessie/mysql-community-server.postinst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
3+
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
44
#
55
# This program is free software; you can redistribute it and/or modify
66
# it under the terms of the GNU General Public License as published by
@@ -27,6 +27,15 @@ take_upstart_job_backup () {
2727
case "$1" in
2828
configure)
2929

30+
# MySQL 5.6.34 needs this
31+
MYSQLFILES=/var/lib/mysql-files
32+
if [ ! -d ${MYSQLFILES} -a ! -L ${MYSQLFILES} ];
33+
then
34+
mkdir ${MYSQLFILES}
35+
chown mysql:mysql ${MYSQLFILES}
36+
chmod 770 ${MYSQLFILES}
37+
fi
38+
3039
if [ -z "$2" ];
3140
then
3241
set -e

packaging/deb-precise/mysql-community-server.postinst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
3+
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
44
#
55
# This program is free software; you can redistribute it and/or modify
66
# it under the terms of the GNU General Public License as published by
@@ -27,6 +27,15 @@ take_upstart_job_backup () {
2727
case "$1" in
2828
configure)
2929

30+
# MySQL 5.6.34 needs this
31+
MYSQLFILES=/var/lib/mysql-files
32+
if [ ! -d ${MYSQLFILES} -a ! -L ${MYSQLFILES} ];
33+
then
34+
mkdir ${MYSQLFILES}
35+
chown mysql:mysql ${MYSQLFILES}
36+
chmod 770 ${MYSQLFILES}
37+
fi
38+
3039
if [ -z "$2" ];
3140
then
3241
set -e

packaging/deb-trusty/mysql-community-server.postinst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
3+
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
44
#
55
# This program is free software; you can redistribute it and/or modify
66
# it under the terms of the GNU General Public License as published by
@@ -27,6 +27,15 @@ take_upstart_job_backup () {
2727
case "$1" in
2828
configure)
2929

30+
# MySQL 5.6.34 needs this
31+
MYSQLFILES=/var/lib/mysql-files
32+
if [ ! -d ${MYSQLFILES} -a ! -L ${MYSQLFILES} ];
33+
then
34+
mkdir ${MYSQLFILES}
35+
chown mysql:mysql ${MYSQLFILES}
36+
chmod 770 ${MYSQLFILES}
37+
fi
38+
3039
if [ -z "$2" ];
3140
then
3241
set -e

packaging/deb-wheezy/mysql-community-server.postinst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
3+
# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
44
#
55
# This program is free software; you can redistribute it and/or modify
66
# it under the terms of the GNU General Public License as published by
@@ -27,6 +27,15 @@ take_upstart_job_backup () {
2727
case "$1" in
2828
configure)
2929

30+
# MySQL 5.6.34 needs this
31+
MYSQLFILES=/var/lib/mysql-files
32+
if [ ! -d ${MYSQLFILES} -a ! -L ${MYSQLFILES} ];
33+
then
34+
mkdir ${MYSQLFILES}
35+
chown mysql:mysql ${MYSQLFILES}
36+
chmod 770 ${MYSQLFILES}
37+
fi
38+
3039
if [ -z "$2" ];
3140
then
3241
set -e

0 commit comments

Comments
 (0)