* Qatar-backed investor fails to pay by Aug. 17 deadline
* $129 million deal hangs in balance
* Privatisation chief could face sack if deal falls through
(Rewrites with treasury ministry comments)
By Gabriela Baczynska and Pawel Bernat
WARSAW, Aug 18 (Reuters) - Poland said on Tuesday Qatar was considering to buy the country's two troubled shipyards after an investor linked to Qatari investment bank QInvest failed to complete the politically sensitive acquisition.
Poland's Treasury Ministry had announced earlier on Tuesday that an entity it said was backed by QInvest had not met the extended, Aug. 17 deadline to pay 380 million zlotys ($129 million) for the loss-making yards.
Under pressure from Brussels to sell the storied shipyards or to take back a few billion euros in Polish state aid that the European Commission has said was illegal, Poland's centre-right government agreed to sell the Szczecin and Gdynia yards to avert bankruptcy and thousands of job losses.
"I have made a decision to allow the Qatar Investment Authority the time to come up with a solution and take part instead of the previous investor," Treasury Minister Aleksander Grad told a news conference.
Grad said the Qatar sovereign fund -- which last week bought a 10 percent voting stake in Porsche SE and most of its options for a stake in Volkswagen -- had until the end of August to take on the investment.
Prime Minister Donald Tusk warned he would sack Grad, who is his privatisation chief, if the sale is not completed by Aug. 31, also the deadline set by the European Commission.
Poland's shipyards are the birthplace of the Solidarity trade union, which helped bring down the communist regime two decades ago, but they have struggled to remain viable due to bloated employment and more nimble competitors abroad.
MYSTERIOUS INVESTOR
It is unclear who made the initial offer to buy the shipyards.
Grad had said previously that QInvest, whose shareholders include Qatar Islamic Bank and Gulf Finance House, was the ultimate buyer and that QInvest was being represented in the deal by Dutch Antilles registered-entity Stichting Particulier Fonds Greenrights.
QInvest has said it is representing another entity and would not comment on client transactions.
On Tuesday, Grad pinned the decision to back out on Stichting Particulier Fonds Greenrights, saying it was due to deteriorating economic conditions, which have led to the collapse in shipping and demand for new vessels. He declined to provide further details about the buyer.
The treasury minister has denied that the shipyard transaction was connected to a gas distribution deal signed with Qatar in April.
In November, Tusk and Grad visited Qatar as part of a wider swing through the Gulf to find investors for state assets in a planned privatisation drive and find new energy sources to cut its reliance on Russian gas.
The trip resulted in a deal signed between Polish gas distribution monopoly PGNiG and Qatargas for 1 million tonnes of liquefied natural gas to be delivered to Poland annually starting in 2014.
Warsaw said at the time the deal was signed that Qatar had also expressed an interest in the privatisation of Polish state assets. (Additional reporting by John Irish in Dubai and Adrian Krajewski in Warsaw; writing by Chris Borowski; editing by Janet Lawrence, Simon Jessop and Karen Foster) ($1=2.945 Zloty)