"I have a small sump that needs flushing. Should I use the same lube oil as used in the equipment, diesel fuel or a cleaning solvent?"
There is no mention of the type of deposit that you are trying to remove, so this answer must be a bit general.
The oil product that is the lube oil for the equipment will likely be the poorest cleaning agent but will not present you with any compatibility/cross-contamination issues. A better option is that some oil companies offer a mineral oil-based flushing oil.
Diesel fuel is a hydrocarbon that will completely mix with the mineral oil lube in use. It may be a better cleaning agent than the lube oil and will not have any compatibility issues. The only issue is that any residual diesel fuel left in the sump after the flush will dilute and lower the viscosity of the new charge of lube oil.
The chemical cleaning solution or agent is likely the best cleaning option, but you must be sure to get all of the cleaning solution out of the sump. This may require a fill and drain (flush) with the new lube oil to be used, then a final fill with the new lube oil to be used in the operating equipment. Any remaining cleaning solution may cause issues with emulsification of water or foaming and aeration. Also, make sure that the chemical solution is compatible with any seals and paints in the sump. Temperature and flow rates also affect flushing effectiveness.
Often the need to flush is first observed during an inspection or the appearance of sludge in a sight glass, on a used filter or on the bottom of a sump. This can be confirmed by oil analysis and further inspection. Remediation involves both the removal of the sludge, varnishing or debris (flushing) plus the removal of the root cause before the system is returned to service with normal life expectancy.
The risks associated with a flush vary considerably and depend on the flushing procedure, the machine and the lubricating oil. If the flush procedure involves introducing foreign chemistry (solvents, detergents, etc.) into the oil or machine, this could impair the performance of the lubricant and attack seals and machine surfaces. Lab testing in advance can hedge the risks.
In certain cases, flushing can also lead to leakage when deposits are removed around aged seals and gaskets. In addition, problems can also come from the disturbance and resuspension of settled, low-lying contaminants that are not fully carried out of the system during the flush. Of course, there are risks any time a machine is invaded by a human agency.