Ejemplo n.º 1
0
    def _backup_mysql_db(self, db_conf, outfile):
        outfile = '%s.mysql.gz' % outfile
        _check_writable(outfile)
        ret = os.system('mysqldump %s | gzip -9 > %s' %
                (build_mysql_args(db_conf), outfile))

        return ret, outfile
Ejemplo n.º 2
0
 def _load_mysql_db(self, db_conf, infile):
     return os.system("zcat %s | mysqldump %s" % (infile, build_mysql_args(db_conf)))
Ejemplo n.º 3
0
    def _backup_mysql_db(self, db_conf, outfile, tmp_outfile):
        outfile = '%s.mysql.gz' % outfile
        ret = os.system('mysqldump %s > %s' %
                (build_mysql_args(db_conf), tmp_outfile.name))

        return ret, outfile
Ejemplo n.º 4
0
    def _backup_mysql_db(self, db_conf, outfile, tmp_outfile):
        outfile = '%s.mysql.gz' % outfile
        ret = os.system('mysqldump %s > %s' %
                        (build_mysql_args(db_conf), tmp_outfile.name))

        return ret, outfile