I think the episode is from the "Out of the Unknown" SF series.
The plot involves a star ship that lands on a planet. There are humanoid aliens present, who appear primitive. However, when testing an alien with a thought machine, the alien seems to know how to use the equipment. In the meantime, the ships systems start to fail. The ending is that the aliens are forced to a primitive life because of metal eating bacteria that has destroyed their civilization. The star ship's systems continue to fail and lift off becomes impossible.
Does anyone know the name of the episode, and even better, the name of the story and it's author that the episode was based on?