Filter Membrane Blockage Prevention

In a treatment package plant attached with a reverse osmosis machine, how can one resolve the issue of membrane filter blockage prematurely and how long does it take before a filter needs replacement?