How to create the first VPS on DigitalOcean

The complete guide from zero to owning a DigitalOcean VPS

In this article, I want to guide you through the process of setting up your first Linux Virtual Private Server (VPS) on DigitalOcean.

DigitalOcean is one of the most famous VPS services.

DigitalOcean provides a one-click installation process for the most famous applications and operating systems, and it provides a global network of data centers and CDN locations. It is also very reliable, starting at 5 $/m, and very convenient.

I think DigitalOcean is one of the most affordable and easy-to-use solutions, and it can be used for various services.

Step 1: Create a DigitalOcean account

you couldUse this affiliate linkTo get a bonus of $100, you can use the bonus for the next 60 days.

Disclaimer: This is an affiliate link. When you sign up using this link, you will get a credit of 100 USD, and I will get a DigitalOcean credit of 25 USD.

I don't recommend DigitalOcean just because they have a membership plan. Quite the opposite: Since I use it a lot, if I can lower my bill, I will take advantage of this opportunity.

After entering the website:

Fill out the registration form and you will get up and running quickly. You can also register using Google or GitHub.

You need to confirm your email:

Then, you need to enter the billing information required after completing the $100 free credit:

Step 2: Create a project

After registering, you can now create a new project:

Enter the name and description of the project:

After clicking "Create Project", the project will be added to your project list, andProject dashboardappear:

This is the control center for whatever you want to do with this project.

First, there is a big blue buttonStart using Droplettext.

What is a droplet? DigitalOcean Droplet is a virtual machine, or VPS. We want to create something. All content on DigitalOcean revolves around Droplets.

Through this interface, we can also initialize the hosting database, create space (a location for storing files), and create a load balancer to distribute traffic among multiple Droplets.

But let's keep it simple. We just want to create a droplet.

Create a droplet

Click onStart using DropletButton in the project dashboard.

This will display a page with many options:

Let's start from the beginning.

Preferred isChoose a picture. Here, we can choose between several Linux distributions (Ubuntu, Fedora, Debian and CentOS) and FreeBSD (another UNIX operating system).

For each version, we can choose a specific version:

In addition to releases, we have other categories.marketIn particular, let us install a server pre-configured with WordPress, Ghost, LAMP server or any of more than 150 applications with just one click. This is a very convenient way to get up and running any project quickly.

Snapshots, backups and custom images allow you to create servers from existing servers.

Now that you know everything you can do here, let us chooseUbuntu LTSFrom the Distribution panel.

inChoose a planYou canstandardPlan (this is the plan we will use), or a higher-performance CPU-optimized server or memory-optimized server. This means that the server will cost more.

Speaking of cost, now we have a table where we can choose the size (and cost) of the server:

Don't be deceived: Click the left arrow to reveal cheaper plans:

Before an upgrade is needed, a $5 monthly plan may go a long way. From there. Please also note that billing is billed by the hour, so if you use the server for 10 minutes, you still need to be billed for 1 hour.

Next, we can choose to add block storage to have persistent data storage (not needed now), and we can choose the data center area:

Which one should you choose?

The one closest to your visitors. I almost always choose New York because it is located between Europe and the rest of the United States.

There are other options that you can ignore, and thenverification:

selectpasswordTo make the operation easier, but for real servers, I recommend using SSH key authentication (the setup is more complicated, but more secure).

Enter the password you want to userootUser, Linux system administrator.

Then fill in a username that is meaningful to you:

Finally, clickCreate dropletsButton:

Then DigitalOcean will start creating droplets:

Once it is over, it will display your public server IP address:

Click on the name to display the Droplet dashboard:

From here you can completely control anything. You can turn it on, off, resize, etc.

Remember, turning off Xiaodi does not stop DigitalOcean's billing: you have to destroy it, so it won't take up any space at all.

Access the Droplet as root

Now, from the Droplet, you can access the Droplet by clicking the "Access" menu and the "Launch Console" button:

This will open a login window in your browser, allowing you to log in to the server. enterrootAs the username and the password you previously set:

Then, you should be able to log in to the server:

The console in the browser is not ideal. It is best to use an operating system terminal.

Let me use the macOS Terminal application to access the server. I write the commandssh [email protected]<IP ADDRESS>:

I immediately received a warning telling me that I had never connected to this server before. I accept "yes":

Now the server asks me to enter the password:

I have logged in:

What's the next step?

Now you can fully control the computers in a data center located somewhere in the world.

Isn't it cool? This is just the beginning.

Before the server is ready to perform any operations, you need to do a lot of things. The first thing you should do is to create a user who is not a root user, worry about the security of the server and set up any servers that you want to run on. it.


More service tutorials: