Server for creating virtual servers. How do I create a local server? We deploy a local server on Windows. Why do you need hosting

Virtual servers: if you create a server on a local network and want to make it available on the Internet, a virtual server can implement this service and provide it to users. At the same time, the virtual server allows you to maintain the security of the local network, since other services will still be invisible from the Internet.

A virtual server can be used to configure public services on your local network such as HTTP, FTP, DNS, POP3 / SMTP and Telnet. Different services use different service ports. Port 80 is used by the HTTP service, port 21 is used for FTP, port 25 is used for SMTP, and port 110 is used for POP3. Check the service port number before configuration.

Configuration example

For example, a personal website was created on my home PC (IP address: 192.168.0.100). I want my friends to be able to visit my site over the Internet.

PC is connected to a router with WAN IP-address 218.18.232.154.

LAN WAN Router: 218.18.232.154

Assign a static IP address to your computer, for example 192.168.0.100

Follow these steps:

Note: Adjustment is made using the example of the Archer C9 model.

Step 1

Log into the Archer C9 web interface. Read the article How to log into the web interfaceWi- Fi router for instructions on how to access the router's web interface.

Step 2

Click Advanced (Additional settings) at the top right, then on the left, select NAT Forwarding (NAT forwarding) -> Virtual Servers (Virtual servers) -> Add (Add).

Step 3

Click View Existing Services (View existing services) and select HTTP External port (external port), internal port (internal port) and protocol (protocol) will be filled in automatically. Enter the computer address 192.168.0.100 in the field Internal IP (internal IP address).

2. If the service you want to specify is not registered in the Service Type, you can enter the corresponding parameters manually. You need to check the port number that the service needs.

3. You can add multiple virtual server rules if you want to provide multiple services in the router. Please remember that external ports must not be duplicated (duplicated).

Step 4:

To visit your website, Internet users can log in to http:// WAN IP (in this example: http: // 218.18.232.154).

Note: Your settings will not take effect if NAT is disabled. Go to the page Advanced (Additional settings) > System Tools (System Tools)\u003e System Parameters (System parameters) to enable NAT.

1. WAN IP address must be public (white / external). If the WAN IP is assigned dynamically by the ISP, it is recommended to register and use a domain name for the WAN IP (see setting up a DDNS service account). In the future, you can type in the address bar http:// domain name,to visit the website.

If you are not sure how to configure static IP (static IP) on the device, you can configure (address reservation) by following How to configure address reservation on TP-Link Wi-Fi routers (new blue user interface), so that one and the same IP address will always be assigned to your device.

2. If you changed the external port from the default, you must use http:// WAN IP: External port or http: // domain name: External portto visit the website.

3. Make sure the server is accessible from the internal network. You can check if you are accessing this server inside the local network. If you cannot access the server on your local network, check your server settings.

Find out more about each feature and setting, go to section DOWNLOADS on your website to download your product manual.

Some time ago there was an idea to test the prospects of developing a site on ASP.Net focused on working in a Linux environment. However, the fact that the site will work in an environment on a host with Linux, it was decided immediately, it only remained to decide on the programming language: ASP.NET 2 in conjunction with the power of Mono, or PHP. The options for testing various VPS, even if provided for free for a short time by hosting providers, disappeared right away. if the experiment was successful, sooner or later, in any case, a local VPS server would be required.

The VirtualBox program became a virtual machine for creating a home virtual server - from the considerations that a virtual machine may be needed only for one time, commercial options were not considered immediately, and among free programs - only this one is simple enough to set up and can fully support guest operating systems of the family Linux. Also, as a result of the analysis of VPS offers on the Internet, several of the most common and Mono-compatible operating systems were identified from those pre-installed by hosting providers.

So, the tools used:

Install VirtualBox, launch and create a virtual machine of the desired configuration. When creating the virtual machine, I left all the recommended settings except for the available memory - it was reduced to 128 MB, and the size of the virtual hard disk - increased to 4 GB. We start the virtual machine and mount the image with the Debian 5 operating system.

