In this paper, we study the optimization of yard operations, which are critical for the terminal efficiency. A linear mixed integer programming (MIP) model is proposed for scheduling different types of equipment and planning the storage strategy in an integrated way. We also investigate a nonlinear mixed integer programming (NLMIP) model to reduce the number of constraints and the computational time. A set of numerical results are carried out for the comparison between the linear model and the nonlinear model. Finally, we propose a genetic algorithm for the MIP model to illustrate how large scale problems can be solved and to show the effect of different factors on the performances of the optimization model.