Preheat oven to 350 degrees, spray a 9x13 casserole baking dish with non-stick cooking spray and set aside.
In a large skillet over medium heat, cook the ground beef. Drain excess grease, add the diced onions, and cook for a few minutes until the onion is soft. Add all of the marinara sauce and diced tomatoes to the meat mixture and stir to combine. Set aside.
Cook spaghetti according to package instructions, just al dente. Drain and rinse.
Combine cream cheese, sour cream, and ricotta in a bowl and mix well.
Pour half of the pasta into the prepared baking dish, and add half of the meat sauce.
Spoon the cream cheese mixture on top of the sauce. Top with the rest of the noodles.
Add the rest of the meat sauce on top of the noodles and smooth into an even layer. Top with mozzarella cheese and parmesan cheese.
Cover with aluminum foil, place in the preheated oven for 30 minutes, remove the foil, and continue cooking for 10 minutes or until the casserole is hot and bubbly. Remove and let rest for 15 minutes.