After downloading in the installation menu, select Installsince we don't need a graphical installation. We select the installation language, I recommend English (if you are not friends with English at all, then Russian), then select the location other => Europe => Russian Federation, and keyboard layout for input, here I strongly advise you to select English for the United States. During installation, you are prompted to enter the name of the machine for the network, I entered MyVPS, and the name of the domain in which this computer is located (you can not enter anything here). Further, the choice of time zone and the method of partitioning the hard disk are proposed. I chose the default method, in general, for me it was not particularly important. We agree with the proposal to write the changes to the disk and confirm its partitioning. We are waiting for the end of the installation of the system ...

During the installation process, a password for the administrator account, username and password are requested. Next, you are asked to select the address of the nearest repository and proxy server settings for Internet access. If you are not using a proxy server, you do not need to enter anything. The installer will now connect to the repository of your choice, ask for information about available software, and download the packages required to proceed with the installation. After that, the system kernel will be configured and a menu for selecting the software to be installed will appear. Uncheck the item Desktop environment (a desktop on a VPS is not needed), be sure to leave a mark on the item Standard system, the rest of the items are optional. Upon completion of the installation, the question will be asked: is it possible to put the GRUB bootloader as the main one, select Yes... After that, you will be prompted to remove the disk and reboot. Unmount the disk image and click Continue to reboot the virtual machine. Congratulations! This completes the OS installation.

So, the virtual machine is rebooted. It is suggested to enter a login. Enter root, then you will be asked for a password, enter it as well. Now you need to install SSH. To do this, enter the command

Apt-get install ssh

The program will analyze the dependencies and ask for confirmation to download and install the package ssh and those packages on which it depends.

After installation, turn off the virtual machine. Since the operating system is used by a single user, for this we enter the command

Now we need to configure our virtual machine for SSH access, and also configure access to the future web server on port 80. This can be done in two ways.

    Close all VirtualBox windows. Go to folder C: \\ Users \\% username% \\. VirtualBox \\ Machines on Windows 7 and Vista or to a folder C: \\ Documents and Settings \\% username% \\. VirtualBox \\ Machinesif you have Windows XP.

    Open the folder of the virtual machine you created, find a file with the name of your virtual machine in it. In my case it is MyVPS.xml open it and add to section ExtraData following lines






    Close VirtualBox. Open console. If you have Windows go to the folder C: \\ Program Files \\ Sun \\ VirtualBox... Enter the following commands in the console

    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / apache / GuestPort" 80
    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / apache / HostPort" 80
    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / apache / Protocol" TCP
    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / ssh / GuestPort" 22
    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / ssh / HostPort" 2222
    VBoxManage setextradata "% mashine_name%" "VBoxInternal / Devices / pcnet / 0 / LUN # 0 / Config / ssh / Protocol" TCP

    where% mashine_name% is the name of your virtual machine.

Launch VirtualBox and turn on the virtual machine. If now you get an error about the impossibility of turning on, close everything and re-configure the virtual machine. You probably made a mistake when entering commands. If you changed the settings in the xml file, check the added entries for errors, if in the console, enter the commands again.

After starting the virtual machine, run the Putty program, if you are in Windows, in the Host field, write localhost, in the Port field set the value 2222 ... Push Open, we agree to accept the ssl key. If you are on Linux, enter

Ssh -l% user_name% -p2222 localhost

Enter your login (in Putty) and password.

You can use WinSCP to manage the file system. You will need to enter localhost, set the Port value to 2222 , enter your username and password.

The server is ready in minimal configuration. Now you can install Apache, nginx, MySQL, etc. Please note that the web server must work on port 80. If you want to use any other port, change the virtual machine settings using the VBoxManage program.

"How to create a virtual server?" - a frequent question that arises among many users who first encounter hosting. In the article, we will continue to analyze what a VPS (VDS) is, how to choose it correctly, configure this type of hosting for the needs of your project and is it possible to create a regular Virtual Private Server on your own, or you need to rent it.

In we found out what a virtual server is, when it is worth purchasing it, which operating system (Linux or Windows) is better to use.

Apart from traditional website hosting, virtual servers can be used for IP telephony, virtual routers and switches, VPN or proxy, terminal servers with traditional office programs for remote access from employee computers.

Technology Information

