cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
952
Views
0
Helpful
2
Replies

How to show all service profile associated to a particular VLAN via command line

vimalvijayan348
Level 1
Level 1

Can someone please help me to find all service profile associated to a particular VLAN via command line in the UCSM.

 

Eg: I have a VLAN (1022) existing in the UCSM named 'CSA-DBS-GG_1022'. We also have many service profiles existing in different sub organization. Trying to find what command will show all the service profile associated to that particular VLAN in that UCSM.

 

Thank you in advance. 

2 Replies 2

josoneal
Cisco Employee
Cisco Employee
Hello,

I'm not quite sure we can associate a VLAN with a service profile via command line but we can use the show run-configs command to get the server and vnic with the allowed vlans. You can then search copy that output in a 3rd party tool and search for that vlan. it may be part of a vlan range. Once you know which servers, you can associate those server to the correct service profile.

Try the following command in command line
#connect nxos a|b
#show running-config | include "description server|switchport trunk allowed vlan"
You should see an output like this:
description server 3, VNIC vNIC_MGMT_A <----------------- Server and vNIC being used
switchport trunk allowed vlan 1,28,101 <-------------------- Vlans associated with the above server and vNIC
description server 1/8, VNIC managementA <----------------- Server and vNIC being used
switchport trunk allowed vlan 28,101<-------------------- Vlans associated with the above server and vNIC

If I can find another way. I will let you know.

-Josh

Thank you for your reply Josh.. :)

 

But this is not what I am looking for. 

Let me explain the request in detailed: We have almost 450 VLANs existing in our UCSM and almost 150+ physical servers (I guess). Recently we found that few VLANs which we have added 1 year before were with a wrong names. So we want to delete those VLANs first. But before deleting those VLANs we need to check if any physical servers are already using by those VLANs or not. Manually looking that VLAN in each service profile is time consuming. So I am looking for a command which can show all the service profile those are using by that VLAN.

Review Cisco Networking for a $25 gift card

Review Cisco Networking for a $25 gift card