The federal government took control of Pasadena-based IndyMac Bank on Friday in what regulators called the second-largest bank failure in U.S. history.

Citing a massive run on deposits, regulators shut its main branch three hours early, leaving customers stunned and upset. One woman leaned on the locked doors, pleading with an employee inside: “Please, please, I want to take out a portion.” All she could do was read a two-page notice taped to the door.

The bank’s 33 branches will be closed over the weekend, but the Federal Deposit Insurance Corp. will reopen the bank on Monday as IndyMac Federal Bank, said the Office of Thrift Supervision in Washington. Customers will not be able to bank by phone or Internet over the weekend, regulators said, but can continue to use ATMs, debit cards and checks. Normal branch hours, online banking and phone banking services are to resume Monday.

(Article continues below)

Federal authorities estimated that the takeover of IndyMac, which had $32 billion in assets, would cost the FDIC $4 billion to $8 billion. Regulators said deposits of up to $100,000 were safe and insured by the FDIC. The agency’s insurance fund has assets of about $52 billion.

IndyMac’s failure had been widely expected in recent days. As the bank was shuttering offices and laying off employees to cope with huge losses from defaulted mortgages made at the height of the housing boom, nervous depositors were pulling out $100 million a day. The bank’s stock price had plummeted to less than $1 as analysts predicted the company’s imminent demise.

The takeover of IndyMac came amid rampant speculation that the federal government would also have to take over lenders Fannie Mae and Freddie Mac, which together stand behind almost half of the nation’s mortgage debt.