In an effort to reduce switch cost, we present the optimum numbers of tunable wavelength converters (TWCs) and internal wavelengths required for contention resolution of asynchronous and variable length packets, in the optical packet switch (OPS) with the shared fiber delay line (FDL) buffer. To optimize TWCs and internal wavelengths related to an OPS design cost, we proposed a scheduling algorithm for the limited TWCs and internal wavelengths. For three TWC alternatives (not shared, partially shared, and fully shared cases), the optimum numbers of TWCs and internal wavelengths to guarantee minimum packet loss are evaluated to prevent resource waste. Under a given load, TWCs and internal wavelengths could be significantly reduced, guaranteeing the same packet loss as the performance of an OPS with full TWCs and internal wavelengths.