WASHINGTON (AP) — Federal Reserve Chair Jerome Powell warned Thursday that Russia’s invasion of Ukraine, which has already driven up oil prices, will likely further magnify the high inflation that has engulfed the U.S. economy.

At the same time, Powell said he is committed to doing whatever it will take to slow inflation, underscoring the Fed’s high-risk challenge in raising interest rates enough to stem price increases without tipping the economy into another recession.

The Fed chair, addressing the Senate Banking Committee on his second day of semiannual testimony to Congress on interest rate policies, stressed his belief that the economy is strong enough to withstand higher borrowing costs. His expression of confidence echoed his testimony Wednesday that the Fed can engineer a “soft landing” in which the economy would slow enough to ease inflation even while hiring and growth remain healthy.

“Commodity prices have moved up — energy prices, in particular,” Powell said when asked about the economic consequences of Russia’s invasion of Ukraine. “That’s going to work its way through the U.S. economy. We’re going to see upward pressure on inflation, at least for a while.”

Consumer prices are already rising at their fastest pace in four decades, having jumped 7.5% in January compared with 12 months earlier. Gas prices, a key driver of that increase, have soared 40% over the past year. In the view of most economists, the surge in inflation is largely a consequence of a shortage of labor and components resulting from bottlenecked supply chains, much of it resulting from the global economy’s swift rebound from the pandemic recession.

Price spikes, though, have also spread to areas such as rents and restaurant meals, where rapid economic growth and higher wages are driving up costs.

Responding to a question from Sen. Steve Daines, a Montana Republican, Powell noted that inflation is generally thought to rise about 0.2 percentage point for each $10 increase in the price of a barrel of oil. Oil prices have surged by $40 a barrel since early December to about $110, suggesting that overall inflation will be higher than it would otherwise be in the coming months.

Sen. Richard Shelby, an Alabama Republican, urged Powell to do “what it takes” to control inflation. He praised Paul Volcker, who led the Fed in the early 1980s and who sharply increased the Fed’s benchmark short-term rate to choke off the double-digit inflation of the 1970s. Volcker’s actions also led to a deep recession in 1981-82.

Shelby asked Powell whether he, like Volcker, was willing to be “draconian” to “get the inflation under control and protect price stability.”

Powell replied that Volcker was the “greatest economic public servant of the era” and added that, “I hope history will record that the answer to your question is yes.”

But Powell stressed his belief that the Fed can bring down inflation without triggering a recession. The economy grew last year at the fastest pace since the 1980s, the Fed chair noted, the unemployment rate is at a low 4% and hourly pay is rising steadily, before adjusting for inflation.

Job openings are near a record high, Powell added, and Americans are quitting their jobs at a record pace, usually for better, higher-paying positions.

“This is a great labor market for workers, particularly for workers” among those in the lowest one-quarter of incomes, he said. For these workers, pay gains over the past two years have slightly exceeded price increases, according to research by the Federal Reserve Bank of Dallas.

On Wednesday, Powell had said that he would propose a quarter-point rate hike at the Fed’s next meeting in two weeks, which would be the first rate increase since 2018. The Fed chair repeated Thursday that if inflation didn’t decline this year as he expects, he is open to bigger hikes at some later central bank meeting this year.

Powell testified to Congress in his capacity as acting chair, after his term officially expired in February. President Joe Biden has nominated Powell to a second four-year term. But his appointment, along with those of four other nominees to the Fed’s Board of Governors, has been delayed by Republican opposition to one nominee, Sarah Bloom Raskin, as the Fed’s top banking regulator.

Republicans on the committee have boycotted a vote on all Biden’s nominees, including Powell, because of their opposition to Raskin, who they say would use the Fed’s regulatory authority to discourage banks from lending to oil and gas companies. Democrats, as well as many banking executives, counter that Raskin’s views aren’t out of the mainstream and that she simply wants the Fed to consider the risks that climate change poses to the financial system.