Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
The Almighty Buck Bug Software

How To Lose $172,222 a Second For 45 Minutes 327

An anonymous reader writes "Investment firm Knight Capital made headlines in 2012 for losing over $400 million on the New York Stock Exchange because of problems with their algorithmic trading software. Now, the owner of a Python programming blog noticed the release of a detailed SEC report into exactly what went wrong (PDF). It shows how a botched update rollout combined with useless or nonexistent process guidelines cost the company over $172,000 a second for over 45 minutes. From the report: 'When Knight used the Power Peg code previously, as child orders were executed, a cumulative quantity function counted the number of shares of the parent order that had been executed. This feature instructed the code to stop routing child orders after the parent order had been filled completely. In 2003, Knight ceased using the Power Peg functionality. In 2005, Knight moved the tracking of cumulative shares function in the Power Peg code to an earlier point in the SMARS code sequence. Knight did not retest the Power Peg code after moving the cumulative quantity function to determine whether Power Peg would still function correctly if called. ... During the deployment of the new code, however, one of Knight's technicians did not copy the new code to one of the eight SMARS computer servers. Knight did not have a second technician review this deployment and no one at Knight realized that the Power Peg code had not been removed from the eighth server, nor the new RLP code added. Knight had no written procedures that required such a review.'"
This discussion has been archived. No new comments can be posted.

How To Lose $172,222 a Second For 45 Minutes

