1In a large saucepan cook potatoes, covered in boiling salted water about 5 minutes or until slightly tender but still firm. Drain and set aside.
2In a large skillet heat olive oil over medium-high heat. Add pancetta; cook until lightly browned. Using a slotted spoon, remove pancetta, reserving drippings in skillet. Set pancetta aside.
3Add onions to skillet. Cook and stir over medium-low heat about 20 minutes or until lightly browned and very tender. Remove from heat. Carefully stir potatoes and pancetta into onions in skillet.
4Lightly butter a 2 quart rectangular baking dish. Spread potato mix into prepared dish. In a medium bowl whisk together eggs and milk. Add cheese, salt, pepper and rosemary; stir until well mixed. Pour evenly over potatoes in baking dish.
5Cover and chill for at least 4 hours or up to 24 hours.
6Preheat oven to 350-degrees. Bake uncovered for 45-50 minutes or until golden and a knife inserted into the center comes out clean. Let stand 15 minutes before serving.
7This casserole may be made and served the same day by omitting the chilling step.