With the vigorous development of the world economy and the prosperity of the shipping industry, there are more and more oily sewage from ships. At present, the methods of treating oily sewage from ships can be divided into physical, chemical and biological methods, among which biological method is favored by people for treating oily sewage thoroughly and without secondary pollution. However, the slow speed of biological method for treating oily sewage has always been an important reason affecting its development. The optimum pH, salinity and temperature are 7, 2 g/L and 35℃, respectively, according to the single‐factor experiment. The Box‐Behnken design method was used to optimize the response surface of the modified conditions, set up the three‐level experiment of pH, salinity and environmental temperature, and build a regression model. After analysis, it is proved that the regression model predicts that the removal rate of seven‐day diesel oil is 63.2%, and the actual removal rate of diesel oil measured by the experiment is 63.1%, and the error between the predicted value and the model is not more than 2%, indicating that the model is reliable and can be used to optimize the removal rate of seven‐day diesel oil.