Cook orzo according to the package instructions, drain and place in a large mixing bowl or back into the empty pot. Immediately add freshly grated parmesan cheese into the bowl with pasta before pasta cools. Mix well until cheese is melted and pasta is all coated.
While pasta is cooking, you can prepare mushrooms and shallots. Peel and thinly slice shallots. Wash and thinly slice mushrooms.
Preheat a large cooking pan over medium heat and add olive oil.
Add onions and sauté until softened. Add mushrooms, season with some salt and pepper and cook until mushrooms are done.
Add cooked mushrooms and shallots to the bowl with parmesan orzo. Mix well. Taste to see if you need more salt. Stir in truffle oil, if using, and remember that truffle oil is quite potent, so start with 1 tsp and taste to see if it's enough before adding more.)(If you feel like you need to, you can add a dash of olive oil to the pasta.)