Metal Sonic is a Cybernetic Replica of Sonic the hedgehog and Loyal Servent of Doctor Eggman
In secret, it enjoys robot porn.
In short, the personality was created to combat Sonic.
However, his first defeat at Sonic's hands drove him to obsession. Plus Eggman's constant losses to the Blue Blur made him question his orders.
In the span of 9 months... he would be creating his own generals: Neo Metal Sonic and Mecha Sonic, plus mass-produced versions of Knuckles Androids, Amy Woman (Robot) and eventually E-125's.
He would create the Metallix Brotherhood, dedicated to the glory of robotics and overthrowing Sonic and Eggman.
The next day, he would get his ass kicked by the mighty tag-team Warsman and Raiden AKA Team Thunder Iron.