Shared Hosting vs Virtual Server

Started by lokdown, Aug 02, 2022, 12:03 PM

Previous topic - Next topic

lokdownTopic starter

Despite the availability of inexpensive VPS hosting, traditional shared hosting is not becoming obsolete. In this discussion, we will explore the differences between the two approaches to web hosting and determine which one is more advantageous.



On the website of every reputable provider, a comparison of traditional website hosting with virtual servers can be found. While many compare VPS to physical machines, likening them to individual apartments, shared web servers are often compared to communal apartments. However, let's take a closer look beyond these surface-level analogies and analyze the specifics of each option for novice users.

How does traditional hosting function?

In order for a web server to provide services for multiple websites, name-based virtual hosts are used. The HTTP protocol allows a URL (Uniform Resource Locator) to be transmitted as part of the request, allowing the system to identify the website being accessed by a browser or other client program. With this information, the domain name can be connected to the desired IP address and the root directory for the virtual host specified in the layout. The website files of different users can then be separated into their respective home directories and FTP access provided for administration.

A special suexec mechanism was created in Apache to allow web applications on the server side (various scripts, content management systems, etc.) to run with the privileges of a specified hosting user. While the web server's security settings prevent users from accessing others' files, the overall setup closely resembles a communal apartment with separate rooms and a shared address (IP) for hundreds of websites. Although the database server (usually MySQL) for virtual hosts is also shared, hosting users only have access to their own personal databases. Clients cannot modify the configuration of server software beyond site scripts, which is maintained by the provider. An automated account management process exists, with each hosting provider offering a specific web panel for managing services.

How are VPS configured?

Comparing virtual servers to physical servers is not entirely accurate, as many VPSs operate on a single physical host. This is more akin to an apartment building with a shared entrance and common support structures, rather than a shared apartment. Various virtualization technologies and the operating system installed on the host are utilized to create separate "apartments" (VPS) within the same "building" (physical server).

When OS-level virtualization is employed, client processes function in an isolated environment or container, disconnected from other resources and processes. In this case, a separate guest OS is not started; as a result, software in the guest environment must be binary-compatible with the system on the physical host. Typically, clients are offered GNU/Linux distributions specially modified for this method of operation. Advanced options are available, ranging from the emulation of a physical device to running almost any guest OS from an independent installation image.
  •  

Charlesth

I do not comprehend why the current trend is to opt for inexpensive virtual servers for running WordPress, OpenCart, and so on. I believe that shared hosting is more reliable and economical for hosting the same sites.

Shared hosting has evolved significantly in the past decade. Nowadays, CloudLinux-based hosting solutions are common. Essentially, this type of hosting is similar to a virtual server based on OpenVZ, where each user is allocated specific resources (processor and memory). The hosting cost includes a control panel, and the provider oversees the relevance of the software and operation of all server services.

However, purchasing a paid panel and round-the-clock administration service for a virtual server becomes more expensive than regular hosting. Although providers may advise clients that administration is unnecessary as the server will be set up once and will function smoothly, vulnerabilities still exist. For instance, exim, proftpd, vesta have been known to be exploited in numerous server hacks.

My belief is that a virtual server is only necessary when the resources of regular hosting are insufficient or for running exotic software.
  •  

richtedy

Positive aspects of shared hosting include the convenience of pre-existing setups, easy-to-use hosting panels, affordable pricing compared to VDS, as well as the ability to test the hosting for free within a trial period. However, the main drawbacks are the dependence on neighbors due to the resources being shared and using a shared IP address, unless an individual one is purchased.

In contrast, virtual VPS servers provide fully dedicated resources and a guaranteed high speed of the sites. Additionally, each server has a dedicated IP address that belongs only to the user, and complete control over server configuration through opening and closing ports, and setting policies is possible. On the other hand, configuring the server requires some knowledge, and the price is slightly higher than a hosting service.

Conclusively, shared hosting is recommended for simple, low-traffic sites while virtual VPS servers are suitable for highly loaded projects with significant commercial or SEO optimization requirements.
  •