How to Turn Raspberry Pi into Travel Router with VPN

Is there anyone who knows about how to turn Raspberry Pi into travel router with VPN. I am facing some issues in this. Help me.
  • Cyrus

  • 1


  • 10 months ago

Answer Link
Answer - 1

Turn Raspberry Pi into Travel Router with VPN:

A person is forced to connect to a public Wi-Fi network to get access to the internet on the go.  In such a case you must use travel routers to stay connected to the internet.

In case you don't have a travel router with you, then you can build a router with Raspberry PI. This is one of the best traveling homemade VPN routers. 

Steps to Convert Raspberry Pi into a Travel Router with VPN

Step 1: Install OpenWRT

In the first step, you are required to download the OpenWRT firmware for your Raspberry Pi firmware. Go to the open WRT wiki page and find the latest images from there. Use 7zip or any other extraction software to unzip your downloaded file.

After that, flash the IMG file to the card. After that, the tool will detect the SD card. After that, select your image file, correct drive, and then select Flash. Once you are done, keep the microSD memory card into the Raspberry Pi and allow it to boot. 

Step 2: Initial Configuration

Open WRT has a static IP address by default. You are required to change this to prevent the conflict risk. Connect your Raspberry Pi to PC using an ethernet cable. After that, you are required t set the static IP on your computer. 

Rather than processing the LuCi configuration, you need to do it manually to make sure that the configuration is set properly. Load SSH or PuTty client and connect it to by root username.  You will get a security warning on the first connection. Select Yes to continue.

You can also set a password is you want. You can do this by typing a password i the terminal window. To configure firewall and network settings, you need to edit two files i.e., /etc / config / network and etc / config / firewall.

Enter the command vim /etc/config/network to edit the file. If you wish to add some items or edit text, then press I. Once you are done, press the Esc key and type: qw to save and exit. After that, go to the firewall configuration file vim/etc/config/ firewall. Select I to edit and find a region.

Step 3: Update the Package and Install It

Now, you need to update OpenWRT. For this, you need an initial setup and internal Wi-Fi function of Pi. This will help you connect to the present Wi-Fi network. Also, you are required to change the static IP address to to enable the connection. 

Once you are done connecting the IP address of the Raspberry Pi into the browser to open the administration console of OpenWRT. Enter the username and password to obtain access. After that, go to Network and then select Wireless. Search for the Wi-Fi network by clicking on Scan. Once you find the network, select Join Network. Then, enter WPA Passphrase and click on Submit. 

After that, you will see Wi-Fi connection settings. Go to the section of Advanced Settings and then set the Country Code to match the present location. Reconnect to Pi using the new IP address through SSH. Moreover, you need to update the device by typing okpg update. Follow and then click on Y when asked. After installing the updates, you need to install the USB driver. 

Step 4: Set up Your Wireless Router

One can easily set up a Wi-Fi connection if USB Wi-Fi adapter is connected. Return to the LuCi control Panel under the wireless sections and then delete both the network connections. Radio 1 is USB Wi-Fi adapter and Radio0 is integrated Wi-Fi. Click on Add and then set up Wi-Fi integration.

Also, you need to check the following settings. 

  • Network is set to LAN
  • An appropriate password is set
  • Make sure encryption is set to WPA2-PSK under Wireless Security. 
  • Access Point mode  is set

When done, select Save to go back to the wireless menu. carry out the instructions mentioned above for setting the radio 1 device as the initial connection. You also need these details for scanning and changing the network in a new location. 

  • Published by:  Mark   
  •  10 months ago