[Users] BSTRAP component='CreateConf' status='FAIL' message='Basic configuration failed to import default values'

Dan Kenigsberg danken at redhat.com
Thu Jun 28 13:55:50 UTC 2012


On Thu, Jun 28, 2012 at 12:32:27PM +0200, Karli Sjöberg wrote:
> Hi,
> 
> I am running Fedora 17 and added the ovirt beta repository to have access to webadmin addition, since F17 only comes with CLI by default.
> 

<snip>

> 
> 
> The action in question "CreateConf" looks like:
> 
> /usr/share/vdsm-bootstrap/vds_bootstrap.py
> 
>     def _makeConfig(self):
>         import datetime
>         from config import config
> 
>         if not os.path.exists(VDSM_CONF):
>             logging.debug("makeConfig: generating conf.")
>             lines = []
>             lines.append ("# Auto-generated by vds_bootstrap at:" + str(datetime.datetime.now()) + "\n")
>             lines.append ("\n")
> 
>             lines.append ("[vars]\n") #Adding ts for the coming scirpts.
>             lines.append ("trust_store_path = " + config.get('vars', 'trust_store_path') + "\n")
>             lines.append ("ssl = " + config.get('vars', 'ssl') + "\n")
>             lines.append ("\n")
> 
>             lines.append ("[addresses]\n") #Adding mgt port for the coming scirpts.
>             lines.append ("management_port = " + config.get('addresses', 'management_port') + "\n")
> 
>             logging.debug("makeConfig: writing the following to " + VDSM_CONF)
>             logging.debug(lines)
>             fd, tmpName = tempfile.mkstemp()
>             f = os.fdopen(fd, 'w')
>             f.writelines(lines)
>             f.close()
>             os.chmod(tmpName, 0644)
>             shutil.move(tmpName, VDSM_CONF)
>         else:
>             self.message = 'Basic configuration found, skipping this step'
>             logging.debug(self.message)
> 
>     def createConf(self):
>         """
>             Generate initial configuration file for VDSM. Must run after package installation!
>         """
>         self.message = 'Basic configuration set'
>         self.rc = True
>         self.status = 'OK'
> 
>         try:
>             self._makeConfig()
>         except Exception, e:
>             logging.error('', exc_info=True)

^^^^ the interesting stuff is written to a log file, sitting in your
/tmp or a directory below it. Which module fails to be imported?

Which version of vdsm-bootstrap do you have installed? if it is not a
4.10.something, I suggest you upgrade.



>             self.message = 'Basic configuration failed'
>             if isinstance(e, ImportError):
>                 self.message = self.message + ' to import default values'
>             self.rc = False
>             self.status = 'FAIL'
> 
>         self._xmlOutput('CreateConf', self.status, None, None, self.message)
>         return self.rc
> 
> 
> What now? Can anyone tell me why it fails? Besides the obvious "it´s beta" of course:)



More information about the Users mailing list