The Facebook Blog
You may have heard that we just unveiled the next evolution of Facebook Platform. Our new stuff will be going live sometime tonight, so definitely stay tuned on the site and on the blog for more information tomorrow.
Facebook users love our photos application, it's one of the most popular areas on the site. The cool front-end features—like upload, tagging, and editing—are great, but I'd like to take a moment and talk about our photo infrastructure. It's the part of our photos feature that users never see, but it quietly works 24 hours a day to quickly serve all those photos to millions of users.
Allow me to geek out and share some photo infrastructure statistics with
you. We have:
(For you sharp-eyed geeks out there, we actually store four image sizes for each photo, so if you want to know how many files we have, multiply the photo numbers by four. That's right, we're adding a quarter billion files every week.)
And that's just the storage side of things. We also have a fleet of servers who receive your photo uploads, happily scrubbing out EXIF data and tweaking the quality settings so your photos look their best. Another fleet of servers and caches who feed images to our CDN (content delivery network) partners. And hey, if we feel like it, we can serve some of the photo traffic directly ourselves too.
We have also developed our own specialized web servers that are tuned to serve files with as few disk reads as possible. Even with thousands of hard drive spindles, I/O (input/output) is still a concern because our traffic is so high. Our squid caches help reduce the load, but squid isn't nearly fast or efficient enough for our purposes, so we're writing our own web accelerator too.
That's just a taste of the current photo infrastructure, and while the system we've got is pretty sweet, there are even bigger things to come. Browser-side sampling of image response times so we can immediately know when ISPs are having issues, automated balancing of load between CDNs and the Facebook network (why pay a CDN to serve images in the middle of the night when we've got a huge photo serving tier that's quiet at that time?), better image performance for our international users, the list goes on and on...
Doug has a bet with the storage team that Facebook will have a petabyte of photos before April 2008, so please don't let him down.
Allow me to geek out and share some photo infrastructure statistics with
you. We have:
- 1.7 billion user photos
- 2.2 billion friends tagged in user photos
- 160 terabytes of photo storage used with an extra 60 terabytes available
- 60+ million photos added each week which take up 5 terabytes of disk space
- 3+ billion photo images served to users every day
- 100,000+ images served per second during our peak traffic windows
(For you sharp-eyed geeks out there, we actually store four image sizes for each photo, so if you want to know how many files we have, multiply the photo numbers by four. That's right, we're adding a quarter billion files every week.)
And that's just the storage side of things. We also have a fleet of servers who receive your photo uploads, happily scrubbing out EXIF data and tweaking the quality settings so your photos look their best. Another fleet of servers and caches who feed images to our CDN (content delivery network) partners. And hey, if we feel like it, we can serve some of the photo traffic directly ourselves too.
We have also developed our own specialized web servers that are tuned to serve files with as few disk reads as possible. Even with thousands of hard drive spindles, I/O (input/output) is still a concern because our traffic is so high. Our squid caches help reduce the load, but squid isn't nearly fast or efficient enough for our purposes, so we're writing our own web accelerator too.
That's just a taste of the current photo infrastructure, and while the system we've got is pretty sweet, there are even bigger things to come. Browser-side sampling of image response times so we can immediately know when ISPs are having issues, automated balancing of load between CDNs and the Facebook network (why pay a CDN to serve images in the middle of the night when we've got a huge photo serving tier that's quiet at that time?), better image performance for our international users, the list goes on and on...
Doug has a bet with the storage team that Facebook will have a petabyte of photos before April 2008, so please don't let him down.
If you were to check out the Toronto, ON network page, you'd notice that the Toronto network has over half a million members—a huge chunk of the explosive growth Facebook has recently seen in Canada (2 million Canadian users—or 10% of the Facebook population—and counting).
Soon after the launch of network pages, I started a new topic on the Toronto Discussion Board where I asked Torontonians what factors they thought contributed to the growth of the Toronto Facebook network. Since then, several enthusiastic members have posted their theories, ranging from the GTA (Greater Toronto Area) coverage, and word of mouth, to the explosive media coverage Facebook has been receiving.
Soon after the launch of network pages, I started a new topic on the Toronto Discussion Board where I asked Torontonians what factors they thought contributed to the growth of the Toronto Facebook network. Since then, several enthusiastic members have posted their theories, ranging from the GTA (Greater Toronto Area) coverage, and word of mouth, to the explosive media coverage Facebook has been receiving.

