* Hike in prices will start from Wednesday
* Petrobras grappling with debt, corruption scandal (Adds detail, background)
RIO DE JANEIRO, Sept 29 (Reuters) - Brazil's state-run oil company Petroleo Brasileiro said on Tuesday it would raise the price of gasoline by 6 percent and diesel by 4 percent at refineries in Brazil.
The change, which will take effect on Sept. 30, comes as the firm struggles with mounting debt, falling oil prices and a giant corruption scandal.
For years Petrobras, as the company is known, imported gasoline and sold it locally at a loss in order to help the government keep a lid on inflation. But the policy led to billions of dollars in losses and contributed to making Petrobras the world's most indebted major oil company.
Bringing domestic fuel prices in line with international levels is vital to shoring up Petrobras' finances and enabling the company to sell refinery assets, sources with direct knowledge of the matter previously told Reuters.
Although international fuel prices have fallen dramatically, a 35-percent weakening of the real against the dollar this year has meant prices at the pump in Brazil remain low.
But the price increase could give a further kick to Brazil's already high rate of inflation, which economists predict will reach 9.5 percent in 2015.
Reporting by Stephen Eisenhammer; Editing by Paul Tait and Joseph Radford