Sudden oak death, caused by Phytophthora ramorum, has killed millions of oak and tanoak in California since its first detection in 1995. Despite some localized small-scale management, there has been no large-scale attempt to slow the spread of the pathogen in California. Here we use a stochastic spatially explicit model parameterized using data on the spread of P. ramorum to investigate whether and how the epidemic can be controlled. We find that slowing the spread of P. ramorum is now not possible, and has been impossible for a number of years. However, despite extensive cryptic (i.e., presymptomatic) infection and frequent long-range transmission, effective exclusion of the pathogen from large parts of the state could, in principle, have been possible were it to have been started by 2002. This is the approximate date by which sufficient knowledge of P. ramorum epidemiology had accumulated for large-scale management to be realistic. The necessary expenditure would have been very large, but could have been greatly reduced by optimizing the radius within which infected sites are treated and careful selection of sites to treat. In particular, we find that a dynamic strategy treating sites on the epidemic wave front leads to optimal performance. We also find that "front loading" the budget, that is, treating very heavily at the start of the management program, would greatly improve control. Our work introduces a framework for quantifying the likelihood of success and risks of failure of management that can be applied to invading pests and pathogens threatening forests worldwide.Phytophthora ramorum | constrained budget | landscape-scale stochastic epidemiological model | optimizing disease control | risk aversion