Testing SampleApplication.py

245 views
Skip to first unread message

ydtak...@nissho-ele.co.jp

unread,
Feb 9, 2016, 8:13:02 PM2/9/16
to OpenClos
Hi all,
We want to build 3-stage Clos (4 Spine (QFX10008), over 30 Leaf(QFX5100))
We are testing SampleApplication.py
So, We are editing the "closTemplate.yaml".
When We change the spineCount and LeafCountm,
that displays error messsages this below.

######## error log ##########
root@ubuntu:/usr/local/lib/python2.7/dist-packages/OpenClos-2.5.dev1-py2.7.egg/jnpr/openclos# python tests/sampleApplication.py
Couldn't import dot_parser, loading of dot files will not be possible.
2016-02-10 09:43:14,754 [trapd       ] [INFO    ] [7f457dc07740] Starting trap receiver...
2016-02-10 09:43:14,761 [trapd       ] [INFO    ] [7f457dc07740] Trap receiver started on 0.0.0.0:20162
Traceback (most recent call last):
  File "tests/sampleApplication.py", line 96, in <module>
    app.createConfigFilesForDevices()
  File "tests/sampleApplication.py", line 38, in createConfigFilesForDevices
    self.pod = l3ClosMediation.createPod('anotherPod', pods['anotherPod'])
  File "/usr/local/lib/python2.7/dist-packages/OpenClos-2.5.dev1-py2.7.egg/jnpr/openclos/l3Clos.py", line 77, in createPod
    self._validatePod(pod, podDict, inventoryData)
  File "/usr/local/lib/python2.7/dist-packages/OpenClos-2.5.dev1-py2.7.egg/jnpr/openclos/l3Clos.py", line 287, in _validatePod
    raise CapacityMismatch("Pod[id='%s', name='%s']: inventory device count %d does not match capacity %d" % (pod.id, pod.name, inventoryDeviceCount, expectedDeviceCount))
jnpr.openclos.exception.CapacityMismatch: CapacityMismatch errorCode: 1008, errorMessage: Device count does not match capacity: Pod[id='1290b1a9-479e-489f-813f-181c670f9cd8', name='anotherPod']: inventory device count 6 does not match capacity 34, cause: 1008

######## ClosTemplate.yaml ##########
------- snip ------- 
    anotherPod:
        spineCount : 2 ###### change the 4 ######
        # possible options for leafDeviceType are qfx5100-24q-2p
        spineDeviceType : qfx5100-24q-2p
        # the image file should be placed under <install dir>/jnpr/openclos/conf/ztp
        # if not placed under this dir, the file would not be accessible from http server
        # and ZTP process will be broken, these are optional, overrides global setting ztp.junosImage
        spineJunosImage : jinstall-qfx-5-14.1X53-D30.3-domestic-signed.tgz

        leafCount : 4  ###### change the 30 ######
        # possible options for leafDeviceType are qfx5100-96S, qfx5100-48s-6q
        # for complete list refer to openclos.yaml
---------------------------- 

It has limitation ?
please let me know why be an error.

Thanks
Yudai

Moloy c

unread,
Feb 11, 2016, 1:21:39 PM2/11/16
to OpenClos
Hi Yudai,
Thanks for your interest on Openclos. 
closTemplate.yaml has two POD definitions and you are modifying POD definition "anotherPod". As you update the spine/leaf counts, you also need to update the device inventory. For this particular POD the device inventory is indicated by "inventory : inventoryAnotherPod.json". If you look at this json file, it has entry for 2 spines and 4 leaves. So please update this file to match your spine/leaf count. 

Please let us know if you more help.

Moloy 

Yudai Takahashi

unread,
Mar 10, 2016, 8:29:37 PM3/10/16
to OpenClos
Hi, Moloy

Thank you for your advice.
I have one more question.
Do you have any plan include qfx10008 on device Family.yaml ?
(I found deviceFamily on DevR3. I hope that deviceFamily include at the master version)

Regards,
Yudai

Moloy c

unread,
Mar 11, 2016, 4:44:44 PM3/11/16
to OpenClos
Yes! Currently we are working on release 3.0. QFX10008 will be supported in that. If you are interested you can start playing with codes from devR3.0 branch, but it is constantly evolving and may not be stable.

Regards,
Moloy

Yudai Takahashi

unread,
Mar 18, 2016, 4:27:06 AM3/18/16
to OpenClos
Hi moloy

I want to deploy QFX10002-36q on Spine.
But, it does not work ztp.
(leaf device(QFX5100,EX4300) worked)
I tried this below config.
Let me know if it is wrong.

##### inventoryAnotherPod.json  #####
{   "spines" : [
       { "name" : "clos-spine-01", "family" : "qfx10002-36q", "serialNumber" : "xxxxx", "deployStatus" : "deploy"},
       { "name" : "clos-spine-02", "family" : "qfx10002-36q", "serialNumber" : "xxxxx", "deployStatus" : "deploy"}
    ],
    "leafs" : [
       { "name" : "clos-leaf-01", "family" : "qfx5100-48s-6q", "serialNumber" : "xxxxx", "deployStatus" : "deploy"},
       { "name" : "clos-leaf-02", "family" : "qfx5100-48s-6q", "serialNumber" : "xxxxx", "deployStatus" : "deploy"},
       { "name" : "clos-leaf-03", "family" : "ex4300-48t", "serialNumber" : "xxxxx", "deployStatus" : "deploy"},
       { "name" : "clos-leaf-04", "family" : "qfx5100-24q-2p", "serialNumber" : "xxxxx", "deployStatus" : "deploy"}
   ]
}

