Q: Rattling noise on 2003 Nissan Maxima

Rookie cbe0621eac06868b3efe0d8d1d3611e23c60d3114864ea2ec19a68cfbd3eebab
My car makes a rattling noise when accelerating between 1000 & 2000 rpms or going up a hill it goes away after.
I have no check engine light or codes.The noise sounds like marbles in a soda can and also sounds like a diesel truck when accelerating.
(1) Answer
Are you using regular gas (87 octane)? If you are that may be the problem. The Maxima is intended to use Premium gas (92 octane). From your description of when it happens I believe the rattling you hear could ignition pinging. The higher the octane the more resistant to this. Try running the high octane this may just "fix" the problem.
On the other hand the diesel truck description sounds like a connecting rod knock which is serious and may signal the engine is on it's way out. Sorry I can not be more specific but I am not there listening with you.