If you’ve just spun up a fresh Ubuntu 14.04 server and you’re staring at a lonely SSH prompt, it’s pretty normal to feel stuck.
Before: nothing is installed, no website, no web server, you’re not even sure what your public IP is.
After: Apache is running, you can hit your server IP in a browser and see the default Ubuntu test page, and you know where to go next.
This guide walks you through that “after” part: getting a basic LAMP stack started on Ubuntu 14.04 by installing Apache and checking that it’s working.
We’ll assume you’re a developer, site owner, or tinkerer who just wants a simple, repeatable process without drama.
What You Need Before You Start
Before touching anything, you should:
- Have Ubuntu 14.04 already installed on your server.
- Be logged in through SSH with a non-root user that has
sudoprivileges.
If you’re still logging in as root directly, pause here and set up a normal user first. That keeps you from accidentally wrecking the whole system with a single bad command.
Why the non-root user matters: sudo forces you to think for half a second before running powerful commands. It’s like a safety lock on the power tools in your garage.
Step 1: Install Apache with apt
Apache is the web server part of the LAMP stack. On Ubuntu 14.04, you’ll grab it using the apt package manager.
Package managers like apt save you from hunting random .deb files around the internet. They pull software from Ubuntu’s own repositories and handle the dependencies for you.
- Update package info (recommended first move)
This keeps your package list current so you’re not installing outdated versions:
bash
sudo apt-get update
- Install Apache
Run the install command:
bash
sudo apt-get install apache2
- You’ll be asked for your user password because of
sudo. - The command runs with root-level permissions, so watch for any errors as it installs.
Once that finishes, Apache is installed.
Under normal conditions, the service starts automatically after installation. The next job is simply to verify that it’s actually serving a page.
Step 2: Find Your Server’s Public IP Address
To see Apache in action, you need the server’s public IP. That’s the same IP you usually use when connecting via SSH.
If you already know that IP, you can skip ahead to the browser test. If not, there are a couple of command-line ways to find it.
The instructions mention using the iproute2 tools. These tools let you query your network interfaces from the command line.
From your SSH session, run the appropriate ip command (from the iproute2 tools) to list the addresses on your network interfaces.
You’ll usually get one or two IP addresses back.
- Both are technically valid addresses.
- Depending on your environment, only one might be reachable from your local machine.
So if the first IP doesn’t load in the browser, try the second one.
That’s it for this step: once you have a candidate public IP or two, you’re ready to test Apache.
Step 3: Check Apache in Your Browser
Now let’s see if Apache is actually working.
On your own computer (not on the server), open a web browser and go to:
http://your_server_IP_address
Replace your_server_IP_address with the IP you found in the previous step.
If Apache installed and started correctly, you’ll see the default Ubuntu 14.04 Apache web page. It’s a simple info/testing page provided by the Apache package.
You should see something similar to:
- A page with the Ubuntu branding
- Text explaining that this is the default Apache page on Ubuntu 14.04
If you see that page, congratulations — your web server is installed and answering HTTP requests.
From here you can later add virtual hosts, drop in PHP, or connect it to a database, but the basic “web server works” check is done.
Step 4: Quick Troubleshooting If You Don’t See the Page
If you type the IP in your browser and get nothing, don’t panic. Work through these basic checks.
- Confirm you used
http://and nothttps://
On a fresh Apache install like this, there’s no SSL setup yet. You should be using plain HTTP:
text
http://your_server_IP_address
- Try all IP addresses you found
The instructions point out that you might get one or two addresses back when you query the interface. - Test each of them in your browser.
- One might be a private or internal IP, while another is public.
-
Confirm SSH vs browser IP
If you connect to the server via SSH using a hostname or different IP, double-check that the IP you’re testing in the browser is actually the one the server is bound to.
If you still don’t see the default page after those checks, the problem is likely outside the scope of this minimal install (firewall, network rules, etc.). But for most basic setups, installing Apache through apt and hitting the public IP over HTTP is enough.
Safety and Next Steps
You now have the “A” in LAMP:
- Apache is installed using Ubuntu’s package manager.
- You know how to find the server’s public IP from the command line.
- You’ve confirmed Apache works by loading the default test page in your browser.
A couple of quick safety notes before you go further:
- Keep using your non-root user with
sudofor all system-level commands. That habit alone saves a lot of pain. - If this is a remote server that might host real sites later, avoid random manual changes in
/var/wwwor Apache config until you have a plan. Small, deliberate edits are easier to back out.
From here, typical next steps would be:
- Install and configure the rest of the LAMP stack pieces (MySQL and PHP) using
apt. - Replace the default test page with your own content or app.
- Set up virtual hosts and basic security hardening.
But for this guide’s scope, the core goal is done: a basic, verified Apache install on Ubuntu 14.04.
Need more help? Check the latest CrushEdge posts.
No Comments