Comments Filter:
  • by mythosaz ( 572040 ) on Tuesday October 22, 2013 @08:18PM (#45207925)

    I'm sure someone will chime in and claim to be the em-effing Change MASTER! but this seems like an ordinary error, the sort I've seen a hundred times before, where one server is a tiny bit wonky, and during the change, something doesn't happen as expected. Normally it's an "inexpensive" error, where some of your VPN users get randomly disconnected... ...and sometimes it's the sort of error where you lose half a billion dollars an hour by HFT trading... ...badly.

  • by Anonymous Coward on Tuesday October 22, 2013 @08:18PM (#45207931)

    This level of trading does not do the market any good, and puts individual investors at a severe disadvantage against firms like this.

    It can be stopped. And it should be stopped. And the only reason it is not being stopped is because too many rich and powerful people make too much money on it.

  • by Anonymous Coward on Tuesday October 22, 2013 @08:25PM (#45207971)

    This corporation can't send people with guns to your house to get more money. Obama Can Do It!
    This corporation can't print more money, watering down the money you yourself have, Obama Can Do It!
    This corporation won't get the smug approval of 4 out of the 5 major news outlets, Obama Can Do It!
    This corporation won't blame its losses on Bush. ...won't borrow 40 cents for ever dollar it spends, from China, leaving the mess for your kids to pay for. ...won't forward this email to 10 friends!

  • by onyxruby ( 118189 ) <onyxrubyNO@SPAMcomcast.net> on Tuesday October 22, 2013 @08:30PM (#45207993)

    No proper change management, no peer review, no proper lab testing. Dev should always reflect production to the greatest reasonable level. No proper maintenance windows. You should never be surprised by a change in production. This is a case study in incompetence and the failure to execute industry best practices. I'm guessing the guy or gal who raised the best practices flag was ignored as being inconvenient or too expensive.

    If I'd done this kind of thing when I was working with the exchanges I would have been fired in a heartbeat. Whoever failed to utilize best practices, or whoever failed to allow the utilization of best practices had damn well better have been fired. This is incompetence of the highest level and a perfect example of why ITIL based best practices were born.

  • by iserlohn ( 49556 ) on Tuesday October 22, 2013 @08:31PM (#45208007) Homepage

    The corporations (and other moneyed interests) don't have to do any of that because it pays the government du jour to do its bidding. The whole idea of representative democracy is to prevent and minimize that by introducing checks on power by the public.

  • by ShanghaiBill ( 739463 ) on Tuesday October 22, 2013 @08:45PM (#45208077)

    You are confused. "Algorithmic trading" and "High Frequency Trading" are two different things, used for two different purposes. This was caused by AT, and you are complaining about HFS. That makes no sense.

  • IT Debt (Score:5, Insightful)

    by Anonymous Coward on Tuesday October 22, 2013 @08:48PM (#45208099)

    They had some code that processed orders in a special way. There was a flag on the order they could set that would trigger that code. We will call this Power Peg. They later moved away from that functionality but it still existed in the system. It sat there for years untested and unused. 9 years later they added new functionality and decided to reuse that same flag. The new code also disabled Power Peg.

    When they pushed the new code into production, they missed a server. That missed server still had Power Peg looking for that flag. Orders started setting that flag and it was processed correctly on all but one server. But that last server was placing orders incorrectly. The logic that Power Peg used was not valid anymore. In a panic they rolled back the code on the servers. Not knowing that Power Peg was the issue, they now had all the servers running Power Peg again.

  • Re:In other news.. (Score:3, Insightful)

    by ShanghaiBill ( 739463 ) on Tuesday October 22, 2013 @08:54PM (#45208143)

    So...where did the money go?

    The money went to the people on the other side of the trades. Knight lost $400M. Many other people, accumulatively, gained $400M.

  • by Billly Gates ( 198444 ) on Tuesday October 22, 2013 @08:56PM (#45208155) Journal

    Dude, Wall Street traders demand software engineers get things done in minutes and hours!

    There is no process as it all had to be done yesterday if you ask anyone who has worked in that environment.

    They pay top dollars and change core algorithms on the fly as each millisecond costs money to a competitor who has a more efficient trading algorithm that steals from their own HTC network.

    So when when skims and manipulates the prices in milliseconds they steal from those who have process engineered designs who are too slow to react.

    If it messes up they get bailed out by the SEC anyway and they can just fire the programmer.

  • by TsuruchiBrian ( 2731979 ) on Tuesday October 22, 2013 @08:59PM (#45208169)
    The wealth that the money represented was not "lost", but rather redistributed. Efficient redistribution of wealth is a strength of the private sector not a weakness. The private sector is good at redistributing money where it needs to go for economic growth. This company was not exercising an appropriate level of caution and it's money was redistributed elsewhere.
  • by rsilvergun ( 571051 ) on Tuesday October 22, 2013 @09:09PM (#45208235)
    In the same thread where I can find 1000 people going on about how efficient capitalism is I can find another (sometimes the same) 1000 people complaining all the dumb things their companies do. Well, which one is it? It doesn't work both ways people. Could it be that people are people, no matter what banner they're organized under?
  • by techno-vampire ( 666512 ) on Tuesday October 22, 2013 @09:19PM (#45208273) Homepage
    I think you're being a tad too literal here. As far as Knight was concerned the money was lost because they didn't have it any longer and they had nothing to show for it.
  • by Anonymous Coward on Tuesday October 22, 2013 @09:22PM (#45208297)

    Capitalism produces large corporations that are very efficient at doing dumb things.

  • by RightwingNutjob ( 1302813 ) on Tuesday October 22, 2013 @09:43PM (#45208387)
    Didn't RTFA, but summary makes me go WTF in several places:
    1. Python. I thought all the quants liked C, assembler, and even VHDL for their high frequency stuff. No matter
    2. "2nd technician to review". If this were flight hardware or a bridge or skyscraper, there would be a second "technician" to review and at least one "engineer" to personally sign off that what was built/deployed is a) done right and b) is what you want
    3. "no written procedures". There are a very small number of things in life about which it is absolutely imperative to keep a rod firmly up one's ass: a. moving machinery, b. formal mathematics, and c: hundreds of millions of dollars of your clients and shareholders' money.
  • by MightyMartian ( 840721 ) on Tuesday October 22, 2013 @09:50PM (#45208417) Journal

    I'm too busy thinking about how many children with cancer could be saved for 400 million US dollars.

  • by Alan Shutko ( 5101 ) on Tuesday October 22, 2013 @09:55PM (#45208441) Homepage

    There were a number of errors made here.

    1. They failed to deploy to one of eight servers
    2. They failed to automate the deployment to the servers such that it would be impossible to deploy to all servers without knowing.
    3. They didn't have a step between code deployment and production activation where they could validate all 8 servers. For instance, in our company, we deploy the prod code to the prod servers but leave them in a "stage" environment, where the production load balancer doesn't hit those instances. Once we've validated, we then switch the load balancers to point to the correct instance.
    4. They failed to quickly back out a change when they realized it was having problems. In fact, they backed out the part on seven servers but not the flag that was being sent to the servers, which made things worse.
    5. They failed to have a risk-mitigation backstop in place which would have prevented these orders from being submitted once they hit a certain amount, and which was required by SEC Rule 15c3-5(c)(1)(i).

    There were a lot of places that you could put in a control to prevent or limit the effect of these kinds of errors, and that's the lesson people need to learn. Yes, mistakes happen! But try to make it hard to make a mistake, easy to recover from a mistake, and really easy to NOTICE a mistake.

  • by Anonymous Coward on Tuesday October 22, 2013 @10:05PM (#45208481)
    The money wasn't destroyed, it went to other traders. Maybe they will donate it to children with cancer?
  • by Waffle Iron ( 339739 ) on Tuesday October 22, 2013 @10:43PM (#45208693)

    It is usually just wasted.

    By your own previous logic, money can never be "wasted", just redistributed.

    Every dollar that the government collects in taxes or creates out of thin air is redistributed back into the private sector.

  • by Anonymous Coward on Tuesday October 22, 2013 @10:59PM (#45208783)

    No. You're basically wrong on every point you bring up.

    "Looking at what has happened in other countries, the "you're fucked" point, the point at which you can't escape the death spiral, is about 100% of GDP - when a country owes as much as it generates."

    No, there is no magic debt/GDP limit: http://krugman.blogs.nytimes.com/2013/05/26/reinhart-and-rogoff-are-not-happy/ [nytimes.com]

    "That tells us we are about six to eight years from becoming Greece."

    No, Greece doesn't have its own currency, so we are in no way the same as Greece: http://krugman.blogs.nytimes.com/2013/10/18/the-china-debt-syndrome/?_r=0 [nytimes.com]

  • by rsilvergun ( 571051 ) on Tuesday October 22, 2013 @11:15PM (#45208863)
    Um, Microsoft used borderline slave labor and a complete disregard for the environment to build the Surface pro. And not the kind of disregard that we get to ignore. It's the kind that makes 'Cancer Villages' (google it)

    And the reason your gov't is making an agency to do a contract to get something done isn't inefficiency, it's socialism. Seriously. It's make work projects to try and spread some money around because otherwise the natural tendency if for money to be hoarded at the top by a few wealthy oligarchs (we call 'em the 1% these days).

    The US Postal Service has God like efficiency. Just ask Netflix. Or just mail a letter and watch it travel across the breath of the United States in less than a week for 33 1/3 cents. The Space programs were (and are) amazing, and did things private industry couldn't hope to accomplish and that we're still reaping the benefits from today. The Gov't can be plenty efficient when it wants to be. It can also be very inefficient when it wants to. There are times when that's a good thing.
  • by Tablizer ( 95088 ) on Tuesday October 22, 2013 @11:21PM (#45208895) Journal

    The public and private sector do different things better. While the private sector is more efficient in terms of service or widgets per hour, there's also heavy pressure to trick, mislead, and rip off consumers and customers.

    Such "trick" pressure is noticeably lower in the public sector. There is relatively little pressure for a line worker and middle manager to rip off or trick customers because they don't have to compete with other cut-throat competition and are not sweating over narrow margins. They generally don't want the drama of customers sending or phoning complaints and so do an adequate job, even if a bit slow at it.

    Certain kinds of services are better under one versus the other. If it's a service where it's easy to fool customers, especially over longer-term features, then it's probably best done by or heavily regulated by the gov't. If it's something that's relatively easy for a consumer to verify the quality of, then it's probably best done by the private sector.

  • by happyhamster ( 134378 ) on Wednesday October 23, 2013 @12:52AM (#45209315)

    >> Capitalism is very effective in what it does

    Pumping the money from the poor to the rich.

  • by happyhamster ( 134378 ) on Wednesday October 23, 2013 @01:08AM (#45209379)

    >> I WORK for that agency

    So, you are a repuglican saboteur troll that takes public money and then badmouths the hand that feeds them.

    The government needs to fire repuglicans that don't believe in the system, and hire more democrats who cares and gets things done.

    The problem with the government isn't intrinsic, it's the scum that saboteurs the system on a daily basis and then walks around screaming how "it's not working". Get rid of the scum, hire decent people that believe in public good, and things work marvelously.

  • by sjames ( 1099 ) on Wednesday October 23, 2013 @01:14AM (#45209403) Homepage Journal

    Except they built in enough safeguards that they were able to debug it and get it fully operational. Having done so, it then accomplished it's mission and considerably more.

    The appropriate measure varies based on the type of risk.

  • by happyhamster ( 134378 ) on Wednesday October 23, 2013 @01:40AM (#45209499)

    Indeed, I always forget that I have the FREEDOM to be homeless, live under the stars with my wife and children, enjoy the nature, you know. Republican dream for working people.

  • by englishknnigits ( 1568303 ) on Wednesday October 23, 2013 @01:55AM (#45209547)
    There is nothing preventing governments from being efficient and they sometimes are. The problem is that there also isn't anything keeping the government from being inefficient. Companies that are run horribly inefficiently tend not to last too long because they can go out of business (obviously doesn't apply to government enforced monopolies). If the government is horribly inefficient the general punishment is that they get more funding. To summarize, natural selection operates more in a capitalist market than it does in a government. That isn't to say how natural selection operates in markets is all good but it tends to make them more efficient (child labor can be quite efficient).

    You may be right about the "make work" projects but that doesn't make it not exceedingly stupid. How about they pay their own worker to do that work and use the other money to get other things. If they do that they are providing more value for everyone while distributing money.
  • by Errol backfiring ( 1280012 ) on Wednesday October 23, 2013 @09:53AM (#45211745) Journal
    In this on-line gambling system, money has lost all its real value. One of the very problems we have now is that a bit of on-line gambling can be traded for real work. And off course, that there is so much money to be made with on-line gambling that the financial institutions have left the real economy behind long ago. Nowadays, finance has almost nothing to do with economy anymore.

They are relatively good but absolutely terrible. -- Alan Kay, commenting on Apollos

Working...