How does growth in Canada compare to other non-U.S. countries? This graph shows weekly shares of total users by country of affiliation for non-U.S. users. Since the beginning of 2007, the number of Canadian users has nearly doubled in relative presence on Facebook!
There may not be one single reason why Facebook is so popular in Canada, but rather a combination of tipping-point factors that continue to make networks like Toronto so unique in terms of growth. The best part is that as more people in Toronto join, the more relevance Facebook has for everyone involved, as it becomes more and more likely that all your friends are members. On behalf of all the Facebook Team, and as the resident Canadian, I want to say "Thanks Canada!".
P.S. A little internet video that made the rounds in the US in the last few months is now circulating in Canada. Just so everyone knows, Facebook is not selling any of your information. It never has and never will. Period.
Nico, Facebook's Privacy Engineer, is a fan of Rush, The Tragically Hip, Blue Rodeo, Cowboy Junkies, and Leonard Cohen.
As of today, Facebook has fully rolled out our new Marketplace feature. You can use Marketplace to list what you have and what you want within your group of friends, networks, or other networks. Beyond its use for classified listings, you can use Marketplace to get a sense of everything available or desired within your networks.
Your listings in Marketplace can be anything—books and DVDs you don't need anymore, the dream job you are looking to land, or the special requirements it takes just to be your roommate—but one thing remains the same; you have something to offer, and someone else is probably looking for that thing.
Your listings in Marketplace can be anything—books and DVDs you don't need anymore, the dream job you are looking to land, or the special requirements it takes just to be your roommate—but one thing remains the same; you have something to offer, and someone else is probably looking for that thing.

