Oil and gas explorer Beach Energy said it would sell a 40 per cent stake in its Victorian Otway gas assets for $344 million and trimmed its earnings and production guidance.