Showing posts with label solution. Show all posts
Showing posts with label solution. Show all posts

Monday, April 29, 2024

Solved: Error: eth0 interface name is not allowed for R2 node when network mode is not set to none in containerlab

 Problem:

   Containerlab returns a similar error:

Error: eth0 interface name is not allowed for R2 node when network mode is not set to none


Solution:

 In the .yml file in the node section indicating the topology error specify:


network-mode: none


Example:

topology:

  kinds: 

    linux:

      image: quay.io/frrouting/frr:8.4.1

  nodes:

    R1:

      kind: linux

      image: quay.io/frrouting/frr:8.4.1

      network-mode: none


 Rerun the topology with clab dep -t file.yml and that's it!


Luck.

Tuesday, February 27, 2024

This is the way to install the telnet command in Alpine Linux (very popular in the container world such as docker)

This is the way to install the telnet command in Alpine Linux (very popular in the container world such as docker)

#apk update

#apk add busybox-extras

Friday, February 23, 2024

The real solution to run ContainerLAB on MAC m1 or m2 apple silicon

Step 1: Install Canonical Multipass your MAC 

$brew install multipass


Step 2: Install the VM called docker

$multipass launch docker --name mydocker


Step 3: Connect to the new VM

$multipass shell mydocker


Step 4: Inside the VM install ContainerLab

$sudo su

#bash -c "$(curl -sL https://get.containerlab.dev)"


Let's try this simple back2back topology of two Linux computers with FRR


-- 2-frr-back2back.yml --

name: ipv6-ws

topology:

   kinds:

     linux:

       image: ghcr.io/hellt/network-multitool

   do not give:

   ROUTERS ###

     A1:

       kind: linux

       image: quay.io/frrouting/frr:8.4.1

       exec:

         - "sysctl -w net.ipv6.conf.all.forwarding=1"

         - "ip address add dev eth1 2001:db8:ffab::1/64"

     A2:

       kind: linux

       image: quay.io/frrouting/frr:8.4.1

       exec:

         - "ip address add dev eth1 2001:db8:ffab::2/64"

         - "sysctl -w net.ipv6.conf.all.forwarding=1"

   links:

     - endpoints: ["R1:eth1", "R2:eth1"]

--- yml --


Step 5: Let's build the topology with clab:

clab dep -t 2-frr-back2back.yml


Step 6: finally we are going to connect to one of the VMs inside ContainerLAB

docker exec -i -t clab-ipv6-ws-R2 bash

Thursday, July 6, 2023

Google returns: 403. That's an error. Your client does not have permission to get URL / from this server. That's all we know.

 Introduction:

   You want to do a google search and the page returns: "403. That’s an error.

   Your client does not have permission to get URL / from this server. That's all we know."







In my case I was using an IPv6 tunnel with Hurricane Electric, specifically the /64 that they deliver in the tunnels.


Solution?

    Ask Hurricane Electric at the portal for a /48 routed. That's it! Then I removed the old /64 prefix from the router's SLAAC, leaving only a /64 belonging to the /48.


Good luck!

Thursday, May 25, 2023

Strange ssh behavior on MAC - Copy/Paste Issues

 Situation:

   Strange behavior of SSH on MAC, problems with copy/paste in terminal during ssh. Does the clipboard work in other applications?


Solution:

   At least in "vi" the solution is very simple. Edit the file: ~/.vimrc and paste the following content:


if !has("gui_running")

   set mouse=

endif


Luck!

Monday, January 23, 2023

Python: reading a text file - character

Situation:

   Reading a text file in python3 (csv or txt) there is a character that can be appreciated using "more" in terminal but in python3 the situation is more complicated.


Example:

  $ more epa.csv

<U+FEFF>the text


Problem:

   Python3 reads the file well, it doesn't throw an error, but that invisible "character" remains in the variables, the texts, etc. and can cause some inconvenience.


Solution:

   The solution is to read the file and specify the encoding, something as simple as:


FILENAME="epa.csv"

with open(FILENAME, encoding='utf-8-sig') as file:

     for line in file:

         print(line)




