Originally created for my friend Vibhor. If someone stumbles across this and finds it useful, cheers!
This guide will walk you through the steps to install the latest version of Ubuntu on a new PC using a USB stick, connect to Wi-Fi, and enable SSH access for remote users.
What You'll Need
- A USB stick (at least 8 GB)
- A working computer to create the bootable USB
- An internet connection
- The target PC for installation
Steps to Install Ubuntu
1. Download Ubuntu
- Visit the official Ubuntu website
- Click "Download Ubuntu Desktop" and select the latest version
- Save the
.iso
file to your computer
2. Create a Bootable USB
-
Insert the USB stick into your working computer
-
Use one of the following tools to create a bootable USB:
- Windows: Use Rufus
- macOS/Linux: Use balenaEtcher
-
Steps for Creating the USB:
- Using Rufus (Windows):
- Open Rufus and select your USB device
- Click "Select" and choose the Ubuntu
.iso
file - Use default settings and click "Start"
- Using balenaEtcher (macOS/Linux):
- Open Etcher, select the Ubuntu
.iso
, choose the USB stick, and click "Flash"
- Open Etcher, select the Ubuntu
- Using Rufus (Windows):
-
Wait for the process to complete and safely eject the USB
3. Boot the Target PC from USB
-
Insert the bootable USB stick into the target PC
-
Power on the PC and enter the BIOS/UEFI settings:
- Typically accessed by pressing
F2
,F12
,DEL
, orESC
during startup - Refer to your PC's manual if unsure
- Typically accessed by pressing
-
Set the USB as the Boot Device:
- Navigate to the "Boot Order" or "Boot Options" menu
- Move the USB stick to the top of the boot priority list
- Save changes and exit
-
Restart the PC, and it will boot from the USB stick
4. Start Ubuntu Installation
- After booting, you'll see the Ubuntu boot menu
- Select "Try or Install Ubuntu" and press Enter
5. Connect to Wi-Fi
- On the Ubuntu installer screen, click the Wi-Fi icon in the top-right corner
- Select your Wi-Fi network from the list
- Enter the password and click "Connect"
- Ensure the PC is connected to the internet before proceeding
6. Install Ubuntu
- Language Selection: Choose your preferred language and click "Install Ubuntu"
- Keyboard Layout: Select your keyboard layout and click "Continue"
- Updates and Software:
- Choose to install updates and third-party software (recommended)
- Click "Continue"
- Installation Type:
- For a fresh PC, select "Erase disk and install Ubuntu"
- For advanced users, choose "Something else" to customize partitions
- Confirm Changes: Review the partition setup and click "Install Now". Confirm if prompted
- Set Your Time Zone: Select your region on the map
- Create a User Account:
- Enter your name, computer name, username, and password
- Choose whether to log in automatically or require a password
- Installation: Wait for the installation to complete (10–20 minutes)
- Restart: Remove the USB stick when prompted and press Enter to restart
Post-Installation Setup
1. Connect to Wi-Fi (if needed)
- After booting into Ubuntu, click the Wi-Fi icon in the top-right corner
- Select your network, enter the password, and connect
2. Update the System
Open the terminal (Ctrl + Alt + T
) and run:
sudo apt update && sudo apt upgrade -y
3. Install and Configure SSH
- Install SSH Server:
sudo apt install openssh-server -y
- Verify SSH Service:
sudo systemctl status ssh
If it's not running, start it:
sudo systemctl start ssh
- Enable SSH on Boot:
sudo systemctl enable ssh
4. Find the PC's Public IP Address
Open the terminal and run:
curl ifconfig.me
Note: This public IP address is required for remote SSH access.
5. Configure Router for Port Forwarding
- Log in to your router's admin panel (usually 192.168.x.x or 192.168.1.1)
- Locate the Port Forwarding section
- Forward port 22 to your PC's local IP address:
- Find your local IP with:
ip addr
- Look under inet for your Wi-Fi interface
- Save the changes
6. Secure SSH
-
Enable Password Authentication (default method):
- Open the SSH configuration file:
sudo nano /etc/ssh/sshd_config
- Find and modify these lines:
PasswordAuthentication yes ChallengeResponseAuthentication yes
- Save the file (
Ctrl + O
, thenEnter
, thenCtrl + X
) and restart SSH:
sudo systemctl restart ssh
-
Change Default SSH Port (optional extra security):
sudo nano /etc/ssh/sshd_config
-
Find the line
#Port 22
and change it to a custom port, e.g.,Port 2222
-
Save the file (
Ctrl + O
, thenEnter
, thenCtrl + X
) and restart SSH:
sudo systemctl restart ssh
-
7. Connect Remotely via SSH
- From the remote machine, connect to your Ubuntu PC:
ssh username@your-public-ip
- If you changed the SSH port, specify it:
ssh -p 2222 username@your-public-ip
- When prompted, enter your Ubuntu user account password
Your PC is Ready
Congratulations! You've successfully installed Ubuntu, connected to Wi-Fi, and enabled SSH access for remote users.
PS. Huge thanks broda, I owe you one 🫶