User Tools

Site Tools


Sidebar

playground:wiki3:magic_link

This is an old revision of the document!


Magic Link

To ease the upgrade, migration or first installation of gateways, a Magic Link feature can be used. It is a simple command based on wget that automatically downloads the required embedded software, configures the VPN connection, configures the packet forwarder with the best default configuration, all in one step.

Request

Request has to be made to customer support through support@kerlink.fr or by opening an OTRS Ticket.

A single Magic Link can be reused for as many gateways as necessary (please include them all when requesting the Magic Link from Kerlink support). It is linked to a single WMC instance.

There is a unique and secret token inside the Magic Link command or USB package. This is a secret that shouldn't be shared and transmitted in a non-secure way.

Reception

A Magic Link looks like this:

/etc/init.d/firewall stop; killall openvpn; sleep 1; wget -O- https://upgrade.wanesy.com/00112233445566778899aabbccddeeff | sh

It can either be given as is, for copy/paste, or as a ZIP package, for USB installation.

The hash (the 32-digit token in the URL above: 00112233445566778899aabbccddeeff) is secret. Be sure to safely transmit it, and avoid sharing it!

Usage

This feature requires an Internet connection throughout all the procedure.

The used connection is HTTPS to upgrade.wanesy.com (TCP port 443).

Over SSH

An SSH access to the gateway is required, this means that it shouldn't be already connected to WMC (unless for on-premises servers, in which case SSH is possible from the WMC server itself).

Just copy/paste the provided command and wait for about 5 minutes (20 minutes if Wirnet iBTS with FPGA upgrade).

Over USB

Unzip the provided package on an USB stick and plug it into the Wirnet gateway.

For Wirnet iBTS and Wirnet iFemtoCell, please remove the USB stick after 15 seconds (as soon as the LED blinks). For Wirnet Station, please leave the USB stick plugged in for 20 minutes, or until the gateway is shown as connected on the WMC instance.

Over WMC dashboard

Over WMC dashboard, you can use the magic link to update a single gateway or a group of gateways.

For WMC, it is less useful to use the Magic Link as the Software Upgrade feature can be used to send any package: new VPN package (migration), megapackage (upgrade), etc.

The advantage though, is that it's no longer required to download the megapackage from this wiki and upload it in the Software update section of the WMC. The gateway will directly download the megapackage and VPN package through the use of the Magic Link.

Use the File Explorer feature of the WMC to upload the magic link script to /tmp or /user. Then use the Remote Shell feature and type: sh /tmp/magic_link.sh

Then execute the magic link script using the remote shell feature:

Since the same command line or script can be used to update a gateway, the magic link can be used to update a whole set of gateways. That's the magic of this feature !

It exists 2 ways of using the magic in this context:

  • using the magic link command line and execute it on all the gateways,
  • using the magic link script by uploading it onto each gateway and execute it.

First, add your gateways to the Cart:

You can add as many gateways as you want.

Select the Cart icon

Select the Workflow template you want to use:

If the template CreateCommand does not exit, create it by selecting the Templates item in the Workflow menu:

Select the category: Gateways, select the CreateGatewayCommand method in the list and drag and drop it in the Selected window on the righ side of the screen:

Enter the name of your template and a short description (optional) then validate.

The new workflow template is now ready to be executed.

Return to the Cart.

  1. Copy the magic link command deliverd by the Kerlink Support team into the field command.
  2. Push the START button.
  3. Check the workflow execution in the Workflow > Running window.

  1. Wait 5-10'
  2. Check the workflow has been completed in the Workflows > Completed window:

Create 2 templates :

- CreateGatewayPutFIleCommand,
- CreateGatewayCommand.

Take care to put CreateGatewayPutFileCommand as Task #1 and CreateGatewayCommand as Task #2. Give a name to your template and select the button VALIDATE.

Go to your Cart and select your new template:

Click on the CHOOSE A FILE button and select your magic link script delivered by the Kerlink Support team:

Set the destination path to /tmp if you are using a WIrnet Station else set the value of /user for KerOS product,

Copy/Paste the magic link script filename to the command area and prefixe it with the sh /user/ command:

Select the START button.

Go to the Workflows > Running window to check the execution of the workflow:

Wait for the workflow execution to complete:

Use cases

First installation

  • over SSH: not applicable for cellular backhaul unless the gateway has a known public IP address. A DHCP server would be necessary on the LAN if Ethernet/WiFi, though static IP should work if directly connected to a computer (static IP and RJ45 cable or WiFi access from the computer to the gateway).
  • over USB: works all the time, but requires physical access.

Migration (e.g. from instance A to instance B)

  • over SSH: only applicable for on-premises instances (where SSH is available through the VPN tunnel from the WMC server itself).
  • using WMC: upload a script and execute it.
  • over USB: works all the time, but requires physical access.

Upgrade (e.g. same instance, but different embedded software version)

  • over SSH: only applicable for on-premises instances.
  • using WMC: upload a script and execute it.
  • over USB: works all the time, but requires physical access.

Specific Use cases

When may want to upgrade several gateways using the magic link. In this case, you can use the workflow feature to achieve this.

playground/wiki3/magic_link.1589562991.txt.gz · Last modified: 2020/05/15 19:16 by tda