Netconfig VLAN Assignment - is this feasible?

Unanswered Question
Jan 22nd, 2008

would it be feasible to create a netconfig template in order to change/move/assign ports into different vlans? I'm assuming it would need one per device. Any ideas or examples appreciated

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 4.5 (2 ratings)
Loading.
Joe Clarke Tue, 01/22/2008 - 10:32

Yes, this is possible. And no, you do not need to create one template per device. Instead, you can used a parameterized template, and create an input XML file that gives all of the devices' required assignments. For example, your template may be:

interface FastEthernet $int1

switchport access vlan $vlan1

interface FastEthernet $int2

switchport access vlan $vlan2

Then, your parameter file would be something like:

0/1

100

0/2

6

1/0/1

10

1/0/2

60

Consult the online help for Netconfig for more on Parameterized templates.

gcossins Fri, 01/25/2008 - 09:27

Thanks, have had ago but doesn't seem to be able do what I need -

What I want is to select a device, then select task e.g. 'Assign Port to Voice Vlan', then from a drop down list select the interface (like the pre-defined templates drop down lists).

A command list removing all possible previous interface commands and applying new ones such as vlan membership, cos parameters etc will then be applied to the interface.

Joe Clarke Fri, 01/25/2008 - 10:00

This kind of thing is not possible in Netconfig. Building new interface widgets for custom templates is not doable. The parameterized templates are the closest thing. I know this kind of thing is possible in the Network Compliance Manager product.

Additionally, taking CoS, etc. out of the picture, Campus Manager provides a VLAN Port Assignment tool that allows you to pick the device, port, and VLAN from lists.

gcossins Fri, 01/25/2008 - 10:32

Thanks - at leat I know it cannot be done this way. Yes I looked at CM & vlan port assignment but discounted it because i need to assign & re-assign ports to voice & no voice vlans, also the voice ports have two vlans associated & cos so I need something a bit more advanced.

gcossins Fri, 01/25/2008 - 11:12

Ok have decided to create a script file that re-writes the parametized file as required.

Problem I have is that when I display the cli commands, the parameterized variable names e.g. $int1 are shown and not the actual values I want to use e.g. FastEthernet 1/0/2 Is this correct?

Joe Clarke Fri, 01/25/2008 - 11:38

This is correct. Viewing the CLI for the instance will still show the variable. The parameter values are merged with the variables at deployment time.

gcossins Fri, 01/25/2008 - 11:40

Thanks - at leat I know it cannot be done this way. Yes I looked at CM & vlan port assignment but discounted it because i need to assign & re-assign ports to voice & no voice vlans, also the voice ports have two vlans associated & cos so I need something a bit more advanced.

Actions

This Discussion