An ideal of osmotic equilibrium between an ideal solution and pure solvent separated by a semi-permeable membrane is studied numerically using the method of molecular dynamics. The osmotic flow is observed as the inflow of the solvent across the membrane from the dilute to the concentrated side. The validity of van't Hoff's law for osmotic pressure is confirmed over a wide range of concentrations. It is found that the law is established by a balance between non-uniform partial pressures of solute and solvent. Furthermore, the present model permits an understanding of the mechanism of the osmotic flow in the relaxation process as the liquids evolve from the initial state to the equilibrium state. We focus in particular on the interaction between solute and solvent.