示例#1
0
文件: myman.py 项目: xoyabc/python
def setVariable(instance_name, variable, value):
    cnf = getCNF(instance_name)
    if path.exists(cnf):
        mc = MySQLDConfig(cnf)
        cur = connMySQLd(mc)
        cur.execute("set global %s = %s" % (variable, value))
        mc.set_var(variable, value)
        mc.save()
示例#2
0
文件: myman.py 项目: 467754239/python
def setVariable(instance_name, variable, value):
    cnf = getCNF(instance_name)
    if path.exists(cnf):
         mc = MySQLDConfig(cnf)
         cur = connMySQLd(mc)
         cur.execute("set global %s = %s" % (variable, value))
         mc.set_var(variable, value)
         mc.save()
示例#3
0
def setVariable(name, variable, value):
    cnf = getCNF(name)
    if os.path.exists(cnf):
        mc = MySQLDConfig(cnf)
        mc.set_var(variable, value)
        mc.save()