These days container transportation is one of the fastest and cheapest ways to carry the cargoes with an extent volume. Some features of maritime transportation are reducing loading and unloading costs, reducing transportation risk, better using of deck space and etc. In this paper we use a simulation optimization model to make a better assignment of facilities cooperating in loading and unloading operation (LUO) at berth in order to minimize the ships waiting time. To validate the experiments, a real case study is taken. The case is one of the national container terminals in Iran named “Shahid Rajaee” which has been located near the Persian Gulf. Comparing the output of the model and real data implies the good efficiency of the model.