Summary

This gitrepo Will be used for this post.

We will walk over some thoughts, methadologies and a demo on leveraging MCP server/client on CloudVision portal with Claude desktop.

Disclaimer

I in a way have no idea what I am doing. I of course am just another person trying to navigate a lot of the newer tech in this world of AI and other things. So this is not exactly a Arista supported technology either just a thing that I am playing with. If you do have any questions or want to add to this I am always up for discussion.

MCP what is it?

MCP is about all the rage here within the world of AI at this point. I watched a video from Anthropic a few weeks ago. I think most will recognize them from their work they have done on Claude. The video is almost 2 hours but really worth a watch since I think most people would agree that when learning a new thing that is completely foreign to them videos are best for means of understanding.

So MCP as a whole is a standards way for a client/server to connect to a “thing” and retrieve information such as tooling, services or prompts about the “thing” I say thing because I want to be very careful here as a thing could be anything from an API to a filesystem. I think it works really well from a good API surface. The general purpose I see this working out really well for people is connecting MCP servers to their own internal services. Antrhopic pitches this within their own internal docs as a USB port that connects everything and I generally agree this is a good concept. What is also nice is that for every MCP server out there it supports reflection which tells a client exactly which tools, resources and prompts in which can be used. Also the FastMCP framework is really easy to use.

For all my networking folks out there reading this and are unsure of this its okay I was not entirely sure about this either. But prior to MCP as a whole if you wanted to create an AI agent things where all over the place and there was not a general standard. I have read a few books on creating AI agents and it was pretty rough. You had to do a lot of things with RAG potentially and also vector stores. You can still do these things with MCP but I feel like as a person just messing with this its really easy to get started with MCP versus a lot of the agents. Even dealing with the agents it is a bit tough.

Now you can find all of these MCP servers and Clients. So if you are starting out this is really easy to simply get something like Claude Desktop and import any of these servers within Claude and simply start asking it questions. The craziest part in my opionin is Claude simply knows what you are trying to accomplish. More to this later.

The setup

So most of my day to day work involves Arista CloudVision which if you are unfamiliar

The overall topology with CloudVision looks like the following.

cvp

CloudVision as a whole will ingest all of the streaming data for every switch which is then streaming into it. So its like a giant network database for every switch, access point etc. So it holds all the network data. We also expose a lot of data via what we call resource api’s or rAPI’s. But this post is more about MCP than it is about CVP.

So the idea here is that if we have well developed and typed API’s it would be a really amazing idea to simply feed an LLM with this data and have a user sorta promt and ask these tools what is happening within the network.

So this is what it looks like with an MCP server and Claude Desktop in the mix.

cvp

Most demos out there will include Claude Desktop and the reason for that in my opinion is that Claude Desktop has a really easy support to get this up and running easily.

Within the git repo will have all the other information to make this work properly. So I will outline some of the code and examples here.

Claude is obviously going to be the client here. Here is an example of what Claude or any MCP client needs entirely for MCP to function.

The file I am using for this is claude_desktop_config.json.

{
  "mcpServers": {
    "CVP MCP Server": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "fastmcp",
        "fastmcp",
        "run",
        "/mcp-server-cvp-demo/secondmcpserver.py"
      ]
    }
  }
}

Simply put all this is doing is running on my system the secondmcpserver.py file with the fastmcp framework. I have seen a few other mcp servers like github’s which leverages docker.

So the next time you simply open up Claude it will then open this up as a MCP server which as long as the code is good we can then interact with the MCP server. Which technically the client / server are both Claude since it is simply a python file running on my system.

The Code

So this is written in python. I could ramble on about how I hate how async works and my code probably reflects this however I will explain a lot of this.

There are a few functions here.

get_env_vars - This is exactly what it sounds like. There are two env vars you need to either add to your own system. CVP and CVPTOKEN cvp is the address of the cvp server and CVPTOKEN is the string of the json web token to authenticate to CVP.

get_request_cvp - This is a function that will allow for a simply rest GET to CVP by passing in the token and the url you want to go to.

get_inventory - This leverages the Arista Inventory Resource API which will return inventory in json with some other meta data like version of the switch and model.

