A Rasp Pi wireless access point
Wide Reach

© Lead Image © lightwise, 123RF.com
Set up a wireless access point with a Raspberry Pi 3, Ubuntu Core, and snaps.
Router coverage gaps often have different causes, which repeaters and access points (APs) can remedy. A repeater usually connects to the router over WiFi and amplifies the signal into areas where the router alone is not sufficient, whereas an AP wired to the router by cable sets up a private WiFi network with its own network identifier (SSID). The AP therefore provides additional access to the local network.
A highly portable Raspberry Pi is ideal for setting up a small and cheap WiFi AP suitable for many applications. For example, you could stretch a network into the back garden or provide Internet to an awkwardly located conference room.
The easiest route is to use a Raspberry Pi 3 (RPi3), which already has a WiFi module. Previous models can be prepared for the new task with a dongle, available for just a few dollars. Even the Rasp Pi 3 could benefit from a WiFi stick, because the internal connections of the installed module do not deliver the performance of a good dongle.
In this article, you'll see how to set up a wireless AP, and then I will show you how to provide an additional entry into your local area network through the integration of Nextcloud on an external disk connected to the Rasp Pi.
Good Choice
Not all WiFi sticks work with the Rasp Pi, and those that do work often cannot be used without loading an additional driver. The Edimax and TP-LINK WN725N models are well known to be problem-free on a Pi. Whichever dongle you choose, make sure it supports AP mode. A detailed list of supported dongles, including their properties, can be found on the Embedded Linux wiki [1].
Many of the listed models are powered by the Rasp Pi USB socket. Because the dongle's power consumption depends on its load, among other things, you would be more secure when working with larger amounts of data or numerous accesses by connecting the WiFi stick to an active USB hub.
In the example here, the AP is based on Ubuntu Core. If you want to follow the steps here, you need an operational Rasp Pi connected to the router by Ethernet and reachable via WiFi.
An Account with an Advantage
If you don't already have an Ubuntu One account, you'll need to sign up [2]. This step is important for security, as demonstrated later. After logging in, select the SSH keys item and upload a public key, which you will need for an SSH connection to Ubuntu Core. If necessary, create a new SSH key as root with the command:
ssh-keygen -t rsa -b 4096
In the meantime, download the Ubuntu Core image [3]. After unpacking the archive, it expands from slightly more than 300MB to nearly 600MB of disk space.
Ubuntu Core was chosen because it is compact and doesn't have a graphical interface, which would be superfluous on an AP. The system includes the kernel and bootloader from Ubuntu's alternative Snap package system [4] and updates itself. If something goes wrong when updating, the system can be restored automatically or manually to a previous state [5].
Automatic Updates
Automatic updates, especially, are worth their weight in gold, because an AP works quietly in the background, and you could easily forget to update it. Therefore, take the safe and maintenance-free approach, which also allows integration of other Snap applications (e.g., a UPnP media server or openHAB home automation software).
Creating a WiFi hotspot is quick and easy. Start by moving the Ubuntu Core images onto an SD card:
$ xzcat <image file> | sudo dd of=<device file> bs=8M
Use the correct name for the image file and enter the identifier of the device file according to your local setup. To find the correct name of your block device, enter the
lsblk -l
command. Next, insert the SD card into the appropriate slot on the Rasp Pi and connect the Ethernet cable, monitor, keyboard, and power supply. Shortly after powering on, the computer will prompt you to press the Enter key to start the installation, which could take several minutes.
To continue, configure eth0
as the default device. Working over WiFi at this point is not possible, because of an error in the installer. The system then prompts you to enter the email address of your Ubuntu account. If you're using a keyboard with an AltGr key, note that it is not implemented correctly, so if you need to use it, type the Alt sequence for the required character with the Num Lock key activated [6] (e.g., Alt+6-4 for the @ symbol).
After the software has checked the account, you will receive an SSH address to connect to Ubuntu Core. From this point, you can do without the screen and keyboard on the Rasp Pi; just log in from a PC with the specified SSH address (Figure 1).
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you've found an article to be beneficial.
News
-
The GNU Project Celebrates Its 40th Birthday
September 27 marks the 40th anniversary of the GNU Project, and it was celebrated with a hacker meeting in Biel/Bienne, Switzerland.
-
Linux Kernel Reducing Long-Term Support
LTS support for the Linux kernel is about to undergo some serious changes that will have a considerable impact on the future.
-
Fedora 39 Beta Now Available for Testing
For fans and users of Fedora Linux, the first beta of release 39 is now available, which is a minor upgrade but does include GNOME 45.
-
Fedora Linux 40 to Drop X11 for KDE Plasma
When Fedora 40 arrives in 2024, there will be a few big changes coming, especially for the KDE Plasma option.
-
Real-Time Ubuntu Available in AWS Marketplace
Anyone looking for a Linux distribution for real-time processing could do a whole lot worse than Real-Time Ubuntu.
-
KSMBD Finally Reaches a Stable State
For those who've been looking forward to the first release of KSMBD, after two years it's no longer considered experimental.
-
Nitrux 3.0.0 Has Been Released
The latest version of Nitrux brings plenty of innovation and fresh apps to the table.
-
Linux From Scratch 12.0 Now Available
If you're looking to roll your own Linux distribution, the latest version of Linux From Scratch is now available with plenty of updates.
-
Linux Kernel 6.5 Has Been Released
The newest Linux kernel, version 6.5, now includes initial support for two very exciting features.
-
UbuntuDDE 23.04 Now Available
A new version of the UbuntuDDE remix has finally arrived with all the updates from the Deepin desktop and everything that comes with the Ubuntu 23.04 base.