A re-entrant manufacturing system producing a large number of items and involving many steps can be approximately modeled by a hyperbolic partial differential equation (PDE) according to mass conservation law with respect to a continuous density of items on a production process. The mathematic model is a typical nonlinear and nonlocal PDE and the cycle time depends nonlinearly on the work in progress. However, the nonlinearity brings mathematic and engineering difficulties in practical application. In this work, we address the optimal control based on the linearized system model and in order to improve the model and control accuracy, a modified system model taking into account the re-entrant degree of the product is utilized to reflect characteristics of small-scale and large-scale multiple re-entrant manufacturing systems. In this work, we solve the optimal output reference tracking problem through combination of variation approach and state feedback internal model control (IMC) method. Numerical example on optimal boundary influx for step-like demand rate is presented. In particular, the demand rates are generated by an known exosystem.