您好,欢迎访问三七文档
当前位置:首页 > IT计算机/网络 > 网站策划/UE > myspace网站技术架构
Behind the Scenes at MySpace.comDan FarinoChief Systems Architectdan@myspace.com1Friday,November21,2008Topics•Architecture overview and history•The stuff I get to work on (in the Windows world)•Monitoring•AdministraGon22Friday,November21,2008Topics•Windows?!•It’s a good server (now leave me alone.)•However, the selecGon of tools for large‐scale management is a bit sparse...33Friday,November21,2008Where we started 4Friday,November21,2008Where we started•The ideal growth scenario•Plan•Implement•Test•Go live•Monitor and collect ops data•Repeat55Friday,November21,2008Where we started•Our growth scenario:•Implement•Go live•And while those are happening over and over:•Reboot servers•Throw hardware at performance issues•“Shotgun debugging”66Friday,November21,2008Where we started“Shotgun debugging”:Shotgun debugging is a process of making relaGvely undirected changes to soVware in the hope that a bug will be perturbed out of existence.77Friday,November21,2008Where we started•Why would anyone “shotgun debug”?•Don’t really know how to analyze and debug a problem•Need to resolve the problem now and collecGng data for analysis would take too long88Friday,November21,2008Where we started•Web servers•Windows 2000 Server•IIS 5.0•ColdFusion 5•Database servers•Windows 2000 Server•SQL Server 200099Friday,November21,2008Where we were•OperaGonally•Batch files and robocopy for code deployment•“psexec” for remote admin script execuGon•Windows Performance Monitor for monitoring1010Friday,November21,2008Where we were•Any sort of formal, automated QA process?•No.1111Friday,November21,2008Current architecture12Friday,November21,2008Current architecture•4,500+ web servers•Windows 2003/IIS 6.0/ASP.NET•1,200+ “cache” servers•64‐bit Windows 2003•500+ database servers•64‐bit Windows 2003•SQL Server 20051313Friday,November21,2008QA today•Unit tests/automated tesGng•We sGll don’t “fuzz” the site nearly as thoroughly as our users do though•There are sGll problems that happen only in producGon1414Friday,November21,2008QA today•We need beher operaGonal data collecGon so that we know what cases we’re not tesGng1515Friday,November21,2008OperaGonal Data CollecGon16Friday,November21,2008Ops Data CollecGon•Two general types of systems:•StaGc•Collect, store and alert based on pre‐configured rules•Dynamic•Write an ad‐hoc script or applicaGon to collect data for an immediate or one‐off need1717Friday,November21,2008Ops Data CollecGon•Our current “staGc” Windows Performance counter monitor:18Friday,November21,2008Ops Data CollecGon•Cons of staGc system:•RelaGvely central configuraGon managed by a small number of administrators•Bad for one‐off requests: change the config, apply, wait for data•Developer’s quesGons usually go unanswered1919Friday,November21,2008Ops Data CollecGon•Developers looking at producGon?!•Developers like to see their creaGons come to life (I know I do)•The more a developer can see once their code goes live, the more they’re going to know for V22020Friday,November21,2008Ops Data CollecGon•Cons of the dynamic system:•It’s not really a “system” at all...it’s an administrator running a script•Is a privileged operaGon: scripts are powerful and can potenGally make changes to the system•Even run as a limited user, bad scripts can sGll DoS the system2121Friday,November21,2008Ops Data CollecGon•Cons of the dynamic system:•One‐shot data collecGon is possible but learning about deltas takes a lot more code (and polling, yuck)•Different custom‐data collecGon tools that request the same data point cause duplicated network traffic2222Friday,November21,2008Ops Data CollecGon•A recent example of an ad‐hoc task using our current “dynamic” system:•get‐adservers | run‐agent ps /e 'Version: $(gcm F:\file.dll | %{$_.FileVersionInfo.FileVersion})' | select Host, Message2323Friday,November21,2008Ops Data CollecGon•Ideally, all operaGonal data available in the enGre server farm should be able to queried:•Safely•Instantly•With change‐noGficaGon2424Friday,November21,2008Ops Data CollecGon•I’d like to be able to do something like this:•SELECT CpuTime.*, ExceptionsPerSecondWHERE WebService.Status = ‘UP’AND serving = ‘profile.myspace.com’OR serving = ‘home.myspace.com’2525Friday,November21,2008Ops Data CollecGonI’d also to be able to leave that query “hanging” and be noGfied of changes like:•A selected field has changed for a known data point•A new server has come online and meets the criteria (or vice‐versa)2626Friday,November21,2008Our new operaGonal data collecGon plalorm27Friday,November21,2008Ops Data CollecGon•Our new operaGonal data‐subscripGon plalorm:•On‐demand•Supports both “one‐shot” and “persistent” modes•Can be used by non‐privileged users2828Friday,November21,2008Ops Data CollecGon•Our new operaGonal data‐subscripGon plalorm:•Eliminates the need for the consumer to poll for changes•If a data source requires polling, that operaGon is pushed as close to the source as possible2929Friday,November21,2008Ops Data CollecGon•A Client makes one TCP connecGon to a “Co
本文标题:myspace网站技术架构
链接地址:https://www.777doc.com/doc-6439784 .html