Answer:
The idiom compares the hollow inside of an object like a drum (or ship or can) and its loud sound with the empty thoughts of an ignorant person and his or her talkative nature. People typically use this expression when they want to discredit someone who is making their opinion widely known.