クラウドホスティングの概要

提供:Dev Guides
移動先:案内検索

序章

クラウドホスティングは、オンデマンドで作成、変更、破棄できるオンライン仮想サーバーを使用する方法です。 Cloud servers are allocated resources like CPU cores and memory by the physical they are hosted on, and can be configured with any operating system and accompanying software. Cloud hosting can be used for hosting websites, distributing web-based applications, or other services.

このガイドでは、仮想化の仕組み、仮想環境のコンポーネント、他の一般的なホスティング方法との比較など、クラウドホスティングに関連するいくつかの基本的な概念について説明します。

「クラウド」とは何ですか?

“The Cloud” is a common term that refers to internet-accessible servers that are available for public use, either through paid leasing or as part of a software or platform service. クラウドベースのサービスは、Webホスティング、ファイルホスティングと共有、ソフトウェア配布など、さまざまな形をとることができます。 “The Cloud” can also refer to cloud computing, i.e., transparently spanning a task across multiple servers. Instead of running a complex process on a single powerful machine, cloud computing distributes the task across many smaller nodes.

仮想化の仕組み

Cloud hosting environments are broken down into two main parts: the virtual servers that apps and websites can be hosted on, and the physical hosts that manage the virtual servers. Virtualization makes cloud hosting possible: the relationship between host and virtual server provides flexibility and scaling that are not available through other hosting methods.

仮想サーバー

今日のクラウドホスティングの最も一般的な形式は、仮想プライベートサーバー(VPS)の使用です。 VPSは、独自のオペレーティングシステムを備えた実際のコンピューターのように機能する仮想サーバーです。 While virtual servers share resources that are allocated to them by the host, they are totally isolated in practice, so operations on one VPS won’t affect the others.

仮想サーバーは、物理ホストのハイパーバイザーによって展開および管理されます。 Each virtual server has an operating system installed by the hypervisor, that is available to the user. For practical purposes, a virtual server is identical in use to a dedicated physical server, though the a virtual server needs to share physical hardware resources with other servers on the same host.

ホスト

リソースは、仮想サーバーがホストされている物理サーバーによって仮想サーバーに割り当てられます。 このホストは、ハイパーバイザーと呼ばれるソフトウェアレイヤーを使用して、制御下にある仮想サーバーにリソースを展開、管理、および付与します。 The term “hypervisor” is also often used to refer to the physical hosts that hypervisors (and their virtual servers) are installed on.

ホストは、仮想サーバーの起動時に、メモリ、CPUコア、および仮想サーバーへのネットワーク接続の割り当てを担当します。 複数の仮想サーバーが同じ物理コアを利用している可能性があるため、ハイパーバイザーの継続的な義務は、仮想CPUコアと物理CPUコアの間のプロセスをスケジュールすることです。 Hypervisors differ from one another in the nuances of process scheduling and resource sharing.

ハイパーバイザー

There are a few common hypervisors available for cloud hosts today. これらのさまざまな仮想化方法にはいくつかの重要な違いがありますが、それらはすべて、ホストが必要に応じて仮想サーバーを展開、維持、移動、および破棄するために必要なツールを提供します。

KVM は、「カーネルベースの仮想マシン」の略で、Linuxカーネルに組み込まれている仮想化インフラストラクチャです。 このカーネルモジュールをアクティブにすると、Linuxマシンがハイパーバイザーに変わり、仮想サーバーのホスティングを開始できるようになります。 This method contrasts with how other hypervisors usually work, as KVM does not need to create or emulate kernel components that are used for virtual hosting.

Xen is one of the most common hypervisors. Unlike KVM, Xen uses its own microkernel, which provides the tools needed to support virtual servers without modifying the host’s kernel. Xen supports two distinct methods of virtualization: paravirtualization, which skips the need to emulate hardware but requires special modifications made to the virtual servers’ operating system, and hardware-assisted virtualization (or HVM), which uses special hardware features to efficiently emulate a virtual server so that they can use unmodified operating systems. HVM became widespread on consumer CPUs around 2006, allowing most desktops and laptops to achieve similar performance when running virtual machines or microkernel-based containers (e.g. through Docker).

