Skip to Content.

rare-dev - Re: [rare-dev] Swap Different Configuration in FreeRtr

Subject: Rare project developers

List archive


Re: [rare-dev] Swap Different Configuration in FreeRtr


Chronological Thread 
  • From: Carmen Misa Moreira <>
  • To: <>
  • Subject: Re: [rare-dev] Swap Different Configuration in FreeRtr
  • Date: Wed, 1 Dec 2021 12:10:10 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 188.184.36.16) smtp.rcpttodomain=lists.geant.org smtp.mailfrom=cern.ch; dmarc=bestguesspass action=none header.from=cern.ch; dkim=none (message not signed); arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=P/efzRaFvn/ZncQklBM7O3aaI7ceiDEM4b45/O40gV0=; b=VWF/Pkv9K6UvDnILRa8x1ji4xgMIIMSChKrEc4/hnPnofU3lZhHCiMg2cZvv1bjgupmElAYsX0MtAckUD+2tjqJT/S/da2BRggc6dkmvIDYgmzrJn4utXgyTfjEhXlmDMikY716UBkB7IfjNKpx/kzlAHIm7bmSREH8eoiySEk6aPlLIeowQljzg+ci2l372RKejFUt3D56QWmmhONUnYHm6EvWhDW2UuTiaXRxOj3bR1g/aZBp+hasb8uaxirXvReuNPbT+KKN4Ng8LFWe5Y4btFmZxO0q+fe9iitWk/c+47eYF8u+5csRSyWuFWlCT5fb8BML5gA8Q4Y/0tzcUPA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JRM8XHRLiwIurYbn68TuwInCjOfw2e2uIzsC/ZcUZWS4jWh1fBpia14tDRNJCVKTYAx/0Yt/CaLnctZdUp4V6viJik00C4Si2ZTD1vtregrGgsdDrWQonYcr0y3Fw0ZN5ewVJ142fktuQqUsA74RMjaN+4hkm9SE9xiu715Tc0bC0aozmcx5TYUdOnWBKc+NCBGl1M0hHB76uF/fH014ay9hCDi3WJ/ApCyOEZxoe21X3elc6eDk9XR/lbpAc6WaV2XFmMmXPbdvfqaGStpCjHtcg2qItVRYZCMT9w81eL1EiyBZGbfjbH/ymUAmqCYZMNIS8LrS2iplMv0bP4CXzA==

Hi all,

@Frederic I don't have this path on the router "/opt/freertr/bin/hwdet-main.s"

By the way, I'm storing the configuration in different .txt files and then I just copy one of the configuration into /etc/freertr/rtr-sw.txt and then 'reload warm' or if it's needed reboot the switch this works to me!

Best regards,

Carmen Misa


On 26.11.21 16:57, mc36 wrote:
hi,
so we have "config reload <url>" to load from a config store or "config startup" to edit locally...
then reload warm and it moved to the new configuration... we also have "config overwrite-network <url>"
that operates on the running configuration but imto that one have high chances to run into bugs... :)
anyway, as you can note, you should take a look at "config ?" maybe others better fit your needs...
regards,
cs


On 11/26/21 15:57, Frédéric LOUI wrote:
Hi !

In p4 switch, software configuration is saved in /etc/freertr/rtr-sw.txt

Then you can save multiple files:
/etc/freertr/rtr-test1-sw.txt
/etc/freertr/rtr-test2-sw.txt
/etc/freertr/rtr-test3-sw.txt
/etc/freertr/rtr-test4-sw.txt
/etc/freertr/rtr-test5-sw.txt

And make sure you start freertr with the right /etc/freertr/rtr-test<x>-sw.txt files

In /opt/freertr/bin/hwdet-main.sh

...
while (true); do
   cd /opt/freertr/lib

   stty raw < /dev/tty
   java -Xmx2048m -jar rtr.jar router $FREERTR_CONFIG/rtr-test<x>
   if [ $? -eq 4 ] ; then
     sync
     reboot -f
   fi
   stty cooked < /dev/tty
   sleep 1
   done
…

Note that in that case you also need to have rtr-test<x>-hw.txt

But  maybe mc36 have more elegant solutions in his sleeves.


Hope this helps !
Frederic

Le 26 nov. 2021 à 15:46, Carmen Misa Moreira <> a écrit :

Hi all,

I was wondering if is possible to have several control plane configurations and swap between them depending on the test that you want to execute, for example, one configuration with 3 VLANs and 1 VRF and the other without VLANs but with 2 VRF and then test different behaviours in the network just by loading one of this configurations. Two different control plane configurations with different purposes.

Thanks for your time,

Best regards,

Carmen Misa





Archive powered by MHonArc 2.6.19.

Top of Page