Agile Cat — in the cloud

July 3, 2010

Facebook 探検隊: どのようなソフトウェアでスケールを達成しているのか _1

Filed under: Big Data,Facebook — Agile Cat @ 8:10 am
Tags: , , , , , ,

Exploring the software behind Facebook, the world’s largest site _1
Posted in Main on June 18th, 2010
by Pingdom
http://royal.pingdom.com/2010/06/18/the-software-behind-facebook/

facebook_logo

At the scale that Facebook operates, a lot of traditional approaches to serving web content break down or simply aren’t practical. The challenge for Facebook’s engineers has been to keep the site up and running smoothly in spite of handling close to half a billion active users. This article takes a look at some of the software and techniques they use to accomplish that.

Facebook の運用スケールにおいて、 Web コンテントをサービスするための、数多くの伝統的なアプローチは失敗し、また、現実的ではなくなっている。 Facebook のエンジニアによるチャレンジは、5億人に近いアクティブ・ユーザーをハンドリングしながら、このサイトを維持して、順調に走らせることにある。 この記事では、その目標を達成するために、Facebook が要しているソフトウェアとテクニックを見ていく。

Facebook’s scaling challenge

Before we get into the details, here are a few factoids to give you an idea of the scaling challenge that Facebook has to deal with:

詳細に入る前に、Facebook が取り組むスケーリングへの挑戦において、その考え方を把握するために有用な、いくつかの事実と思われる項目を提供する:

● Facebook serves 570 billion page views per month (according to Google Ad Planner).
There are more photos on Facebook than all other photo sites combined (including sites like Flickr).
More than 3 billion photos are uploaded every month.
Facebook’s systems serve 1.2 million photos per second. This doesn’t include the images served by Facebook’s CDN.
More than 25 billion pieces of content (status updates, comments, etc) are shared every month.
Facebook has more than 30,000 servers (and this number is from last year!)

Facebook サーバーの PVs は 5700億/月間である(oogle Ad Planner によると)
Facebook にストアされる写真の枚数は、その他すべてのサイトの合計よりも多い(Flickr なども含む)
30億枚以上の写真が、毎月アップロードされる
Facebook のシステムは、毎秒 120万枚の写真を処理する(Facebook CDN での処理は除く)
毎月 250億以上のコンテントがシェアされていく(ステータス・アップデートやコメントなど)
Facebook は 30,000 台以上のサーバーを保有している(2009年末のデータ

Software that helps Facebook scale

In some ways Facebook is still a LAMP site (kind of), but it has had to change and extend its operation to incorporate a lot of other elements and services, and modify the approach to existing ones.

ある意味で、Facebook は依然として LAMP サイトであるが、多数のエレメントとサービスを取り込むために、そのオペレーションを革新し拡張し、また、既存のアプローチを修正しなければならない。

For example:

Facebook still uses PHP, but it has built a compiler for it so it can be turned into native code on its web servers, thus boosting performance.
Facebook uses Linux, but has optimized it for its own purposes (especially in terms of network throughput).
Facebook uses MySQL, but primarily as a key-value persistent storage, moving joins and logic onto the web servers since optimizations are easier to perform there (on the “other side” of the Memcached layer).


Facebook は PHP を使い続けているが、コンパイラを構築している。 そのため、Web サーバー上ではネイティブ・コードに置き換えられ、そのパフォーマンスをブーストしている。
Facebook は Linux を使っているが、その目的に合わせて最適化している(とりわけネットワーク・スループットの視点で)。
Facebook は MySQL を使っているが、join と logic を Web サーバーに移行するための、最適化が容易であるという理由から、プライマリーとして key-value persistent storage を使っている(Memcached レイヤの受け側として)。

Then there are the custom-written systems, like Haystack, a highly scalable object store used to serve Facebook’s immense amount of photos, or Scribe, a logging system that can operate at the scale of Facebook (which is far from trivial).

それ以外にも、Facebook における膨大な写真を処理するために用いられる、ハイスケールなオブジェクト・ストアである Haystack や、Facebook のスケールにおいて機能するログ・システムである Scribe のような、カスタム記述されたシステムがある(詳細は不明だが)。

But enough of that. Let’s present (some of) the software that Facebook uses to provide us all with the world’s largest social network site.

しかし、それだけ分かれば充分だろう。さあ、世界最大の SNS を提供するために、Facebook が使用しているソフトウェア(すべてではないが)を見ていこう。

<続く>

ーーーーー

今回を含めて、3回くらいに分けてポストする予定です。それにしても、5700 億 PVs/月 には、笑うしかないですね。 ーーー A.C.

ーーーーー

<関連>
Facebook 探検隊: どのようなソフトウェアでスケールを達成しているのか _1
Facebook 探検隊: どのようなソフトウェアでスケールを達成しているのか _2
Facebook 探検隊: どのようなソフトウェアでスケールを達成しているのか _3

ーーーー
わずか四半期の間に、サーバー数が倍増した Facebook の事情
Facebook の HDFS クラスターは 21 PB !!!
Facebook のスケール感覚に驚愕! _1
Facebook のスケール感覚に驚愕! _2
Facebook で Office ドキュメントを共有する Docs.com を触ってみた
Microsoft TownHall : Windows Azure と Facebook の連携が始まった!
Facebook は RFID タグで、アメリカ版 お財布ケータイを狙うのか?

Advertisement

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Theme: Rubric. Get a blog at WordPress.com