Existing goodwill in the books must be written off among all partners in their old profit sharing ratio 7:4:4 (total 15).
B's share of existing goodwill = 30,000×154=8,000.
Hence B's Capital A/c will be debited by Rs. 8,000 at the time of retirement for writing off existing goodwill.