Arduino, solenoid driver and current limiter

Trying to current-limit a PWM power circuit is doomed to failure.

Use a high-side driver with current feedback. I really like the BTS5012 for 12-15V systems and the BTT6010 for 24-28V. Those chips are much more than you need and hence almost bullet-proof. There are others in the family that may be more appropriate for just 2A.

With an appropriate RC filter on the feedback pin, your Arduino can control the current in the solenoid very accurately.