Most often, when developing sites, the PHP programming language, MySQL databases, and Apache and Nginx web servers (they work independently or in combination) are used. This set of programs is also often called LAMP (Linux- Apache- MySQL- PHP) or LEMP (Linux- Nginx- MySQL- PHP).

Of course, other technology stacks are also used, sites can be written in other programming languages \u200b\u200b(Python, Ruby, NodeJS) and use other databases (PostgreSQL, noSQL), as well as auxiliary software. But, since such solutions are less common, we will not consider them. Let's take a closer look at the choice and initial configuration of a VPS for hosting sites in PHP and corporate mail.

Selection of a tariff plan

There will not be a detailed guide on how to select the required tariff, since resources are selected individually in each case. The amount of resources will depend on the number of sites on the server used by the CMS, the need to use additional programs, etc.

The only thing that is calculated accurately enough is disk space. Check how much space is used by sites and mail, add 7-10 GB to this and get the minimum disk space required. The fact is that on the VPS you need to allocate additional space for installing the operating system and control panel, which is also taken into account in the total disk space.

Operating system and control panel

There is a whole family of operating systems based on the Linux kernel, including both server and desktop versions. Most popular server operating systems: CentOS, Debian, Ubuntu Server.

If you need a very stable system, CentOS is your choice. A stable and secure system, but with the ability to upgrade to the latest software versions if necessary, this is Debian. Ubuntu Server is an OS that keeps up with the times, delivering the latest versions of programs, which may cause them to not work perfectly.

The server control panel is a kind of script, or a set of scripts that allows you to conveniently manage the VPS in a graphical interface. Usually the graphical part is available in the browser at a specific address.

The choice of PU is largely influenced by the subjective experience of use, that is, one panel will seem more convenient to some users, to others the other. If you are at a loss with a choice, you can test the interface of various products in a demo version on the developers' sites and decide which suits you best. Also, the choice of PUs is closely related to the operating system, since they usually support a limited list of operating systems. And another important factor in choosing a panel is the availability of the tools you need or the ability to quickly install them.

Of course, you can not use the control panel at all and configure the virtual server through the command line, but this method requires sufficient technical knowledge. Most PUs come with a set of popular basic software needed to quickly deploy your sites. It is a web server, PHP, databases, FTP, mail and DNS server. All packages are already optimally configured to start working with the server immediately.

We recommend using a VPS with a control panel and provide free full-fledged technical support for them. For servers without a panel, technical support will be limited. Creating a virtual server is an incredibly expensive process, and for a full-fledged hosting there is a platform where you can host your resource, and you do not have to create it from scratch.

For installation on our VPS and dedicated servers, we offer the following panels: cPanel / WHM (from $ 13.95 / month), ISPmanager 5 Lite ($ 4 / month), Plesk 17 (from $ 10 / month), Centos Web Panel (free ), and it is also possible to install the Bitrix virtual environment.
We will look at all these control panels in more detail in the next part.

Hello, dear readers of Habr. With this material, we begin a series of publications on how to build a VPS hosting from scratch based on RUVDS White Label API.

In this introductory publication, we will tell you what you need to do first in order to start making the first profit from your own VPS hosting as soon as possible, how to do it relatively quickly, and how expedient and profitable it is. If you decide to create your VPS hosting from scratch, but you do not have your own infrastructure or do not have the funds and time to create it, welcome under cat.

Do you need a website


To organize your own VPS service, you first of all need 2 things - a site on which you will offer services for renting VPS servers and a service provider that provides you with favorable partnership conditions for these purposes, its own infrastructure and a reliable API with wide capabilities. What is an API? This is a kind of interface, using which you can provide your customers with all the same server management capabilities that your service provider provides to its customers.

It will be much cheaper and faster to integrate a website with your VPS-provider via API than to create your own cloud infrastructure from scratch, since in this case it "takes care" of many questions: you do not need to worry about the availability of sufficient resources from the provider, how to organize a wide and fault-tolerant channel for Internet access from virtual servers, how to collect and store data on the use of resources by servers, and so on.

Now about the site. There can be many options, we will list the most common:

  • you are the owner of a website that offers related services (checking / registering domains, renting a DNS server, remote server administration).
  • you create your site from scratch using the popular CMS and plugins for it.
  • you order a website from a web studio
  • enter your version
