LOS ANGELES — The quiet summer campus of UCLA found itself suddenly steeped in water and chaos after a major water pipe burst and spewed some 8 million gallons, stranding people in parking garages and flooding the school’s storied basketball court less than two years after a major renovation.
The 30-inch, nearly century old pipe burst Tuesday afternoon under nearby Sunset Boulevard, sending water 30 feet into the air, opening a 15-foot hole in the street and inundating part of the campus that soon was swarmed with police and firefighters.
‘‘Unfortunately UCLA was the sink for this water source,’’ UCLA Chancellor Gene Block said.
The break came amid a historic drought when residents are being threatened with $500 fines for overuse.
‘‘We lost a lot of water, around 35,000 gallons a minute, which is not ideal in the worst drought in the city’s history,’’ City Councilman Paul Koretz said.
The flooding hit the part of campus that is home to its athletic facilities, with the greatest danger coming in a pair of parking structures that quickly began filling with water.
Firefighters, some using inflatable boats, saved at least five people who were stranded in the structures where more than 100 cars were stuck, city fire officials said. No injuries were reported.
Water cascaded to the entrance of Pauley Pavilion, considered one of college basketball’s shrines since it was built in 1965, then poured on to the court named for legendary coach John Wooden and his wife Nell.
The arena — where Kareem Abdul-Jabbar, Bill Walton, Reggie Miller and Kevin Love starred — underwent a $132 million renovation that was completed in October 2012. At least an inch of water covered the floor Tuesday night, and its locker rooms also were flooded.
‘‘It’s painful. It’s painful,’’ Block said. ‘‘We just refurbished Pauley just a few years ago. And it’s a beautiful structure. It’s of course, a symbolic structure for this entire campus.’’
Athletic Director Dan Guerrero said the floor would be cleared of water overnight and the damage assessed Wednesday.
The school may need to make contingency plans, but ‘‘luckily we’re not in the middle of basketball season,’’ Administrative Vice Chancellor Jack Powazek said.
The other two campus buildings damaged were the Wooden Center, which has training facilities for students, and the J.D. Morgan Center, which houses the school’s sports trophies, hall of fame and athletics offices.
Many students took the flooding in stride, walking calmly across campus with their backpacks in ankle-deep water.
Paul Phootrakul of the UCLA Alumni Association, who was in business attire for an evening event, took off his dress shoes and dress socks, and rolled up his slacks in an attempt to wade to his car, which was on the bottom floor of one of the flooded structures. Firefighters stopped him, saying the structure was unsteady because of the weight of all the water.
‘‘I don’t have much hope for my car,’’ Phootrakul said.
Some saw a chance for fun, pulling out body boards and attempting to ride down the flowing water.
Patrick Huggins and Matthew Bamberger, two 18-year-olds who live in nearby Westwood, said they were having a dull summer day until Huggins’ mother told them about the water.
‘‘It was about up to my thigh, and I thought, ‘This is a good day for a little dip,’’’ Huggins said.
The two shot video of themselves diving and splashing in the badly flooded practice putting green used by the golf team.
The 93-year-old high-pressure line of riveted steel pipe spewed a geyser of water for about 3 ½ hours before it could safely be shut down without causing more damage, said Jim McDaniel of the Department of Water and Power.
Crews struggled to get to the area at rush hour, and they had to research which valves to shut off without affecting service, McDaniel said. Some water service was briefly interrupted but quickly restored.
There was no immediate word on the cause.
McDaniel said there was no ‘‘magic technology’’ to determine when a new line is needed, and the city is on a replacement cycle of over 300 years for main lines.
‘‘Every city that has aging infrastructure has issues like this, and we’re no exception.’’
Repairs to the pipe and to Sunset Boulevard were expected to last well into Wednesday, McDaniel said.
Associated Press writers Bob Jablon, Beth Harris and Andrew Dalton contributed to this story.