get_events - This leverages the Arista Events Resource API This will return events. Events are going to be network wide events. As in BGP broke, high latency etc etc.

All of these will use the mcp.tool() decorator and the function. So the MCP framework will call that then the function.

As long as this all supports either the decorator for tools,resources or prompts MCP kind of just works which is kind of insane to me but really neat at the same time.

So overall, as long as these functions return data the LLM can then use it.

Claude

So lets load up Claude and take a look at what we have going here.

If all is going well we should see the tools button reflect that we have MCP tools we can leverage.

So lets ask it a simple question about inventory. Notice that I am not telling it to use the local inventory mcp tool it figures it out for me.

3

4

So what happened here? We simply asked it about the inventory. Since it simply knows that there is a cvp inventory mcp service it can then check to see if the mcp service is appropriate for my prompt. I could further ask it questions if I would like based off of those devices like how much memory is available, or platform etc.

Now this was a bit interesting on the events side.

5

Asking it for BGP events it actually gave me more than what I expected.

Based on the information I've gathered, let me provide you with a summary of recent events and potential BGP issues in your network:
Recent Network Status

BGP-Related Issues:
I don't see any specific BGP failure alerts in the events, but there are several network issues that could potentially impact BGP operation:

Several EVPN configuration consistency check failures on devices including DC1_LEAF1A, DC1_LEAF1B, DC1_SPINE1, xxx, and xxx. Since EVPN often relies on BGP, these inconsistencies could be affecting BGP operation.
VXLAN configuration check failures on multiple devices (SGD21076098, SGD21075972, SGD21030209). VXLAN overlay networks typically use BGP EVPN for control plane functions.


Device Connectivity Issues:

Several devices have stopped streaming to CloudVision, including:

xxx (xxx) - just went inactive today (April 17, 2025)
xxx (xxx) - inactive since March 10
xxx (xxx) - inactive since September 2024
xxx (xxx) - inactive since September 2024
xxx (xxx) - inactive since November 2024



These streaming failures might indicate connectivity issues that could also affect BGP peering.
Interface Issues:

Recent interface errors on DC1_LEAF1A showing TX errors on Port-Channel3 and Ethernet4 (today, April 17)
Multiple unexpected interface shutdowns on xxx and xxx
Interface issues on SGD21076098 (xxx) with Ethernet1 and Ethernet2


Other Relevant Issues:

NTP clock synchronization problems on multiple devices, which can indirectly affect routing protocol operation
Power supply failures on several devices



DC1 Environment Status (Most Recent Activity)
Your DC1 environment (spine-leaf architecture) shows some recent activity that might be related to BGP concerns:

DC1_LEAF1A and DC1_LEAF1B both have EVPN consistency check failures from March 24
DC1_SPINE1 also has EVPN consistency check failures
DC1_LEAF1A is experiencing interface TX errors today (April 17)
DC1_SPINE1 had a designed configuration change on April 15, which could have affected BGP configuration

Recommendation
Since you're concerned about BGP issues, I would recommend checking:

The BGP peering status on your DC1 environment devices, particularly between the spine and leafs where EVPN consistency issues have been reported
The recently inactive device xxx (xxx) which went down today - this could be related to your concern about BGP breaking somewhere
The interface errors on DC1_LEAF1A, as faulty interfaces can disrupt BGP sessions

Most of the devices in your network show "STREAMING_STATUS_INACTIVE" which means CloudVision isn't receiving real-time updates from them. Only your DC1 environment devices (the cEOSLab devices) are actively streaming.
Would you like me to help you look into any specific part of this information in more detail?RetryClaude can make mistakes. Please double-check responses.

This is cool becaause this can make recommendations and tell a person what to do. It is really interesting to note that when I asked for events it used both events and the inventory feature to figure out the entire picture.

In summary

Needless to say I am really bullish on this. For the reason that I think generally speaking on network devices weather they are management platforms or orchestration systems you might need expertise to guide you through and help out with them. Its also really difficult to find entirely what you are potentially looking for doing way too many clicks. I find MCP with LLM’s to be a great way to get expertise on these things.