How to install Ubuntu Server on your Raspberry Pi

after some debugging, hdmi “work”. it does on for a half second, than blank for 2 second …

Yes it does. But it would be great if the tutorial say it :slight_smile: I just did what the tutorial say, and get an error message

2 posts were split to a new topic: Pi Wifi Help

The example provided:

wifis:
  wlan0:
  dhcp4: true
  optional: true
  access-points:
    <wifi network name>:
      password: "<wifi password>"

Did not work on my fresh install of 20.04.2 server. Fortunately what was provided at netplan.io worked fine:

wifis:
    wlan0:
        dhcp4: true
        access-points:
            "wifi network name":
                password: "wifi password"
1 Like

The arp -a command does not return any information on Ubuntu 20.04.

A suggestion is to include the following command:

$ sudo apt-get install arp-scan

$ sudo arp-scan --interface=enp0s3 --localnet
Interface: enp0s3, type: EN10MB, MAC: 08:00:27:xxxx:xx, IPv4: 192.168.0.226
Starting arp-scan 1.9.7 with 256 hosts (https://github.com/royhills/arp-scan)
...
192.168.0.249	dc:a6:32:xx:xx:xx	Raspberry Pi Trading Ltd

The indention is the problem:

  network:
  version: 2
  ethernets:
    eth0:
      dhcp4: true
      optional: true
  wifis:
    wlan0:
      optional: true
      dhcp4: true
      access-points:
        "WIFI_123":
          password: "WIFI_123_PW"

After the indention is correct you are able to restart the networkings service with

sudo netplan apply

It seems to be that the structure and indention of the file network-config is destroyed while import.

1 Like

2 posts were split to a new topic: Wouldn’t it be super awesome if we just had something that prompted for the information and programmatically created the file (maybe even with hashed passwords)?

Followed the steps without much trouble. installed xubuntu but it didn’t load automatically. Any assistance would be appreciated!

Updates for the original post/article on Preparing the SD card imager download links from https://www.raspberrypi.org/software/

windows  https://downloads.raspberrypi.org/imager/imager_latest.exe
macos  https://downloads.raspberrypi.org/imager/imager_latest.dmg
ubuntu x86  https://downloads.raspberrypi.org/imager/imager_latest_amd64.deb

To install on Raspberry Pi OS, type `sudo apt install rpi-imager` in a Terminal window.
1 Like

or just

sudo snap install rpi-imager

on any linux that has snap support enabled …

1 Like

Have you had any luck in finding a solution?

My router doesn’t allow me to assign static ip addresses to my devices.

Installed server and xubuntu-desktop without issue, however the wifi manager does not work. I am still connected to my wifi though. I am guessing because it is “hard wired” per the instructions for getting wifi to work pre desktop install.
How do I undo the hard wire and let the network manager manage my wifi?
Suggest this be added to the instructions.

Good tutorial, but I could never get Wifi to work by editing the config file before first boot. And even the ethernet was a pain. Probably add that one may have to run sudo dhclient eth0 in order to bring the ethernet up, that’s what I had to do in order to get a connection. Very frustrating setup process, haha. Perhaps add the commands to use NetworkManger cli to add a wifi network if you missed the first boot or its not working with the initial boot config file.

1 Like

May I suggest an example of editing the network-config file to give the server a static IP address. Then you don’t need to do all the hunting in arp for the address

A working example:

ethernets:
  eth0:
    addresses:
      - 192.168.101.212/24
    gateway4: 192.168.101.1
    nameservers:
      addresses: [192.168.101.253]
1 Like

Hey Francis o/ - Good idea, would you mind suggesting exactly how you would amend the current tutorial? Then I can publish your suggestion? (We’re working on a better way for helpful folks like you to more easily contribute your ideas) :blush:

1 Like

In section 3 (https://ubuntu.com/tutorials/how-to-install-ubuntu-on-your-raspberry-pi#3-wifi-or-ethernet):

If you want to use your local lan’s DHCP server to get an IP address for your pi then there are two ways to get your Pi connected to the internet:

  • The first is to connect your Pi to your router with an ethernet cable. In this case, you can skip this step and go to the next one in the tutorial.

  • The second requires a local Wi-Fi network that both your computer and Pi can be connected to. We are going to edit files you just downloaded on your SD card to ensure your Pi can connect to the Wi-Fi network at boot.

If you want to have the pi boot the pi to known IP address then see the section “Set a Static IP” below Wifi where you will edit the same file that the Wifi section tells you to modify


Then Section
Set A Static IP

To set a static IP you need to replace the
dhcp4: true
line in the network-config file with lines that specify the intended IP address of the pi as well as its default gateway and DNS server. You can do this for either the eth0 or wlan0 interface (or both). It is important that you get the indenting right for this work correctly

For example if you were planning to give the pi the address 192.168.1.23 in the 192.168.1.0/24 subnet with a default gateway of 192.168.1.1 and a DNS server of 192.168.1.53 then the following text would work.

    addresses:
      - 192.168.1.23/24
    gateway4: 192.168.1.1
    nameservers:
      addresses: [192.168.1.53]
1 Like

Wonderful, cheers @francis-turner :blush:

1 Like

You should probably post the whole section starting at ethernets. I just tried my instructions and got the indenting wrong and thus no network.
ethernets:
eth0:
addresses:
- 192.168.101.212/24
gateway4: 192.168.101.1
nameservers:
addresses: [192.168.101.253]
optional: true

Gaaah. can’t get the indent to display in the comment. See my original comment whihc has it right

1 Like

put triple backticks ``` above and below the pasted text to keep your indendation intact …

2 Likes

Maybe you could tell your users up front that headless will not work for WiFi – at least until you get that fixed?
Saying at the beginning that a headless installation is possible, then saying “it won’t work the first time, just type ‘sudo reboot’ and it will work the second time” sounds like a bad practical joke. Headless means no monitor and no keyboard, so one cannot “just type sudo reboot”. I’ve just wasted a couple hours of my time and I’m less than happy. I would prefer you not make other users unhappy.

1 Like