France has opened an attempted murder investigation after petrol bombs were thrown at police during protests over the rising cost of living in Paris.