For Sale: Cute Dog
You can create a listing for basically anything, and you can easily track your connections to other people in Marketplace. This means that the next time you want to buy something, you can ask a mutual friend of the seller if she is the type to scratch CDs or let the cat have free reign over the sofa bed. As always, you have complete control over your privacy and the privacy of your listings.
Lastly, it's important to note that this idea was catalyzed by a mock-up built entirely in Excel by Josh Pritchard. Tell him thanks when you sell your fuzzy sticker collection.
Jared, a PM and Designer at Facebook, can't imagine making a whole mock in Excel. Seriously.
In a previous post titled "The Spirit of Openness," Steven Grimm wrote about the various open source projects we use and contribute to at Facebook. We wanted to give everyone some "down and dirty" details on a couple of those projects, specifically relating to the PHP community.
You might have noticed that the user-facing portion of Facebook is written in PHP, and we're fortunate enough to be able to make contributions back to some PHP related projects. Most of our contributions (so far) have been towards an optimization extension called the Alternative PHP Cache (APC). Some of this code includes faster locking mechanisms like Futex locks, POSIX mutex locks, and porting spin locks from the PostgreSQL project. Some changes are bug fixes rather than enhancements, like bug #7816 and #8663 (a configuration and file update bug which never really affected Facebook directly, but we're happy to help).
We've added new caching statistics to help engineers learn what's being effectively cached and what's not. Our own opcode copy optimizations significantly cut down Facebook load and response time last month. We also added multi-key fetches, faster statistics, and a cool apc_compile_file function. We get to sneak in occasional patches to other PHP related projects like a PHP foreach bug, a "script" option for xdebug, and PHP-5.2 compatibility for APD. These changes cut down on the number of bugs engineers have to deal with, and give them new functionality for measuring site performance.
When site performance and technology is core to what you do, like it is at Facebook, having control over changes of every aspect of the site is crucial. Facebook runs with some modifications to projects like PHP that aren't stable or generic enough for inclusion in a public release (although we do our best to make these available). Having people available that work on programming languages, caches, or storage facilities gives Facebook a distinct edge over other sites that aren't as concerned about end user experience or being part of an open source community.
If you're interested in more information on open source projects, check out ohloh.net. You can see statistics on APC and PHP as well as many other projects like memcached, another project we are proud to contribute to. There are many people that come together to make these projects a reality, and it's awesome to be part of something that affects so many people. Getting involved in open source projects is a great way to learn and become part of a larger community. Finding a company that understands this as well is even better.
Brian Shire, an engineer at Facebook, is working on fixing some PHP bugs.
You might have noticed that the user-facing portion of Facebook is written in PHP, and we're fortunate enough to be able to make contributions back to some PHP related projects. Most of our contributions (so far) have been towards an optimization extension called the Alternative PHP Cache (APC). Some of this code includes faster locking mechanisms like Futex locks, POSIX mutex locks, and porting spin locks from the PostgreSQL project. Some changes are bug fixes rather than enhancements, like bug #7816 and #8663 (a configuration and file update bug which never really affected Facebook directly, but we're happy to help).
We've added new caching statistics to help engineers learn what's being effectively cached and what's not. Our own opcode copy optimizations significantly cut down Facebook load and response time last month. We also added multi-key fetches, faster statistics, and a cool apc_compile_file function. We get to sneak in occasional patches to other PHP related projects like a PHP foreach bug, a "script" option for xdebug, and PHP-5.2 compatibility for APD. These changes cut down on the number of bugs engineers have to deal with, and give them new functionality for measuring site performance.
When site performance and technology is core to what you do, like it is at Facebook, having control over changes of every aspect of the site is crucial. Facebook runs with some modifications to projects like PHP that aren't stable or generic enough for inclusion in a public release (although we do our best to make these available). Having people available that work on programming languages, caches, or storage facilities gives Facebook a distinct edge over other sites that aren't as concerned about end user experience or being part of an open source community.
If you're interested in more information on open source projects, check out ohloh.net. You can see statistics on APC and PHP as well as many other projects like memcached, another project we are proud to contribute to. There are many people that come together to make these projects a reality, and it's awesome to be part of something that affects so many people. Getting involved in open source projects is a great way to learn and become part of a larger community. Finding a company that understands this as well is even better.
Brian Shire, an engineer at Facebook, is working on fixing some PHP bugs.
Publicações Arquivadas por Data
2009
Novembro (12)
Outubro (17)
Setembro (10)
Agosto (10)
Julho (10)
Junho (13)
Maio (13)
Abril (13)
Março (14)
Fevereiro (13)
Janeiro (8)
2008
Dezembro (15)
Novembro (14)
Outubro (12)
Setembro (9)
Agosto (2)
Julho (3)
Junho (6)
Maio (5)
Abril (6)
Março (2)
Fevereiro (4)
Janeiro (3)
2007
Dezembro (4)
Novembro (4)
Outubro (1)
Setembro (3)
Agosto (4)
Julho (4)
Junho (2)
Maio (5)
Abril (9)
Março (8)
Fevereiro (7)
Janeiro (4)
2006
Dezembro (3)
Novembro (6)
Outubro (5)
Setembro (7)
Agosto (4)
Archived Posts by Blogger
Abraham Cooper (1)
Adam Conner (4)
Adam Hupp (1)
Aditya Agarwal (2)
Akhil Wable (1)
Alex Moskalyuk (1)
Alexandre Roche (3)
Alok Menghrajani (1)
Annie Ta (2)
Ari Steinberg (2)
Arjun Banker (1)
Austin Haugen (1)
Barbara Fischkin (1)
Barry Schnitt (1)
Benjamin Ling (1)
Bikash Agarwalla (1)
Blair Heuer (1)
Blaise DiPersia (1)
Blake Chandlee (1)
Bo Hong Deng (1)
Bob Trahan (2)
Brian Shire (1)
Brynn Shepherd (1)
Cameron Marlow (1)
Carl R. Augusto (1)
Carolyn Abram (11)
Cat Lee (3)
Chad Little (2)
Chengos Lim (1)
Chris Cox (2)
Chris Hughes (2)
Chris Kelly (4)
Chris Putnam (3)
Chris Ward (1)
Craig Donato (1)
Dan Rose (1)
Daniel Chai (1)
Danna Gutman (1)
Dave Fetterman (1)
Dave Morin (1)
Doug Beaver (2)
Dustin Moskovitz (1)
Elizabeth Linder (2)
Elliot Schrage (2)
Eric Kwan (1)
Eric Zamore (1)
Evan Priestley (1)
Everett Katigbak (1)
Ezra Callahan (8)
Florin Ratiu (1)
Gareth Davis (1)
Gene Fant (1)
Ghassan Haddad (1)
Gibson Biddle (1)
Graeme Menzies (1)
Harry Huai Wang (4)
Henri Moissinac (1)
Jack Lindamood (1)
Jake Brill (1)
James Wang (2)
Jared Cohen (1)
Jason Min (1)
Jason Sobel (1)
Jeff Kanter (1)
Jeff Williams (1)
Jeffrey Wieland (1)
Jesse Dwyer (1)
Jessica Ghastin (1)
Jimmy Lavoie (1)
Joanna Lee (1)
Joe Green (1)
Joe Hewitt (3)
Joe Sullivan (1)
Joel Seligstein (1)
Jon Fougner (2)
Jon Warman (2)
Jonathan Hsu (1)
Josh Elman (1)
Josh Wiseman (2)
Julie Trescott (1)
Julie Zhuo (2)
Justin Bishop (1)
Justin Mitchell (1)
KC Estenson (1)
Kari Lee (1)
Kate Losse (3)
Kathy H. Chan (4)
Katie Carter (2)
Katie Geminder (6)
Kevin Arata (1)
Kevin Der (1)
Leah Pearlman (5)
Lee Byron (1)
Lisa P. Jackson (1)
Liz Perle (1)
Luke Shepard (1)
Makinde Adeagbo (1)
Malorie Lucich (1)
Marcia Velencia (1)
Mark Kinsey (2)
Mark Slee (9)
Mark Zuckerberg (18)
Matt Cahill (1)
Max Kelly (3)
Melissa Luu-Van (1)
Melody Quintana (1)
Michael B Kaiser (1)
Michael Gummelt (1)
Michael Richter (1)
Mike Honda (1)
Naomi Gleit (4)
Natalie Minor (1)
Navid Mansourian (1)
Nico Vera (3)
Nikki M. Flatley (1)
Paul C. Jeffries (1)
Paul Janzer (1)
Paul McDonald (1)
Pedram Keyani (1)
Pete Bratach (1)
Peter X. Deng (2)
Philip Fung (3)
Prashant Malik (1)
Randi Zuckerberg (5)
Raylene Yung (1)
Richard Allan (1)
Rob Goodlatte (1)
Robert Johnson (1)
Roddy Lindsay (2)
Ruchi Sanghvi (1)
Ryan McGeehan (3)
Sam O'Rourke (1)
Sameer Moidu (1)
Sandra Liu Huang (1)
Sara Lannin (3)
Sasha Rosse (1)
Scott Marlette (1)
Scott Mills (1)
Shaun King (1)
Shervin Pishevar (1)
Sheryl Sandberg (1)
Simon Axten (3)
Sophia Huang (1)
Steven Grimm (1)
Suzie White (1)
Ted Ullyot (1)
Teddy Underwood (1)
Tim Sparapani (1)
Tom Occhino (1)
Tom Whitnah (4)
Victor Valdez (1)
Wayne Chang (3)
Will Chen (3)
Xenia Nosov (1)
Yair Landau (1)
Yishan Wong (1)





