I develop in almost exactly the same environment except I use MAMP Pro rather than the inbuilt Apache Server.
I also had trouble with this issue and what I ended up doing was adding an extra page to the checkout process that stored the order before transferring to the checkout success page and then putting this code at the top of my checkout_success.php file
// Initialize the session.
//store the sessions required for this page
$userSession = $_SESSION['clientID'];
$orderNumber = $_SESSION['orderID'];
//reset user session
$_SESSION['clientID'] = $userSession;
$_SESSION['orderID'] = $orderNumber;
Then pull the order and customer information from the database to display on the page and at the bottom of the page destroy the remaining session variables.