The first is the best option, since in order to add a new service for renting VPS servers, very few improvements are needed: you do not have to write from scratch many of the things that are listed below. When building your website from scratch, the launch timeline can change significantly for the worse. You will need to independently implement all the components from the list below (or use third-party implementations, having previously tested and adapted them for your project). We recommend using the third option only if you do not have the necessary knowledge to create sites or if it is impossible to make your site the way you want.

Let's start


What should be implemented on this site?

Registration, user authentication / authorization, password recovery, feedback form.

All hosting providers have it. Your future client must be able to register, recover the password if it is lost, have a personal account on the site with up-to-date information about his balance, purchased servers, etc. Also, he must be given the opportunity to report a problem to technical support. In order to avoid mass registration of "fake" accounts, we recommend not to neglect additional protection means, such as captcha on forms, and also to keep the maximum amount of available information about the user, which can help in case of any violations on his part. In this case, there are many ready-made solutions that require minor modifications. If you are planning to create your site based on a CMS, then the above functionality is either implemented in it to some extent, or can be easily connected using plugins.

Customer personal data management

It should be implemented to some extent, but you can do without it. This functionality is not blocking the launch of your service.

Client server management

What should be on a given page of your site depends on how much you want to use the available functionality of your service provider and how much control over the server you will give to your client. For example, you can create a dedicated server for him after entering the required amount on the balance and his written request to technical support, or you can provide him with a full-fledged configurator to fine-tune the server's characteristics, as well as interfaces for changing the configuration in the process, obtaining server load statistics, various possibilities like reinstalling the OS, and so on. The launch speed of your VPS hosting will vary significantly depending on the option you choose. We will consider this issue in more detail in the following articles from this series.

The ability to use a test period

Obviously, for the initial promotion of your new VPS hosting service, you will need to implement the test period. This is necessary so that your client can decide for himself how much the price announced by you for renting a VPS corresponds to the quality of the services you provide. What should be considered when implementing? First of all, you need to choose the number of days. Do not make the test period too long - clients who just want to get a free server for a certain period of time will register on your service, and after the test period is over, they will register a new account and try to use the test period again. In order to somehow protect you from such clients, you definitely need to learn how to identify them. This is especially important at the initial stage of the development of your service, as due to each such client you will receive less potential profit. It should also be borne in mind that a long test period will not be very beneficial for you, since there is no test period on your partner account, to which all the servers you create are linked to.

Billing

How will customers replenish their balance and buy servers? Of course, we need one more very important component, this is billing. What do we include in billing? Of course, it includes the creation / editing of current tariffs, interfaces for receiving customer payments, internal payment processing mechanisms, the creation of promotions / discounts, monitoring tools.

Implementation of your own or integration into your project of third-party billing should be approached especially responsibly, because the ability to buy a VPS server on your website directly depends on the performance of this component (read your first money). To quickly start accepting money from the most popular payment systems, we recommend that you use payment aggregators. Why? Firstly, it is much faster and easier to integrate with one aggregator than with each of the payment systems it provides. This is due to the fact that each payment system has its own interaction protocol, which must be correctly implemented and unified to work with it within your system, which is extremely laborious. Secondly, you have one interface that provides most of the necessary functionality for working with customer payments - this is the aggregator's personal account. Of course, you will have to pay an additional commission for all this, but in our opinion, this solution is optimal when creating your own VPS service.

Of course, before integrating with a payment aggregator, your site must meet certain requirements. An example is the requirements of the paymaster payment aggregator:

  • the site must be completely filled with information, function;
  • the site must consist of more than one page;
  • the site must contain information about the goods and services sold, as well as the cost of these goods and services;
  • the site should not be hosted on free hosting;
  • the goods and services offered on the site must not contradict the current legislation of the Russian Federation and international law;

Also, you should pay attention to the fact that the list of payment systems, as a rule, is much wider if you enter into an agreement as a legal entity. In some cases, the connection of certain payment systems can take quite a long time, since your site must meet the requirements of each payment system provided by the aggregator, and the verification procedure is performed on the side of the payment system.

Financial aspect


We have come to one of the most important aspects (if not the most important) - financial. It should be profitable to work with your VPS provider. Let's calculate why it is profitable to organize a VPS-server rental service by choosing RUVDS as a service provider.

