### Boot Ubuntu installer in serial console mode Source: https://docs.flexiwan.com/6.5.1/guides/ubuntu.html Enter this command at the boot prompt to start the Ubuntu installer with serial console output. Use this if the device has a serial console and shows 'graphics initialization failed' or 'Error setting up gfxboot'. Adjust the baud rate (115200) if needed. ```bash install console=ttyS0,115200n8 vga=none ``` -------------------------------- ### Start flexiwan-router service Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'systemctl start flexiwan-router' to start the flexiWAN router service and confirm the device connects back to flexiManage after a fwkill command. ```bash systemctl start flexiwan-router ``` -------------------------------- ### Start minicom with serial setup Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Starts minicom to configure the serial port. After running, select 'Serial port setup' and change the Serial Device to /dev/ttyUSB2. ```bash minicom -s ``` -------------------------------- ### Start flexiEdge agent Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'fwagent start' to start the flexiEdge agent. This is used when troubleshooting device registration failure. ```bash fwagent start ``` -------------------------------- ### Install flexiWAN router Source: https://docs.flexiwan.com/6.5.1/guides/hetzner.html Run after adding the repository to install the flexiWAN router package. ```bash apt-get install -y flexiwan-router ``` -------------------------------- ### Start vRouter with Apply API Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Applies to a specific device to start the vRouter. The request body contains only the method 'start'. ```json {"method":"start"} ``` -------------------------------- ### Add flexiWAN repository and install flexiwan-router Source: https://docs.flexiwan.com/6.5.1/guides/manual.html Run these commands as root on Ubuntu 20.04 LTS. The first command adds the flexiWAN key to the apt-key local database and the repository to apt-get. The second installs the flexiWAN software, turning the device into a flexiEdge device. ```bash sudo curl -sL https://deb.flexiwan.com/setup | sudo bash - sudo apt-get install -y flexiwan-router ``` -------------------------------- ### Install flexiWAN and run System Checker Source: https://docs.flexiwan.com/6.5.1/guides/digitalocean.html Run this one-line command after SSHing into the Droplet to add the flexiWAN repository, install the flexiwan-router package, and run the System Checker. ```bash sudo curl -sL https://deb.flexiwan.com/setup | sudo bash - && sudo apt-get install -y flexiwan-router && sudo fwsystem_checker ``` -------------------------------- ### Install flexiWAN router on GCP VM Source: https://docs.flexiwan.com/6.5.1/guides/gcp.html Install the flexiWAN router package on the GCP VM using apt. After installation, run fwsystem_checker to prepare the VM. ```bash apt install flexiwan-router ``` -------------------------------- ### Install udp-test tool Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Install the udp-test Python package using pip3. ```bash pip3 install udp-test ``` -------------------------------- ### Get flexiAgent help Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Use 'sudo fwagent -h' to get help on the fwagent command, or 'sudo fwagent -h' for help on a specific sub-command. ```bash sudo fwagent -h sudo fwagent -h ``` -------------------------------- ### Elevate privileges and add flexiWAN repository Source: https://docs.flexiwan.com/6.5.1/guides/gcp.html Run these commands in the SSH session to elevate privileges and add the flexiWAN repository. The first command switches to root, the second downloads and runs the setup script. ```bash sudo su ``` ```bash sudo curl -sL https://deb.flexiwan.com/setup | sudo bash - ``` -------------------------------- ### Start flexiAgent Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Starts flexiAgent after a stop or if it stopped trying to register or connect. ```bash sudo fwagent start ``` -------------------------------- ### Add flexiWAN repository Source: https://docs.flexiwan.com/6.5.1/guides/hetzner.html Run as root via SSH to add the flexiWAN repository. This is the first command in the installation process. ```bash curl -sL https://deb.flexiwan.com/setup | bash - ``` -------------------------------- ### Start UDP test server on site A Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Run the udp-test server on port 4789 on site A to listen for UDP traffic. ```bash udp-test server -p 4789 ``` -------------------------------- ### Start vRouter Source: https://docs.flexiwan.com/api/nbapi.html Applies to a specific device to start the vRouter. ```json {"method":"start"} ``` -------------------------------- ### Add flexiWAN repository Source: https://docs.flexiwan.com/6.5.1/guides/oracle.html Run this command via SSH to add the flexiWAN repository to the OCI VM instance. This is the first step in the installation process. ```bash sudo curl -sL https://deb.flexiwan.com/setup | bash - ``` -------------------------------- ### Install minicom Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Installs minicom to access the modem via its serial port. Required for Quectel-specific steps. ```bash apt install minicom ``` -------------------------------- ### Add organization token file Source: https://docs.flexiwan.com/6.5.1/guides/digitalocean.html Create this file and insert your organization token from flexiManage to complete the flexiWAN setup. ```text /etc/flexiwan/agent/token.txt ``` -------------------------------- ### Install Ansible on Ubuntu 18.04 Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Install Ansible and required Python Boto libraries on Ubuntu 18.04. Run these commands before using the AWS installation script. ```bash sudo apt update sudo apt install software-properties-common sudo apt-add-repository ppa:ansible/ansible sudo apt update sudo apt install ansible python-boto3 python3-boto3 python-boto python3-boto ``` -------------------------------- ### Install Ansible on Ubuntu 21.10 or newer Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Install Ansible and the Boto library on Ubuntu 21.10 or newer. Use these commands instead of the Ubuntu 18.04 instructions. ```bash sudo apt update sudo apt install software-properties-common sudo apt-add-repository ppa:ansible/ansible sudo apt-get install python3-pip sudo pip3 install boto sudo apt install ansible ``` -------------------------------- ### Install pip3 for UDP test Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Install Python3 pip3 package manager, required for the udp-test tool. ```bash apt install python3-pip ``` -------------------------------- ### Install Ansible on Ubuntu 21.10 or newer Source: https://docs.flexiwan.com/guides/aws-installation.html Commands to install Ansible and required Python packages on Ubuntu 21.10 or newer. ```bash sudo apt update sudo apt install software-properties-common sudo apt-add-repository ppa:ansible/ansible sudo apt-get install python3-pip sudo pip3 install boto sudo apt install ansible ``` -------------------------------- ### Query subscriber ready status Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Gets mobile provider name and subscriber ready status. ```bash mbimcli --device /dev/cdc-wdm0 -p --query-subscriber-ready-status ``` -------------------------------- ### Query registration state Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Gets mobile provider registration state. ```bash mbimcli --device /dev/cdc-wdm0 -p --query-registration-state ``` -------------------------------- ### POST /devices/{id}/apply Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html The Apply API for a specific device allows dynamic integration of new device configurations. It is used to apply methods like start, stop, or upgrade to a single device. The response includes the created jobs and a Location header to track job status. ```APIDOC ## [POST] /devices/{id}/apply ### Description Apply API is added to allow dynamic integration of new device configurations. This endpoint applies to a specific device. In most cases it results with creating jobs that are sent to devices. The created jobs are returned in the response body as well as a link in the Location header to follow the created jobs status. ### Method POST ### Endpoint /devices/{id}/apply ### Parameters #### Path Parameters - **id** (string) - Required - The ID of the specific device to apply to. #### Request Body - **method** (string) - Required - The method to apply, e.g., "start", "stop", "upgrade". - **devices** (object) - Optional - A map of device IDs to boolean values indicating which devices to apply to. - **meta** (object) - Optional - Additional metadata for the method. ### Request Example {"method":"start"} ### Response #### Success Response (200) - **jobs** (array) - The created jobs that are sent to devices. - **Location header** - A link to follow the created jobs status. #### Response Example { "jobs": [] } ``` -------------------------------- ### Install Ansible on Ubuntu 18.04 Source: https://docs.flexiwan.com/guides/aws-installation.html Commands to install Ansible and required Python packages on Ubuntu 18.04. ```bash sudo apt update sudo apt install software-properties-common sudo apt-add-repository ppa:ansible/ansible sudo apt update sudo apt install ansible python-boto3 python3-boto3 python-boto python3-boto ``` -------------------------------- ### Run Ansible playbook to create AWS flexiEdge Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Run the Ansible playbook to create a flexiEdge device in AWS. This example creates a VPC in us-east-2 with the specified CIDRs, LAN IP, and token. The SSH key is saved in the directory under the stack name. ```bash ansible-playbook ec2_create_customer.yml --extra-vars "region=us-east-2 vpc_name=VPC vpc_cidr_block=172.18.0.0/16 cidr_lan=172.18.1.0/24 cidr_wan=172.18.254.0/24 lan_ip_address=172.18.1.254 flexiwan_token=ey****** stack=Ohio" ``` -------------------------------- ### Netplan configuration for static IP on eth0 Source: https://docs.flexiwan.com/6.5.1/management/device-setup.html Example netplan configuration that assigns a static IP address to eth0 and sets a default route via a gateway. This is used to provide internet connectivity when a static IP is required. ```yaml #network: version: 2 renderer: networkd ethernets: eth0: dhcp4: false addresses: - 192.168.1.122/24 routes: - to: default via: 192.168.1.1 ``` -------------------------------- ### Get mobile provider name Source: https://docs.flexiwan.com/troubleshoot/advanced.html Commands to query subscriber ready status and registration state to get mobile provider name. ```bash mbimcli --device /dev/cdc-wdm0 -p --query-subscriber-ready-status ``` ```bash mbimcli --device /dev/cdc-wdm0 -p --query-registration-state ``` -------------------------------- ### Reset flexiEdge agent with -s flag Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'fwagent reset -s' to reset the device configuration. This is used when troubleshooting device fails to start, tunnel errors, or loss of connectivity. ```bash fwagent reset -s ``` -------------------------------- ### Netplan configuration for DHCP on eth0 and eth1 Source: https://docs.flexiwan.com/6.5.1/management/device-setup.html Example netplan configuration that sets eth0 and eth1 to receive IP addresses via DHCP. This is useful when the interfaces are connected to an upstream device. The file is typically located at /etc/netplan/network.yaml. ```yaml ## This file is generated from information provided by # the datasource. Changes to it will not persist across an instance. # To disable cloud-init's network configuration capabilities, write a file # /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following: # network: {config: disabled} network: version: 2 renderer: networkd ethernets: eth0: dhcp4: true eth1: dhcp4: true ``` -------------------------------- ### Check DPDK interface binding Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'dpdk-devbind -s' to check if interfaces are assigned to DPDK. If interfaces are bound to DPDK, run 'fwagent stop' followed by 'fwagent start'. ```bash dpdk-devbind -s ``` -------------------------------- ### Stop flexiEdge agent Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'fwagent stop' to stop the flexiEdge agent. This is used when interfaces are bound to DPDK, before starting the agent again. ```bash fwagent stop ``` -------------------------------- ### Run fwsystem_checker to prepare VM Source: https://docs.flexiwan.com/6.5.1/guides/gcp.html Run the system checker to prepare the VM for flexiWAN operation. Select option 2 for quick and silent configuration, then exit with 0. ```bash fwsystem_checker ``` -------------------------------- ### List all available qmicli commands Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Lists all available qmicli commands. Note that not all commands may work or be supported. ```bash qmicli --help-all ``` -------------------------------- ### gcloud CLI command to create flexiWAN VM instance Source: https://docs.flexiwan.com/6.5.1/guides/gcp.html Use this gcloud command to deploy a VM instance named flexiwan-01 with WAN and LAN network interfaces, IP forwarding enabled, and Ubuntu 20.04 LTS boot disk. Ensure the project, zone, and service account are adjusted for your environment. ```bash gcloud compute instances create flexiwan-01 --project=flexiedgetest --zone=us-central1-a --machine-type=e2-medium --network-interface=network-tier=PREMIUM,nic-type=VIRTIO_NET,subnet=wan --network-interface=nic-type=VIRTIO_NET,subnet=lan,no-address --can-ip-forward --maintenance-policy=MIGRATE --provisioning-model=STANDARD --service-account=626012385667-compute@developer.gserviceaccount.com --scopes=https://www.googleapis.com/auth/devstorage.read_only,https://www.googleapis.com/auth/logging.write,https://www.googleapis.com/auth/monitoring.write,https://www.googleapis.com/auth/servicecontrol,https://www.googleapis.com/auth/service.management.readonly,https://www.googleapis.com/auth/trace.append --create-disk=auto-delete=yes,boot=yes,device-name=flexiwan-01,image=projects/ubuntu-os-cloud/global/images/ubuntu-2004-focal-v20231130,mode=rw,size=20,type=projects/flexiedgetest/zones/us-central1-a/diskTypes/pd-balanced --no-shielded-secure-boot --shielded-vtpm --shielded-integrity-monitoring --reservation-affinity=any ``` -------------------------------- ### Edit token file with nano Source: https://docs.flexiwan.com/6.5.1/guides/gcp.html Open the token file in nano to paste the flexiManage token. Save with CTRL+X and confirm. ```bash nano /etc/flexiwan/agent/token.txt ``` -------------------------------- ### Dump configuration and logs Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Dumps all configuration and logs for support analysis. ```bash sudo fwdump ``` -------------------------------- ### Download the Ansible script Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Download the Ansible script archive from the flexiWAN sandbox into a new 'ansible' directory. ```bash mkdir ansible cd ansible wget https://sandbox.flexiwan.com/Utils/ansible.v0.1.6.tar.gz ``` -------------------------------- ### Restart flexiwan-router service Source: https://docs.flexiwan.com/6.5.1/troubleshoot/recovery.html Run this command after saving the token in /etc/flexiwan/agent/fwagent_info.txt to restart the device control service. The device should then appear online and syncing in flexiManage. ```bash sudo systemctl restart flexiwan-router ``` -------------------------------- ### Switch Quectel modem from QMI to MBIM Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use minicom to run these AT commands on a Quectel modem to switch from QMI to MBIM mode. The first command sets the USB network mode to 2 (MBIM), and the second powers off the modem. ```at AT+QCFG="usbnet",2 ``` ```at AT+QPOWD=0 ``` -------------------------------- ### Show flexiEdge configuration from terminal Source: https://docs.flexiwan.com/6.5.1/troubleshoot/device-logs.html Run this command on the device terminal to fetch the flexiEdge configuration when the device is not connected to flexiManage. ```bash fwagent show -- configuration router ``` -------------------------------- ### Switch Quectel modem from MBIM to QMI Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use minicom to run these AT commands on a Quectel modem to switch from MBIM to QMI mode. The first command sets the USB network mode to 0 (QMI), and the second powers off the modem. ```at AT+QCFG="usbnet",0 ``` ```at AT+QPOWD=0 ``` -------------------------------- ### Verify modem responds to AT commands Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Sends AT command to verify the modem is responding. ```bash AT ``` -------------------------------- ### Default Netplan YAML file path Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Path to the default Netplan YAML file used when the vRouter is not running. ```yaml /etc/netplan/50-cloud-init.yaml ``` -------------------------------- ### VPP packet capture on baremetal Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use these commands to capture packets on a baremetal flexiEdge. Run the first command, wait 10-15 seconds, then run the third command to stop the capture. The .pcap file is saved to /tmp. ```bash vppctl pcap dispatch trace on max 1000 file vrouter.pcap buffer-trace dpdk-input 1000 ``` ```bash vppctl pcap dispatch trace off ``` -------------------------------- ### Uninstall flexiWAN with dpkg -P flexiwan-router Source: https://docs.flexiwan.com/6.5.1/guides/manual.html Run as root on the device via console or SSH. Ensure the vRouter is stopped before executing to avoid issues. ```bash dpkg -P flexiwan-router ``` -------------------------------- ### Show OSPF interfaces Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays OSPF interface information using vtysh. ```bash vtysh -c "show ip ospf interface" ``` -------------------------------- ### Quectel SIM detection verification commands Source: https://docs.flexiwan.com/troubleshoot/advanced.html Commands to verify SIM detection on Quectel modules. Expected output for AT+QUIMSLOT? is 1; if 2, follow steps 3 and 4. ```bash AT ``` ```bash AT+QUIMSLOT? ``` ```bash AT+QUIMSLOT=1 ``` ```bash AT+QPOWD=0 ``` -------------------------------- ### Show flexiAgent components version Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Displays the version of flexiAgent components. ```bash sudo fwagent version ``` -------------------------------- ### POST /devices/apply Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html The Apply API allows dynamic integration of new device configurations. It can be used to apply to multiple devices or to a specific device. The request body contains a method and optional devices and meta parameters. The response includes the created jobs and a Location header to track job status. ```APIDOC ## [POST] /devices/apply ### Description Apply API is added to allow dynamic integration of new device configurations. It can be used to apply to multiple devices or to a specific device. In most cases it results with creating jobs that are sent to devices. The created jobs are returned in the response body as well as a link in the Location header to follow the created jobs status. ### Method POST ### Endpoint /devices/apply ### Parameters #### Request Body - **method** (string) - Required - The method to apply, e.g., "tunnels", "deltunnels", "start", "stop", "upgrade". - **devices** (object) - Optional - A map of device IDs to boolean values indicating which devices to apply to. - **meta** (object) - Optional - Additional metadata for the method, e.g., pathLabels, tunnelType, topology, hub, advancedOptions. - **tunnels** (object) - Optional - For delete tunnels method, a map of tunnel IDs to boolean values. ### Request Example { "method": "tunnels", "devices": { "63054504ceb73f58528ab912": true, "63054513ceb73f58528ab988": true }, "meta": { "pathLabels": [], "tunnelType": "site-to-site", "topology": "fullMesh", "hub": "", "advancedOptions": {} } } ### Response #### Success Response (200) - **jobs** (array) - The created jobs that are sent to devices. - **Location header** - A link to follow the created jobs status. #### Response Example { "jobs": [] } ``` -------------------------------- ### Recover from Host OS upgrade boot failure Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html After a kernel panic during boot, reboot and select the previous kernel in GRUB. Then run these commands to regenerate initramfs and update GRUB, followed by a reboot. ```bash sudo update-initramfs -u -k all ``` ```bash sudo update-grub ``` ```bash reboot ``` -------------------------------- ### Show flexiEdge router configuration with fwagent Source: https://docs.flexiwan.com/troubleshoot/device-logs.html Fetch the flexiEdge configuration from the device terminal when the device is not connected to flexiManage. This command shows the router configuration. ```bash fwagent show -- configuration router ``` -------------------------------- ### Fetch logs from device terminal Source: https://docs.flexiwan.com/6.5.1/troubleshoot/device-logs.html Run this command on the device terminal to fetch the last 1000 lines of the flexiEdge agent log when the device is not connected to flexiManage. ```bash tail -1000 /var/log/flexiwan/agent.log ``` -------------------------------- ### Shut down flexiWAN and apply linux netplan Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Shuts down the flexiWAN service and restores netplan. ```bash sudo fwkill ``` -------------------------------- ### Show OSPF routes Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays OSPF route information using vtysh. ```bash vtysh -c "show ip ospf route" ``` -------------------------------- ### Enable Advanced IKEv2 Logging Source: https://docs.flexiwan.com/6.5.1/management/ipsec-peering.html Run these commands in sequence to set IKEv2 logging level, clear the event logger, and display the event logger output. After entering these commands, IKEv2/IPsec logging will be output to the device syslog, which can be fetched from flexiManage via the device Logs tab. ```shell vppctl ikev2 set logging level 5 ``` ```shell vppctl event-logger clear ``` ```shell vppctl show event-logger ``` -------------------------------- ### View IKEv2 SA Details Source: https://docs.flexiwan.com/6.5.1/management/ipsec-peering.html Use this command to view the status of peer connections from the device Command tab or shell. ```shell vppctl show ikev2 sa details ``` -------------------------------- ### SSH into the flexiEdge instance Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Connect to the newly created EC2 instance via SSH using the key saved from the stack parameter and the public IP allocated for the flexiEdge device. ```bash ssh -i Ohio -l ubuntu 13.53.107.28 ``` -------------------------------- ### Connect UDP test client from site B Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Run the udp-test client from site B to send UDP traffic to the server IP on port 4789. Replace server_IP with the remote site's IP. ```bash udp-test client -h server_IP -p 4789 -l 4789 ``` -------------------------------- ### Set SIM slot to 1 Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Sets the SIM slot to 1. Run if the previous command returned 2. ```bash AT+QUIMSLOT=1 ``` -------------------------------- ### Show BGP summary with vtysh Source: https://docs.flexiwan.com/6.5.1/management/routing.html Execute this command from the Command tab in device settings to view BGP summary and list of neighbors. ```bash vtysh -c "show bgp summary" ``` -------------------------------- ### Show BGP nexthop table Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays the BGP nexthop table using vtysh. ```bash vtysh -c "show bgp nexthop" ``` -------------------------------- ### Connect to provider network Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Sequence of commands to connect to the provider network. Replace APNNAME, USERNAME, PASS with provider info. Supported auth methods: PAP, CHAP, MSCHAPV2. ```bash mbimcli --device /dev/cdc-wdm0 -p --query-subscriber-ready-status ``` ```bash mbimcli --device /dev/cdc-wdm0 -p --query-registration-state ``` ```bash mbimcli --device /dev/cdc-wdm0 -p --attach-packet-service ``` ```bash mbimcli --device /dev/cdc-wdm0 -p --connect=apn=APNNAME,username=USERNAME,password=PASS,auth=PAP ``` -------------------------------- ### Set IKEv2 logging level to 5 Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Sets IKEv2 logging level to 5 for advanced logging. Run from Command tab or shell. ```bash vppctl ikev2 set logging level 5 ``` -------------------------------- ### Show event logger Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays the event logger output. After running the logging commands, IKEv2/IPsec logging will be output to the device syslog. ```bash vppctl show event-logger ``` -------------------------------- ### Run fwdump to collect all logs Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'sudo fwdump' from the command line to generate a compressed archive of all logs in the current folder, e.g., fwdump_devicename_20230721_152125.tar.gz. The file can be fetched using SCP or similar tools. ```bash sudo fwdump ``` -------------------------------- ### Check DHCP server status Source: https://docs.flexiwan.com/6.5.1/management/dhcp-server.html Run this command on the flexiEdge device to view DHCP requests and leases. The output shows the dhcpd log. ```bash sudo systemctl status isc-dhcp-server ``` -------------------------------- ### Reset flexiEdge registration and configuration including PPPoE Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Resets flexiEdge registration including PPPoE configuration. ```bash sudo fwagent reset -p ``` -------------------------------- ### Query IP configuration Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Queries the IP address configuration of the LTE modem. ```bash mbimcli --device /dev/cdc-wdm0 -p --query-ip-configuration ``` -------------------------------- ### Switch Sierra Wireless modem from MBIM to QMI Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use these qmicli commands to switch a Sierra Wireless LTE modem from MBIM to QMI mode. The first command sets the USB composition to 6 (QMI), then the modem is taken offline and reset. ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-swi-set-usb-composition=6 ``` ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-set-operating-mode=offline ``` ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-set-operating-mode=reset ``` -------------------------------- ### Disable flexiEdge UI with systemctl Source: https://docs.flexiwan.com/flexiEdgeUI/overview.html Disable and stop the flexiEdge UI service. Recommended only after the device is configured and running in flexiManage. ```bash systemctl disable flexiwan-router-ui ``` ```bash systemctl stop flexiwan-router-ui ``` -------------------------------- ### Switch Sierra Wireless modem from QMI to MBIM Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use these qmicli commands to switch a Sierra Wireless LTE modem from QMI to MBIM mode. The first command sets the USB composition to 8 (MBIM), then the modem is taken offline and reset. ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-swi-set-usb-composition=8 ``` ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-set-operating-mode=offline ``` ```bash qmicli --device=/dev/cdc-wdm0 --device-open-proxy --dms-set-operating-mode=reset ``` -------------------------------- ### View PPPoE DNS servers Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use this command to view DNS servers used by PPPoE connection. Run via shell only. Output shows DNS IPs for all interfaces; look for the one with PPP in the name (e.g., ppp-eth0). ```bash systemd-resolve --status ``` -------------------------------- ### VPP packet capture on VMware Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use these commands to capture packets on a VMware flexiEdge. Run the first command, wait 10-15 seconds, then run the third command to stop the capture. The .pcap file is saved to /tmp. ```bash vppctl pcap dispatch trace on max 10000 file vrouter.pcap buffer-trace vmxnet3-input 1000 ``` ```bash vppctl pcap dispatch trace off ``` -------------------------------- ### List interfaces with ACL index values Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use this command to list interfaces with their ACL index values. The output is used with the next command to view ACL rules. ```bash vppctl show acl-plugin interface ``` -------------------------------- ### Set advanced options for tunnel creation Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Shows how to set cost and other advanced parameters in the 'advancedOptions' object of the tunnel creation request. Includes mtu, mssClamp, ospfCost, and routing. ```json "advancedOptions": { "mtu": "1500", "mssClamp": "yes", "ospfCost": "100", "routing": "ospf" } ``` -------------------------------- ### Check PCI interfaces Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'lspci -vnn' to check the existence of PCI interfaces. If no PCI interfaces are available, the network adaptor must be modified to be PCI based. ```bash lspci -vnn ``` -------------------------------- ### Show current FRR configuration Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays the current FRR running configuration using vtysh. ```bash vtysh -c "show running-config" ``` -------------------------------- ### Open flexiEdge agent configuration file Source: https://docs.flexiwan.com/6.5.1/troubleshoot/device-logs.html Open this configuration file to disable debug mode by setting the debug option to false. ```yaml /etc/flexiwan/agent/fwagent_conf.yaml ``` -------------------------------- ### Kill flexiWAN router service Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'fwkill' as root to stop the flexiWAN router service and restore the default netplan. This is used when troubleshooting loss of connectivity. ```bash fwkill ``` -------------------------------- ### Upgrade devices with Apply API Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Upgrades the software version for two devices. The request body specifies the method 'upgrade' and the devices to upgrade. ```json {"method":"upgrade","devices":{"5e4c1fee3fce30225c612ee8":true,"5e4c2a8b3fce30225c613071":true}} ``` -------------------------------- ### Show ACL details by index Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use vppctl show acl-plugin acl index to display the access control list for a specific ACL index. Replace with the index from the previous command's output. ```bash vppctl show acl-plugin acl index ``` -------------------------------- ### Restart flexiAgent service Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Restarts the flexiAgent service using systemctl. ```bash sudo systemctl restart flexiwan-router ``` -------------------------------- ### Reset flexiEdge configuration only Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Resets flexiEdge configuration only. ```bash sudo fwagent reset -s ``` -------------------------------- ### View DHCP server configuration file Source: https://docs.flexiwan.com/6.5.1/management/dhcp-server.html The DHCP server configuration is stored in /etc/dhcp/dhcpd.conf on the flexiEdge device. ```plaintext /etc/dhcp/dhcpd.conf ``` -------------------------------- ### Show SIM card status Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Shows SIM card status. The output for 'Card state' should be 'present'. ```bash qmicli --device=/dev/cdc-wdm0 -p --uim-get-card-status ``` -------------------------------- ### Check agent log for errors Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Use 'tail -100 /var/log/flexiwan/agent.log' to view the last 100 lines of the flexiEdge agent log and verify if any errors are reported. This command is used in multiple troubleshooting scenarios. ```bash tail -100 /var/log/flexiwan/agent.log ``` -------------------------------- ### Export AWS credentials Source: https://docs.flexiwan.com/guides/aws-installation.html Commands to set the AWS_ACCESS_KEY and AWS_SECRET_ACCESS_KEY environment variables. ```bash export AWS_ACCESS_KEY=********************** export AWS_SECRET_ACCESS_KEY=*********************************************** ``` -------------------------------- ### List LTE modem device names Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Lists device names for LTE modems. Output shows /dev/cdc-wdm0 or a list with numbering like cdc-wdm0, cdc-wdm1, etc. ```bash ls -l /dev/cdc-* ``` -------------------------------- ### Restart modem Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Restarts the modem. After restart, re-try step 2 (AT+QUIMSLOT?). ```bash AT+QPOWD=0 ``` -------------------------------- ### View NAT sessions and ACL rules Source: https://docs.flexiwan.com/troubleshoot/advanced.html Commands to view current WAN NAT sessions and list interfaces with ACL index values, then view allowed/blocked per ACL rule. Use the interface index from the second command in the third. ```bash vppctl show nat44 sessions ``` ```bash vppctl show acl-plugin interface ``` ```bash vppctl show acl-plugin acl ``` -------------------------------- ### Capture OSPF packets using tcpdump on flexiEdge Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Captures 10 OSPF packets on a specified Linux interface. Replace with the actual interface name. ```bash tcpdump -n -v -s0 -c 10 -i :nnnp proto ospf - capture 10 ospf packets ``` -------------------------------- ### Show learned OSPF neighbors Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays OSPF neighbor information using vtysh. ```bash vtysh -c "show ip ospf neighbor" ``` -------------------------------- ### Upgrade devices Source: https://docs.flexiwan.com/api/nbapi.html Upgrades the software version for two devices. ```json {"method":"upgrade","devices":{"5e4c1fee3fce30225c612ee8":true,"5e4c2a8b3fce30225c613071":true}} ``` -------------------------------- ### Switch SIM slots or change SIM card Source: https://docs.flexiwan.com/troubleshoot/advanced.html Commands to power off and on the SIM slot when switching slots or changing SIM card. ```bash qmicli --device=/dev/cdc-wdm0 -p --uim-sim-power-off=1 ``` ```bash qmicli --device=/dev/cdc-wdm0 -p --uim-sim-power-on=1 ``` -------------------------------- ### Access flexiEdge UI via HTTP URL Source: https://docs.flexiwan.com/6.5.1/flexiEdgeUI/overview.html Access the flexiEdge UI by entering the device IP and port 8080 in a web browser. The device must have an active network interface. ```text HTTP://192.168.100.10:8080/ ``` -------------------------------- ### Check policy matching with VPP CLI Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use vppctl show fwabf policy to check if LAN outgoing traffic matches the configured policy. The output shows counters: matched, applied, fallback, dropped, and acl index. ```bash vppctl show fwabf policy ``` -------------------------------- ### Unzip the tar.gz Source: https://docs.flexiwan.com/guides/aws-installation.html Commands to extract the downloaded Ansible script and change into the extracted directory. ```bash tar -vxf ansible.v0.1.6.tar.gz cd ansible.v0.1.4/ ``` -------------------------------- ### Commonly used VPP CLI commands Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html List of frequently used vppctl commands for inspecting interfaces, hardware, IP addresses, FIB, and ARP tables. ```bash vppctl show int ``` ```bash vppctl show hard ``` ```bash vppctl show ip addr ``` ```bash vppctl show ip fib ``` ```bash vppctl arp ``` ```bash vppctl show ip arp ``` -------------------------------- ### Check if OSPF process is running Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use this command to verify that the OSPF process is running on the system. ```bash ps -ef | grep ospf ``` -------------------------------- ### Display number of prefixes for all afi/safi Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays the number of prefixes for all address families and subsequent address families using vtysh. ```bash vtysh -c "statistics-all" ``` -------------------------------- ### Create tunnels with Apply API (no path labels) Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Calls the devices apply API to create a tunnel between two devices without path labels. The request body specifies the method 'tunnels', the devices involved, and meta parameters including tunnelType, topology, hub, and advancedOptions. ```json { "method": "tunnels", "devices": { "63054504ceb73f58528ab912": true, "63054513ceb73f58528ab988": true }, "meta": { "pathLabels": [], "tunnelType": "site-to-site", "topology": "fullMesh", "hub": "", "advancedOptions": {} } } ``` -------------------------------- ### View allowed/blocked per ACL rule Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use this command to view allowed or blocked traffic per ACL rule. Replace with the interface index from the previous command. ```bash vppctl show acl-plugin acl ``` -------------------------------- ### Restrict access to flexiEdge UI with iptables Source: https://docs.flexiwan.com/flexiEdgeUI/overview.html Use this iptables command to allow only a specific IP (1.2.3.4) to access port 8080, blocking all others. Replace 1.2.3.4 with the allowed IP; use /24 for a whole range. Save rules to persist across reboots. ```bash /sbin/iptables -A INPUT -p tcp ! -s 1.2.3.4 --dport 8080 -j DROP ``` -------------------------------- ### View current WAN NAT sessions Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Use this command to display current WAN NAT sessions. ```bash vppctl show nat44 sessions ``` -------------------------------- ### Power on SIM slot Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Powers on the SIM slot. Run after powering off when switching SIM slots or changing SIM card. ```bash qmicli --device=/dev/cdc-wdm0 -p --uim-sim-power-on=1 ``` -------------------------------- ### Show global BGP memory statistics Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays global BGP memory statistics using vtysh. ```bash vtysh -c "show bgp memory" ``` -------------------------------- ### Create tunnels Source: https://docs.flexiwan.com/api/nbapi.html Creates tunnels between multiple devices by invoking the Apply API. The request body specifies the method 'tunnels' and includes device IDs and optional meta parameters. ```APIDOC ## [POST] /devices/apply ### Description Creates tunnels between multiple devices using the Apply API. ### Method POST ### Endpoint https://manage.flexiwan.com/api-docs/#/Devices/devicesApplyPOST ### Parameters #### Request Body - **method** (string) - Required - Set to "tunnels" to create tunnels. - **devices** (object) - Required - Object mapping device IDs to boolean values indicating whether to include each device. - **meta** (object) - Required - Object containing tunnel configuration options. - **pathLabels** (array of strings) - Optional - List of path label IDs to apply to the tunnels. - **tunnelType** (string) - Optional - Type of tunnel, e.g., "site-to-site". - **topology** (string) - Optional - Topology type, e.g., "fullMesh". - **hub** (string) - Optional - Hub device ID for hub-and-spoke topology. - **advancedOptions** (object) - Optional - Advanced options such as MTU, MSS clamping, OSPF cost, and routing. - **mtu** (string) - Optional - Maximum transmission unit size. - **mssClamp** (string) - Optional - MSS clamping setting. - **ospfCost** (string) - Optional - OSPF cost value. - **routing** (string) - Optional - Routing protocol, e.g., "ospf". ### Request Example ```json { "method": "tunnels", "devices": { "63054504ceb73f58528ab912": true, "63054513ceb73f58528ab988": true }, "meta": { "pathLabels": [], "tunnelType": "site-to-site", "topology": "fullMesh", "hub": "", "advancedOptions": {} } } ``` ### Response #### Success Response (200) The response contains created jobs that are sent to the devices. The response body includes the created jobs and a link in the Location header to follow the job status. #### Response Example (No explicit example provided in the source documentation.) ``` -------------------------------- ### Export AWS credentials Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Set the AWS access key and secret access key environment variables required by the Ansible script. Replace the asterisks with your actual keys from the IAM console. ```bash export AWS_ACCESS_KEY=********************** export AWS_SECRET_ACCESS_KEY=*********************************************** ``` -------------------------------- ### Show BGP VRFs Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Displays BGP VRF information using vtysh. ```bash vtysh -c "vrfs" ``` -------------------------------- ### Reset flexiEdge agent Source: https://docs.flexiwan.com/6.5.1/troubleshoot/overview.html Run 'fwagent reset' to reset the flexiEdge agent. This is used when troubleshooting device registration failure or to re-add the device and configure from scratch. ```bash fwagent reset ``` -------------------------------- ### Reset flexiEdge registration and configuration Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Resets flexiEdge registration without resetting PPPoE configuration, which persists after reset. Make sure to delete the device from flexiManage when running this command and reset the agent service. ```bash sudo fwagent reset ``` -------------------------------- ### Add path labels to tunnel creation Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Shows how to add path label IDs to the 'pathLabels' list in the tunnel creation request. This is used when you want to specify path labels for the tunnel. ```json "pathLabels": [ "5e8f465d622b105449e60828" ], ``` -------------------------------- ### Force vRouter stop Source: https://docs.flexiwan.com/6.5.1/troubleshoot/agent-service.html Stops the vRouter and recovers the original system interfaces. ```bash sudo fwagent stop ``` -------------------------------- ### Extract the Ansible script archive Source: https://docs.flexiwan.com/6.5.1/guides/aws-installation.html Extract the downloaded archive and change into the extracted directory. Note the directory name in the source is 'ansible.v0.1.4/' even though the archive is v0.1.6. ```bash tar -vxf ansible.v0.1.6.tar.gz cd ansible.v0.1.4/ ``` -------------------------------- ### Stop vRouter with Apply API Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Applies to a specific device to stop the vRouter. The request body contains only the method 'stop'. ```json {"method":"stop"} ``` -------------------------------- ### Disable Connection Recovery in fwagent_conf.yaml Source: https://docs.flexiwan.com/6.5.1/troubleshoot/connection-recovery.html Configuration snippet to disable Connection Recovery in the FlexiWAN agent. Set 'deadlock.enabled' and 'connection.enabled' to false to stop the recovery process. Set 'router_cfg_window' to 0 to disable the configuration check. After editing, restart the device or run 'systemctl restart flexiwan-router'. ```yaml watchdog: deadlock: enabled: true # Change to false stops the thread recovery connection: enabled: true # Change to false stops the recovery process router_cfg_window: 240 # Change to 0 disables the configuration check to prevent mistakenly stopping the router ``` -------------------------------- ### Disconnect from provider network Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Disconnects the LTE modem from the provider network. ```bash mbimcli --device /dev/cdc-wdm0 -p --disconnect=0 ``` -------------------------------- ### Power off SIM slot Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Powers off the SIM slot. Run when switching SIM slots or changing SIM card. ```bash qmicli --device=/dev/cdc-wdm0 -p --uim-sim-power-off=1 ``` -------------------------------- ### Check SIM slot number Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Checks the current SIM slot. Expected output is 1. If the value is 2, follow the next steps. ```bash AT+QUIMSLOT? ``` -------------------------------- ### Clear event logger Source: https://docs.flexiwan.com/6.5.1/troubleshoot/advanced.html Clears the event logger before enabling IKEv2/IPsec logging. ```bash vppctl event-logger clear ``` -------------------------------- ### Stop vRouter Source: https://docs.flexiwan.com/api/nbapi.html Applies to a specific device to stop the vRouter. ```json {"method":"stop"} ``` -------------------------------- ### Delete tunnels with Apply API Source: https://docs.flexiwan.com/6.5.1/api/nbapi.html Calls the devices apply API to delete a tunnel by ID. The request body specifies the method 'deltunnels' and the tunnel ID to delete. ```json {"method":"deltunnels","tunnels":{"5e4c2aba71b763362c099fb2":true}} ``` -------------------------------- ### Delete tunnels Source: https://docs.flexiwan.com/api/nbapi.html Deletes tunnels by their IDs using the Apply API. The request body specifies the method 'deltunnels' and a map of tunnel IDs. ```APIDOC ## [POST] /devices/apply ### Description Deletes tunnels by their IDs using the Apply API. ### Method POST ### Endpoint https://manage.flexiwan.com/api-docs/#/Devices/devicesApplyPOST ### Parameters #### Request Body - **method** (string) - Required - Set to "deltunnels" to delete tunnels. - **tunnels** (object) - Required - Object mapping tunnel IDs to boolean values indicating whether to delete each tunnel. ### Request Example ```json {"method":"deltunnels","tunnels":{"5e4c2aba71b763362c099fb2":true}} ``` ### Response #### Success Response (200) The response contains created jobs that are sent to the devices. The response body includes the created jobs and a link in the Location header to follow the job status. #### Response Example (No explicit example provided in the source documentation.) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.