Explanation (taken from: https://stackoverflow.com/questions/17912307/u-ufeff-in-python-string):


The Unicode character U+FEFF is the byte order mark, or BOM, and is used to tell the difference between big- and little-endian UTF-16 encoding.


Good luck,

Wednesday, July 13, 2022

Fixing/Solved "Unable to parse package file " after apt

Problem: 
   We get an error after executing any apt command in linux 

Solution 
   The solution is very easy, I spent so many hours fixing it. 
   You just have to delete the file mentioned in the error, in my case I got: "E: Unable to parse package file /var/lib/apt/extended_states (1)" 
   I just deleted the file /var/lib/apt/extended_states 

 Example: 
   #sudo rm /var/lib/apt/extended_states 

 That's it

Sunday, September 26, 2021

Solved: VBoxGuestAdditions.iso (VERR_PDM_MEDIA_LOCKED)Solved:

Situation: 
   When inserting Guest Additions CD Image in a Debian VM you are getting VERR_PDM_MEDIA_LOCKED 

Solution: 
   There are many solutions, like: 
1) Executing 
  sudo apt-get upgrade 
  sudo apt-get install virtualbox-guest-additions-iso
2) Removing and inserting the cd from the VM configuration

and a third one which is the one that worked with me:

a) Start the VM
b) Open a terminal
c) Execute this:
  sudo su
  cd /media
  mkdir cdrom
  mount /dev/cdrom /media/cdrom
  cd cdrom
  sh VBoxLinuxAdditions.run

Hope this helps.

Alejandro,


Saturday, July 24, 2021

Solved: GNS3 - Private Vlan - non-operational - Cisco

Status:

  In summary: private vlan are not working in GNS3, not even using IOU or VIRL


Solution:

  User IOU i86bi-linux-l2-adventerprisek9-15.2d.bin



Test:

IOU3#show vlan private-vlan 

Primary Secondary Type              Ports


------- --------- ----------------- ------------------------------------------


500     501       community         Et0/1, Et0/2, Et1/0


500     502       isolated          Et0/0, Et0/3, Et1/0




Good luck!,




Tuesday, June 1, 2021

Solved: Finder on MAC does not find any files in its searches

Problem:

   Finder can't find files when searching.


Solution:

   I know there are many solutions, many with spotlight in system preferences, but the one that worked for me was to open a terminal window and run/execute:


  #sudo mdutil -E /




    I hope this is useful

Friday, January 1, 2016

Virtualbox in Windows. Bridge adapter + IPv6 not working

Introduction:
  When trying to use IPv6 in Virtualbox inside a guest where the adapter is bridge to the wireless interface of the host, the VM does SLAAC correctly but HTTP or ping6 does not work.

Solution:
  To solve this issue just reinstall/repair your current Virtualbox instalattion (version 5) adding the following parameters to the installer: "-Win.exe -msiparams NETWORKTYPE=NDIS5"

The result would be something like:

G:\>VirtualBox-5.0.12-104815-Win.exe -msiparams NETWORKTYPE=NDIS5

So, you cannot double click on the installer, you need to do it from command line with admin privileges.

Workaround:
  The problem is only with the bridging to the wireless adapter, you, if possible, you could bridge to a non-wireless interface and IPv6 should work perfectly.

References:
https://www.virtualbox.org/ticket/14457

Good luck,


Tuesday, February 17, 2015

Solution to quagga vtysh "Exiting: failed to connect to any daemons."

Description:
   When you run the command in the linux shell vtysh to connect to the quagga daemons (such as bgpd, ospfd, etc) returns  the following error "Exiting: failed to connect to any daemons"

Just like this:

alejandro @ miserver: ~ $ vtysh -d bgpd
Exiting: failed to connect to any daemons.

alejandro @ miserver: ~ $ vtysh
Exiting: failed to connect to any daemons.


Solution:
   The solution is to add the user that is executing vtysh to the quagga group. To do this edit the /etc/group file.
   After editing /etc/group should be something like:

quagga:x:1003:alejandro

You can specify multiple users doing:

quagga:x:1003:alejandro, john


   This is necessary because vtysh tries to connect to the daemons using UNIX domain sockets and not all users (for security reasons) have access to these sockets.

Another solution:
   Another solution might be during the compilation phase where you can specify the linux/unix group for sockets mentioned above. Example:

./configure --enable-vty-group = group


   Good luck, I hope this helped,