The man who led the auto bailout tells about his shock at the state of the carmaker's finances and management.

(Fortune) -- Without any experience in automaking or government, Steven Rattner left his Wall Street perch to wade into the largest restructuring in American history. The scale and
speed of the rescue raised many questions, inspiring Rattner to write this account of a defining moment in capitalism.

Rattner, who led the group that did the hands-on work, believes passionately that the decision to intervene represented not "creeping socialism," as some feared, but a critical part of
the effort to prevent economic collapse.In an excerpt from this Fortune exclusive, Rattner gives a behind-the- scenes look at the ouster of GM's Rick Wagoner:

Everyone knew Detroit's reputation for insular, slow-moving cultures. Even by that low standard, I was shocked by the stunningly poor management that we found, particularly at GM, where
we encountered, among other things, perhaps the weakest finance operation any of us had ever seen in a major company.

For example, under the previous administration's loan agreements, Treasury was to approve every GM transaction of more than $100 million that was outside of the normal course. From my
first day at Treasury, PowerPoint decks would arrive from GM (we quickly concluded that no decision seemed to be made at GM without one) requesting approvals. We were appalled by the
absence of sound analysis provided to justify these expenditures.

The cultural deficiencies were equally stunning. At GM's Renaissance Center headquarters, the top brass were sequestered on the uppermost floor, behind locked and guarded glass doors.
Executives housed on that floor had elevator cards that allowed them to descend to their private garage without stopping at any of the intervening floors (no mixing with the drones).

In my relatively few interactions with chairman and CEO Rick Wagoner, I found him to be likable, dedicated, and generally knowledgeable. But Rick set a tone of "friendly arrogance" that
seemed to permeate the organization.

Certainly Rick and his team seemed to believe that virtually all of their problems could be laid at the feet of some combination of the financial crisis, oil prices, the yen-dollar
exchange rate, and the UAW.

It seemed completely obvious to us that any management team that had burned through $21 billion of cash in a year and another $13 billion in the first quarter of 2009 could not be allowed
to continue. Equally important, GM's February viability plan was more "business as usual" and not the aggressive new approach that we felt was essential.

In a mid-March meeting with Rick, I explored his feelings about his team and then tried to work the conversation around to himself. "I'm not planning to stay until I'm 65 but I think I've
got at least a few years left in me," said Wagoner, 56. "But I told the last administration that if my leaving would be helpful to saving General Motors, I'm prepared to do it." He added
that neither he nor his board thought that was a good idea.

I left my conversation with Rick at that. The next day, I met with Rick's deputy, Fritz Henderson. Another GM lifer (and son of a GM lifer), Fritz conveyed more energy and openness to
change. The question for us was whether GM would be better off with Fritz or with an outsider, as Ford (F, Fortune 500) had done in bringing in Boeing executive Alan Mulally. While nervous
about whether Fritz could bring the change GM desperately needed, I was considerably more nervous about the likelihood of recruiting a thoroughbred CEO in the midst of the turmoil.

Meanwhile, if ever a board of directors needed shuffling, it was GM's, which had been utterly docile in the face of mounting evidence of looming disaster. We decided to recommend to Tim,
Larry, and ultimately the President a package that would include replacing Rick with Fritz as interim CEO, changing at least half of the board, and making an
outside director chairman (which should be universal).