Skip to content

Commit 821379d

Browse files
committed
bug fix in backup creation of complete website
1 parent ed9a5e2 commit 821379d

1 file changed

Lines changed: 4 additions & 7 deletions

File tree

plogical/backupUtilities.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2044,14 +2044,11 @@ def submitBackupCreation(tempStoragePath, backupName, backupPath, backupDomain):
20442044
databases = backupMetaData.findall('Databases/database')
20452045

20462046
for database in databases:
2047-
20482047
dbName = database.find('dbName').text
2049-
2050-
if mysqlUtilities.mysqlUtilities.createDatabaseBackup(dbName, '/home/cyberpanel') == 0:
2051-
writeToFile = open(schedulerPath, 'w')
2052-
writeToFile.writelines('1358')
2053-
writeToFile.close()
2054-
return 0
2048+
res = mysqlUtilities.mysqlUtilities.createDatabaseBackup(dbName, '/home/cyberpanel')
2049+
if res == 0:
2050+
## This login can be further improved later.
2051+
logging.CyberCPLogFileWriter.writeToFile('Failed to create database backup for %s. This could be false positive, moving on.' % (dbName))
20552052

20562053
command = 'mv /home/cyberpanel/%s.sql %s/%s.sql' % (dbName, tempStoragePath, dbName)
20572054
ProcessUtilities.executioner(command, 'root')

0 commit comments

Comments
 (0)