If you want to buy the property get a mortgage. If you can't get a mortgage it's because the bank doesn't think you're a good risk. If the bank doesn't think so, the landlord would be ill-advised to take the risk.
I think what the OP is really describing here is that the landlord would be selling the property to the OP for X amount and also providing a loan to the OP for the same X amount. The ex landlord could then secure the loan against the property until the loan is paid off.
Obviously these are only "bookkeeping entries" No money actually changes hands. The landlord now has a loan of X amount owing from the OP but he no longer owns a house. The OP "owns" a house but he owes X amount to the ex landlord.
Coming up with the funds to pay possible CGT might make the deal unattractive to the landlord.
IMO the loan amount should also include some adjustment for lost earnings from rent and lost interest on same. Which might make it unattractive to the tenant.