Recently, a large amount of studies have been related to nonlinear systems with multi-degrees of freedom as well as continuous systems. The purpose of this paper is to optimize passive vibration absorbers in linear and nonlinear states for an Euler-Bernoulli beam with a nonlinear vibratory behavior under concentrated moving load. The goal parameter in the optimization is maximum deflection of the beam. The large deformation for beam modeling is considered, i.e. the relation between strains and deflections is nonlinear. The force magnitude and beam length are two effective factors for the beam deflection. Vibration absorber with linear damping and linear or nonlinear stiffness is also considered in this manuscript. The results show that, for normal forces and short beams, linear and nonlinear models have similar behaviors, while surveying nonlinear behavior is necessary by increasing the force and length of the beam, i.e. large deflections. Moreover, the difference between linear and nonlinear beam models for regular force magnitudes and beam lengths is negligible. For higher loads and longer beams, beam model nonlinearity can be important. Results demonstrate that,in the presented numerical values (train bridge application) for cubic nonlinear vibration absorber, there are two optimal locations for vibration absorber installation: one inclined from the middle of the beam to the direction of moving loads and the second which is more interestingly inclined from the middle of the beam to moving loads in the opposite direction. Moreover, depending on the model's numerical parameters, for short beams, linear vibration absorber is more effective, while for long beams, cubic nonlinear beam behaves better than the linear one.