The old oil did look pretty rancid (but then I know nothing about tractors).
Is the old engine ECU available to try? Might be worth a quick swap just in case? Is the Tech 2 showing sensible values for the temperature sensors, etc?
Worth trying a bit of lifter treatment and maybe some fuel additive perhaps. Although it hasn't been standing for long it's a fair while in comparison to regular use.
Excuse my complete lack of experience with diesels but if the ECU was over / under fuelling wouldn't it just affect the engine speed (at idle, at least. On boost it would be a different matter, obviously)? Surely if unburnt fuel is escaping as smoke it's the quality of the injector spray pattern or lack of compression, perhaps due to sticking lifters, etc?
Anyway, glad to hear it at least does run. Hopefully it will come good with a little more tinkering.
Kevin