SlapOS Home SlapOS

    Re: Looking for a free partition

    • Last Update:2016-03-15
    • Version:001
    • Language:en

    Hi Alain,

    Thanks a lot for your response.

    I am trying the non-webrunner method first from http://community.slapos.org/wiki/developer-Allocate.SlapOS.Master.cluster.Instance. But there seems to be something wrong.

    This was my supply command-

     

    software_url = 'https://lab.nexedi.com/nexedi/slapos/raw/master/software/slapos-master/software.cfg'
    supply(
        software_url,
        'COMP-2547'
    )
    

    This was my request command -

    import json
    software_url = 'https://lab.nexedi.com/nexedi/slapos/raw/master/software/slapos-master/software.cfg'
    # Choose a SlapOS Node
    # If you are deploying SlapOS Master with Webrunner, then computer_id is 'slaprunner'
    computer_id = 'COMP-2547'
    
    parameter_dict = {
      "timezone": "UTC",
      "site-id": "erp5",
      "bt5": "erp5_full_text_myisam_catalog slapos_configurator",
      "zope-partition-dict": {
        "activities-node": {
          "family": "activities",
          "thread-amount": 3,
          "instance-count": 1,
          "timerserver-interval": 1,
          "computer-guid": computer_id,
        },
    
        "distribution-node": {
          "family": "distribution",
          "thread-amount": 1,
          "instance-count": 1,
          "computer-guid": computer_id,
          "port-base": 2210,
          "timerserver-interval": 1,
        },
    
        "admin-node": {
          "family": "admin",
          "thread-amount": 1,
          "instance-count": 1,
          "port-base": 2220,
          "computer-guid": computer_id
        },
        
        "web-node": {
          "family": "web",
          "thread-amount": 2,
          "instance-count": 1,
          "computer-guid": computer_id,
          "port-base": 2230,
        },
    
        "service-slapos": {
          "family": "service",
          "thread-amount": 2,
          "instance-count": 1,
          "computer-guid": computer_id,
          "port-base": 2240,
          "ssl-authentication": True,
          "backend-path": "/%(site-id)s/portal_slap",
        },
      },
    
      "mariadb-computer-guid": computer_id,
      "mariadb": {
        "test-database-amount": 0
      },
    
      "zodb-software-type": "zeo",
      "zodb-computer-guid": computer_id
    }
    
    # If your are deploying SlapOS Master with Webrunner, don't set "certificate-authority-path" parameter
    ca_path = '/etc/slapos-ssl'
    parameter_dict["certificate-authority-path"] =  ca_path
    
    # Choose a title
    title = "SlapOS Master on COMP-2547"
    
    request(software_url,
      title,
      filter_kw={'computer_guid': computer_id},
      software_type='create-erp5-site',
      partition_parameter_kw={
       '_': json.dumps(parameter_dict, sort_keys=True, indent=2),
      }
    )
    

    But I see this in Home > My Space > My Services -> clicking on the service - #error while instanciating

    Error while instansiating

     

     

    And as you guided I have checked the log at /opt/slapos/log/slapos-node-instance.log which has this error which I have highlighted in red -

    [2016-03-15 18:12:03,748] DEBUG    Loading config: /etc/opt/slapos/slapos.cfg
    [2016-03-15 18:12:03,766] INFO     Sleeping for 11 seconds. To disable this feature, check --now parameter in slapgrid help.
    [2016-03-15 18:12:16,325] INFO     Processing computer partitions...
    [2016-03-15 18:12:16,335] DEBUG    Supervisord already running.
    [2016-03-15 18:12:18,270] DEBUG    Check if slappart19 requires processing...
    [2016-03-15 18:12:18,271] DEBUG    Partition already up-to-date, skipping.
    [2016-03-15 18:12:18,272] DEBUG    Check if slappart18 requires processing...
    [2016-03-15 18:12:18,286] INFO     Processing Computer Partition slappart18.
    [2016-03-15 18:12:18,287] INFO       Software URL: https://lab.nexedi.com/nexedi/slapos/raw/master/software/slapos-master/software.cfg
    [2016-03-15 18:12:18,288] INFO       Software path: /opt/slapgrid/bcb8fbfbae583c14297f14ec8ebc3724
    [2016-03-15 18:12:18,288] INFO       Instance path: /srv/slapgrid/slappart18
    [2016-03-15 18:12:20,702] INFO       Instance status: started
    [2016-03-15 18:12:20,704] INFO     Installing Computer Partition slappart18...
    [2016-03-15 18:12:20,712] DEBUG    Overridden HOME = '/srv/slapgrid/slappart18'
    [2016-03-15 18:12:20,713] DEBUG    Removed from environment: LANG, LOGNAME
    [2016-03-15 18:12:20,714] ERROR
    Traceback (most recent call last):
      File "/opt/slapos/eggs/slapos.core-1.3.15-py2.7.egg/slapos/grid/slapgrid.py", line 1153, in processComputerPartitionList
        self.processComputerPartition(computer_partition)
      File "/opt/slapos/eggs/slapos.core-1.3.15-py2.7.egg/slapos/grid/slapgrid.py", line 1027, in processComputerPartition
        local_partition.install()
      File "/opt/slapos/eggs/slapos.core-1.3.15-py2.7.egg/slapos/grid/SlapObject.py", line 517, in install
        self.software_release_url, template_location))
    IOError: Software Release https://lab.nexedi.com/nexedi/slapos/raw/master/software/slapos-master/software.cfg is not correctly installed.
    Missing file: /opt/slapgrid/bcb8fbfbae583c14297f14ec8ebc3724/instance.cfg
    [2016-03-15 18:12:22,312] INFO     Finished computer partitions.

    1. Can you please tell me what have I done incorrectly?

    2. The payment issue is resolved and I see the invoice is now marked as Paid, hence I assume the account is now validated.

    3. If I deploy my own slapos master, will I still be charged an amount of 2 EUR on a daily basis?

    Look forward to your guidance.

    Thanks,

    Shrenik