This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| virtualization:containerlab [2023/04/12 16:55] – jotasandoku | virtualization:containerlab [2025/09/04 21:48] (current) – jotasandoku | ||
|---|---|---|---|
| Line 19: | Line 19: | ||
| create a simple topology file.\\ | create a simple topology file.\\ | ||
| [[https:// | [[https:// | ||
| - | |||
| - | netlab up | ||
| - | sudo | ||
| - | sudo containerlab destroy -t clab.yml | ||
| - | netlab up # and configuration will be persistent | ||
| + | ---- | ||
| **__LIFECYCLE NETLAB PROJECT - CONTAINERLAB__** | **__LIFECYCLE NETLAB PROJECT - CONTAINERLAB__** | ||
| Line 34: | Line 30: | ||
| netlab initial | netlab initial | ||
| ! work on the lab, saving all work with 'wr mem' | ! work on the lab, saving all work with 'wr mem' | ||
| + | netlab collect | ||
| sudo containerlab destroy -t clab.yml | sudo containerlab destroy -t clab.yml | ||
| - | ! here I come back to work on the lab | + | ! **SUBSEQUENT USES:** |
| - | | + | sudo containerlab deploy -t clab.yml |
| - | | + | |
| - | # work on the lab, saving all work with 'wr mem' | + | # work on the lab |
| + | netlab collect | ||
| sudo containerlab destroy -t clab.yml | sudo containerlab destroy -t clab.yml | ||
| Line 140: | Line 138: | ||
| ---- | ---- | ||
| + | TCPDUMP IN CONTAINERLAB: | ||
| + | \\ | ||
| + | |||
| + | * Official guide: [[https:// | ||
| + | * netlab wrapper: '' | ||
| + | * more info : [[https:// | ||
| + | * We run tcpdump over the cname of the container in question: | ||
| + | sudo containerlab inspect --all # find the name (cname) | ||
| + | docker exec clab-simple_ipv4-rtr ip a | grep ' | ||
| + | ssh $containerlab_host_address "ip netns exec $lab_node_name tcpdump -nni $if_name" | ||
| + | # Enable non-sudo users to capture: https:// | ||
| + | ssh ubuntu@143.47.236.251 "sudo ip netns exec clab-vxlan1-s1 tcpdump -U -nni et1 -w -" | wireshark -k -i - | ||
| + | |||
| + | |||
| + | ---- | ||
| + | ** SAVE WORK AND COME BACK ** | ||
| + | # from your lab folder | ||
| + | netlab collect -o saved # important, folder is not called ' | ||
| + | netlab down --cleanup | ||
| + | |||
| + | netlab up | ||
| + | netlab config saved | ||
| + | |||
| + | |||
| + | ---- | ||
| + | ** INSPECT LAB WITH NETLAB ** | ||
| + | netlab report addressing | ||
| + | netlab report wiring | ||
| + | netlab show reports | ||
| + | |||