Let's take the most popular VPS configurations based on the Windows Server 2012 R2 operating system and give some data that we received when analyzing the VPS services market in Russia as of February 2016:


Configuration

1

2

3

4

5

Number of processors

1

2

4

6

8

RAM, GB

1

2

4

8

16

Disk volume, GB, HDD

20

40

120

300

600

Number of IPv4 addresses

1

1

1

1

1

Current configuration price

When paying per month

300 p.

600 RUB

1400 RUB

2980 p.

5720 p.

When paying for the year

2880 p.

5760 p.

13440 p.

28608 p.

54912 p.

In order to estimate your potential earnings, we present the gain in terms of the configuration price over the average price of competitors:

Also, do not forget that we have the cost of paying commission for transfer and withdrawal to payment systems.

The current discount for creating servers using the API is 10% .
How to estimate the potential earnings from one server of a given configuration, purchased for a month? You can use the following formula:
Earnings \u003d Current RUVDS price * 10% + Difference with the average configuration - Expenses for payment of commissions.

Calculation example for configuration 3:

Earnings \u003d 1400 * 0.1 + 794 (round down) -240 \u003d 694 rubles.

This is earnings from one server. When your clients buy 25-30 servers of this configuration, you will get the amount of earnings already in 20 thousand rubles per month.

In the following articles, we will tell you in detail about the possibilities of RUVDS White Label API, we will discuss how to choose the best rates for your VPS hosting and on what conditions you can earn.

This document will help you create your first virtual server on the site of the cloud hosting provider Clodo.ru

Creating a virtual server

Creating a virtual server (Virtual Server) on the cloud hosting site Clodo.ru will take a few minutes of your time from you. The procedure is simple and requires almost no description. However, we have created this guide to ensure that the process of creating a VPS does not cause questions for you.

If you already have a virtual server, then in order to create a virtual server, you need to click on the "Create virtual server" button on the main page of the control panel. If you do not have a single virtual server, then when you go to the “My resources” section, you will be automatically redirected to the page for selecting a data center for server installation.

After clicking on the "Create virtual server" button, you will be offered a choice of a list of data centers in which you can create a virtual server. After selecting the required DC, click on the "Go to the next step" button.

On the page with the choice of the type of virtual server to create, you will see two options. As part of this article, we are considering installing a classic virtual server, so we must make the appropriate choice - Virtual Server.

The next step in creating a virtual server is to select the operating system that will be installed on the created VPS. Cloud hosting Clodo.ru provides its customers with a large selection of Linux-based operating systems. Each of our clients will find exactly the one with which it is most convenient for him to work. At the time of this writing, cloud hosting Clodo.ru provides the ability to install the following operating systems:

  • Debian
  • Ubuntu
  • CentOS
  • OpenSuse
  • Fedora
  • Arch Linux
  • Gentoo

Also, you can choose to install a system with a set of software installed, called a Preset.

At step 4, you need to select the server parameters, such as the amount of RAM and disk storage, as well as enter the name of the server, which will be displayed in the list of servers in the future. With the help of the constructor presented in this step, you can create a solution that is right for you. Do not be afraid to specify the parameters incorrectly, in the future you can change them already on the running virtual server.

If you want to customize the server more precisely, then click on the "Advanced settings" button. Advanced settings will not be covered in this article.

In the next step, you are asked to select additional services such as: installation of the ISP manager server control panel, additional IP addresses and a server technical support plan. Please note that when you change the technical support plan, its description also changes. Carefully study the presented service levels and choose the one that suits you best.

The next step is final. Check the parameters of the virtual server being created again.

After clicking on the "Create a virtual server" button, you will be redirected to a page with a list of virtual servers.

Virtual server installation takes no more than 5 minutes.

Congratulations! You have become the owner of a virtual server on Clodo!

Terms of use of the document

The material presented on this page can be used by you at your own discretion. It is permitted to copy and distribute the provided material without changing the content and without prior notice to the administration of Clodo.ru.

We would be grateful for the error messages in the submitted documentation and for suggestions for improving the documentation. For these questions, please contact [email protected]. Remember to include the URL of the publication when contacting.

Bluetooth