##### inventoryAnotherPod.json  #####
    anotherPod:
        spineCount : 2
        # possible options for leafDeviceType are qfx5100-24q-2p
        spineDeviceType : qfx10002-36q
        # the image file should be placed under <install dir>/jnpr/openclos/conf/ztp
        # if not placed under this dir, the file would not be accessible from http server
        # and ZTP process will be broken, these are optional, overrides global setting ztp.junosImage
        spineJunosImage : jinstall-qfx-10-f-15.1X53-D30.17-domestic-signed.tgz

        leafCount : 4
        # possible options for leafDeviceType are qfx5100-96S, qfx5100-48s-6q
        # for complete list refer to openclos.yaml
        # the image file should be placed under <install dir>/jnpr/openclos/conf/ztp
        leafSettings :
            - deviceType : qfx5100-48s-6q
              junosImage : jinstall-qfx-5-14.1X53-D30.3-domestic-signed.tgz
        #    - deviceType : ex4300-48t
        #      junosImage : jinstall-ex-4300-14.1X53-D35.3-domestic-signed.tgz
            - deviceType : qfx5100-24q-2p
              junosImage : jinstall-qfx-5-14.1X53-D30.3-domestic-signed.tgz
        # Number of uplink from leaf must be properly connected to indicate
        # the leaf device as "good". If the leaf device is not in "good" state
        # it would not go through 2-stage ZTP/configuration process.
        # Possible value is in between 2 and spineCount, inclusive both end.
        # This field is optional, default value is max(2, math.celi(spineCount/2))
        # leafUplinkcountMustBeUp : 2

Regards,
Yudai

Sunil Rawoorkar

unread,
Mar 22, 2016, 2:57:28 PM3/22/16
to OpenClos

Hi Yudai,

 

On QFX10002 'vme' interface is going to be removed and only 'em0' and 'em1' will be supported as management interface on QFX series.
There is a recent fix in 15.1 Junos where em0 was not enabled with dhcp config when the devices are zeroized, now the fix is in place and will be available in 15.1 release.

ZTP will work once you have this junos build. We are also making changes in openclos 3.0 to change management interface from 'vme' to 'em0'.

Thanks,

Sunil


BTW, For some reasons your next query did not get posted to google groups. Just copying it here  -



Hi Yudai,

 

Please see my reply inline -

 


Hi Sunil

 

Thank you for your reply.

I understood it as the following but is this correct?

 

1.QFX10002 will support dhcp config on em0 next junos version(Junos15.1X53D3x, right?).

 

[Sunil]: That is right

 

2.OpenClos will support em0 on OpenClos 3.0

   # Question: When is it scheduled to be released OpenClos 3.0 ? (As a major version)

 

[Sunil]: In couple of weeks we will have alpha ready for testing  

 

Regards,

Yudai 

 

 

Sunil Rawoorkar

unread,
Mar 22, 2016, 3:00:29 PM3/22/16
to OpenClos
Yes, that is right qfx10002 will support dhcp config on em0 next junos version - Junos15.1X53D3x.

Openclos 3.0 alpha will be available in few weeks for testing.

Armen Martirosyan

unread,
May 5, 2016, 7:18:17 PM5/5/16
to OpenClos
Hi Moloy,

I have a question regarding inventoryAnotherPod.json file. I opened it and it has entries in it. I am not sure if it suppose to be like that or the entries are there as an example. Do I need to remove the entries and define my devices' macAddress and serialNumber instead? 
{   "spines" : [
       { "name" : "clos-spine-01", "macAddress" : "10:0e:7e:af:35:41", "serialNumber" : "VG3714070310", "deployStatus" : "deploy"},
       { "name" : "clos-spine-02", "macAddress" : "10:0e:7e:af:50:c1", "deployStatus" : "deploy"}
    ],
    "leafs" : [
       { "name" : "clos-leaf-01", "family" : "qfx5100-96s-8q", "serialNumber" : "VB3113470018", "deployStatus" : "deploy"},
       { "name" : "clos-leaf-02", "family" : "qfx5100-96s-8q", "macAddress" : "10:0e:7e:b8:9d:01", "deployStatus" : "deploy"},
       { "name" : "clos-leaf-03"},
       { "name" : "clos-leaf-04"}
    ]
}


Second question: I modified deviceFamily.yaml file so qfx5100-48s-6q would appear as a spine device. Will this work?
    qfx5100-48s-6q:
        spine:
            uplinkPorts: 'et-0/0/[48-53]'
            downlinkPorts: 'xe-0/0/[38-47]'
        leaf:
            uplinkPorts: 'et-0/0/[48-53]'
            downlinkPorts: ['xe-0/0/[0-37]', 'ge-0/0/[0-47]']


Thank you!

Sunil Rawoorkar

unread,
May 6, 2016, 12:28:37 AM5/6/16
to OpenClos
Hi Armen,

For your first question, that is right you have to replace your device serial/MAC addresses. Those serial/MAC are just an example.

For your second question, "qfx5100-48s-6q" is supported as leaf and cannot be configured as spine device.

For supported roles please refer to the API -

http://<ipaddress:port>/openclos/v1/underlay/conf

Yudai Takahashi

unread,
Jun 3, 2016, 6:29:31 AM6/3/16
to OpenClos
Hi Sunil,

I foud OpenClos3.0 beta on GitHub.
Could you let me know the rough date when the OpenClos3.0 will be ready?

Regards,
Yudai Takahashi

Sunil Rawoorkar

unread,
Jun 7, 2016, 5:21:19 PM6/7/16
to OpenClos
Hi Yudai,

openCLOS3.0 FRS is planned for Sep 2016.


Thanks,
Sunil

Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
0 new messages