In 1854, the sultan of Selangor Sultan Muhammad Shah appointed Raja Abdullah bin Raja Ja'afar as governor of the Klang Valley. Raja Abdullah and his brother Raja Juma'at had previously helped Raja Sulaiman settle a debt incurred during a failed mining venture, and was therefore rewarded with the governorship of the Klang Valley.[1][2] Raja Mahdi (alternately Raja Mahadi), the grandson of Sultan Muhammad Shah, was the son of Raja Sulaiman who previously served as governor of the Klang Valley; Raja Mahdi hence became disinherited with Raja Abdullah's appointment to the post.