You use whom as the object of a verb in formal English. When you do so, you generally use the whom after the necessary preposition. So the sentence should be:
To whom did he get married?
However, it's very common to use who instead of whom as the object of a verb, especially in informal English. In this case, we use the preposition at the end of a sentence as follows:
Who did he get married to?
You can also say Who did he marry? But the use of the phrase "get married" is more common.
As for the first sentence "Whom have he got married to?, it's ungrammatical; you don't use have for the third person. You use has for he.
So the right sentence is:
To whom has he got married?