ESXi は、VMwareが提供するエンタープライズレベルのハイパーバイザーです。 ESXiは、ホストに基盤となるオペレーティングシステムが必要ないという点で独特です。 これは「タイプ1」ハイパーバイザーと呼ばれ、ハードウェアと仮想サーバーの間に「仲介者」がいないため、非常に効率的です。 ESXiのようなタイプ1ハイパーバイザーでは、ハイパーバイザー自体がオペレーティングシステムとして機能するため、ホストにオペレーティングシステムをロードする必要はありません。

Hyper-V は、Windowsサーバーを仮想化する最も一般的な方法の1つであり、WindowsServerのシステムサービスとして利用できます。 これにより、Hyper-Vは、Windowsソフトウェア環境内で作業する開発者にとって一般的な選択肢になります。 Hyper-V is included in modern versions of Windows and is also available as a stand-alone server without an existing installation of Windows Server. WSL2, the Windows Subsystem for Linux, is implemented via Hyper-V.

なぜクラウドホスティングなのか?

仮想化によって提供される機能は、クラウドホスティング環境に適しています。 仮想サーバーは、さまざまなハードウェアリソース割り当てを使用して構成でき、多くの場合、時間の経過とともにニーズの変化に応じてリソースを追加または削除できます。 Some cloud hosts can move a virtual server from one hypervisor to another with little or no downtime, or duplicate the server for redundancy in case of a node failure.

カスタマイズ

開発者は、仮想環境を制御できるため、VPSでの作業を好むことがよくあります。 Linuxを実行しているほとんどの仮想サーバーは、デフォルトでroot(管理者)アカウントまたはsudo特権へのアクセスを提供し、開発者が必要なソフトウェアをインストールおよび変更できるようにします。

この選択の自由は、オペレーティングシステムから始まります。 ほとんどのハイパーバイザーは、LinuxやBSDなどのオープンソースソフトウェアからWindowsなどのプロプライエタリシステムまで、ほぼすべてのゲストオペレーティングシステムをホストできます。 そこから、開発者は、作業に必要なビルディングブロックのインストールと構成を開始できます。 A cloud server’s configurations might include a web server, database, or an app that has been developed and is ready for distribution.

スケーラビリティ

クラウドサーバーは、拡張性に非常に柔軟性があります。 スケーリング方法は、水平スケーリングと垂直スケーリングの2つの大きなカテゴリに分類されます。 ほとんどのホスティング方法は、いずれかの方法で拡張できますが、クラウドホスティングは、水平方向と垂直方向の両方に拡張できるという点で独特です。 This is due to the virtual environment that a cloud server is built on: as its resources are an allocated portion of a larger physical pool, these resources can be adjusted or duplicated to other hypervisors.

水平スケーリングは、「スケールアウト」と呼ばれることが多く、クラスター化されたシステムにノードを追加するプロセスです。 This might involve adding more web servers to better manage traffic, adding new servers to a region to reduce latency, or adding more database workers to increase data transfer speed.

垂直スケーリング、つまり「スケールアップ」は、単一のサーバーが追加のリソースでアップグレードされる場合です。 これは、使用可能なメモリの拡張、より多くのCPUコアの割り当て、またはそのサーバーの容量を増やすその他のアップグレードである可能性があります。 これらのアップグレードは通常、データベースワーカーなどの追加のソフトウェアインスタンスがそのサーバー上で動作するための道を開きます。 Before horizontal scaling became cost-effective, vertical scaling was the de facto way to respond to increasing demand.

クラウドホスティングを使用すると、開発者はアプリケーションのニーズに応じて拡張できます。追加のVPSノードを展開してスケールアウトしたり、既存のサーバーをアップグレードしてスケールアップしたり、サーバーのニーズが大幅に増加したときに両方を実行したりできます。

結論

By now, you should have an understanding of how cloud hosting works, including the relationship between hypervisors and the virtual servers that they are responsible for, as well as how cloud hosting compares to other common hosting methods. この情報を念頭に置いて、ニーズに最適なホスティングを選択できます。

For a broader view of the overall cloud computing landscape, you can read A General Introduction to Cloud Computing.