A soil compactor includes at least one compactor roller, which is free to rotate about an axis of rotation of the roller, with a plurality of roller segments, which follow one another along the direction of the axis of rotation of the roller. In each case, at least one electromotive drive for producing an oscillating torque is assigned to each roller segment.