Marathon Petroleum has pushed back the restart of its 240,000-barrel-per-day refinery in Catlettsburg, Kentucky, due to problems with a hydrogen plant, a state environmental official said.

The hydrogen plant, owned and operated by Air Products and Chemicals, was shut down along with all the units at the adjacent refinery after a power substation caught fire, officials from both companies said.

The hydrogen plant was restarted, but the company shut it again to correct issues related to the fire before restarting it, Air Products spokesman Art George said.

That unexpected snag delayed Marathon’s plans to begin restarting the units, an official with Kentucky’s Department of Environmental Protection said.

“It was believed that the units would have already been starting back up,” the official said in an email, adding that the units remained shut or idled.

Hydrogen is required to run many of the refinery’s units, the source said.

Marathon now hopes to begin restarting units, but it is expected to take days before the refinery is running at full rates, according to a source familiar with the plant’s operations. A Marathon spokeswoman declined to comment.

The unexpected outage, which comes as refiners are enjoying high profit margins and are pushing plants to capture profits in the final weeks of the summer driving season, has caused Midwest gas prices to rise on fears of a tight market.

In recent years, the refinery has relied on medium-grade imports from Canada and Saudi Arabia for its crude diet, according to the US Energy Information Administration.

In May, the latest month for which data is available, the refinery imported roughly 40,000 bpd of medium-grade crude from Saudi Arabia and about 14,000 bpd from Canada.