When the bacterial cell moves from one environment to another or transports in nutrients from its surroundings, water can freely move across both the cell membrane and the cell wall. Because of this, the cell is at risk for an osmotic imbalance, which could put pressure on the relatively weak plasma membrane. In this case, the cell wall also serves as protection from osmotic lysis.