Guru Hargobind lost his eldest son Baba Gurdita in 1638. Shah Jahan attempted political means to undermine the Sikh tradition, by dividing and influencing the succession. The Mughal ruler gave land grants to Baba Gurdita's eldest son Dhir Mal, living in Kartarpur, and attempted to encourage Sikhs to recognise Dhir Mal as the rightful successor to Guru Hargobind. Dhir Mal issued statements in favour of the Mughal state, and critical of his grandfather. Guru Hargobind died at Kiratpur Rupnagar, Punjab, on 28 February 1644, but before his death, he rejected his eldest grandson Dhir Mal's politics, and nominated Guru Har Rai (Dhir Mal's younger brother) instead to succeed him as the Guru. The pattern was repeated when Guru Har Rai chose his second son as his successor instead of his eldest son.