John Elley was the son of a Holburn eating-house keeper who had joined the ranks of the RHG and received a cornetcy in 1791. I believe he enjoyed a Home Staff appointment as a general officer in the years after Waterloo.
Harry was the son of a surgeon. His father may have had some money. In any event all Harry had to do was deposit the difference between his current commission and the one he wanted to purchase and not the full purchase price of the new commission.
The reason given for not awarding him a peerage, after Sir Harry's victories in South Africa, was that he did not have the private means to support a title and the government was not prepared to either award him a sum to do so or a pension.
Elley would make an excellent study, I think. Sort of like William Robertson ['Orace you're for 'ome!].