Revision cb91d46e lib/backend.py

b/lib/backend.py
43 43
from ganeti import ssconf
44 44

  
45 45

  
46
def ListConfigFiles():
47
  """Return a list of the config files present on the local node.
48
  """
49

  
50
  configfiles = []
51

  
52
  for testfile in constants.MASTER_CONFIGFILES:
53
    if os.path.exists(testfile):
54
      configfiles.append(testfile)
55

  
56
  for testfile in constants.NODE_CONFIGFILES:
57
    if os.path.exists(testfile):
58
      configfiles.append(testfile)
59

  
60
  return configfiles
61

  
62

  
63 46
def StartMaster():
64 47
  """Activate local node as master node.
65 48

  
......
75 58
                 " error: '%s'" % (result.cmd, result.output))
76 59
    return False
77 60

  
78
  utils.RemoveFile(constants.MASTER_CRON_LINK)
79
  os.symlink(constants.MASTER_CRON_FILE, constants.MASTER_CRON_LINK)
80 61
  return True
81 62

  
82 63

  
......
95 76
                 " error: '%s'" % (result.cmd, result.output))
96 77
    return False
97 78

  
98
  utils.RemoveFile(constants.MASTER_CRON_LINK)
99

  
100 79
  return True
101 80

  
102 81

  

Also available in: Unified diff