We consider a cognitive radio system with one primary channel and one secondary user, and then we introduce a channel-usage pattern model and a fundamental access scheme in this system. Based on this model and fundamental access scheme, we study optimal opportunistic spectrum access problem and formulate it as an optimization problem that the secondary user maximizes spectrum holes utilization under the constraint of collision tolerable level. And then we propose a unified approach to solve this optimization problem. According to the solution of the optimization problem, we analyze and present optimal opportunistic spectrum access algorithms in several cases that the idle period follows uniform distribution, exponential distribution, and Pareto or generalized Pareto distribution. Theoretical analysis and simulation results both show that the optimal opportunistic spectrum access algorithms can maximize spectrum holes utilization under the constraint that the collision probability is bounded below collision tolerable level. The impact of sensing error is also analyzed by simulation.