Greetings David;
The problem you are seeing is with a plumbing fitting called a Studor Valve..[aka AAV]
it's used instead of a vent to the out side...
There is a spring in it, and it could rattle...
Depending on the make or model of the valve it could unscrew or disassemble..
It's important to keep sewer gases out of the cabin..
You can find them at Home Depot for less than $10...

Take Care
Tony