1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-08-27 16:01:57 +03:00

MCOL-527 - add code for non-root

This commit is contained in:
david hill
2017-01-20 23:15:00 -06:00
parent 52c9fcd5b5
commit a6193ec7cd

View File

@@ -5501,7 +5501,12 @@ bool ProcessMonitor::amazonVolumeCheck(int dbrootID)
string status = oam.getEC2VolumeStatus(volumeName);
if ( status == "attached" ) {
string cmd = "mount " + deviceName + " " + startup::StartUp::installDir() + "/mysql/db -t ext2 -o defaults > /dev/null";
string cmd;
if ( rootUser)
cmd = "mount " + deviceName + " " + startup::StartUp::installDir() + "/mysql/db -t ext2 -o defaults > /tmp/um_mount.log";
else
cmd = "sudo mount " + deviceName + " " + startup::StartUp::installDir() + "/mysql/db -t ext2 -o defaults > /tmp/um_mount.log";
system(cmd.c_str());
log.writeLog(__LINE__, "mount cmd: " + cmd, LOG_TYPE_DEBUG);