'Exectuting Mininet CLI command in Xterm Window

I have a topology in which the h4 is the receiver and rest of the hosts are senders.I am executing a bash script on the h4 which returns the ip of one of the hosts(say h5) to a variable. Now i need to turn the link of that host with it's switch, down. I know i can do this with the mininet CLI as link h5 s3 down. But i need to use the h4's xterm window to do the same. Is there any solution?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source