Greek MPs failed on Tuesday to elect a president in a second vote in parliament, bringing an early general election a step closer.