My 300tdi has just reached 200k - runs happily at 50mph and had annual services, oils filters etc.
What should I do to make sure the engine reaches 400k ?
How long did it take for the first 200K ?
Regular filter/oil changes will help keep the engine running, assuming you can still buy diesel.
I'd suggest that to keep it on the road over the next 25 years it may need a bit more than regular oil changes and an annual filter service though.
I'd also look at a new snake belt, timing belt (and tensioner), fling washer, water pump, thermostat, radiator and intercooler.
A full set of rubber hoses would probably not go amiss either.
A quick look at the compression will give you a clear indication of the state of the rings/head and valve seats.
Check the Turbo and see if you need a new CHRA too.
If you are in super pamper mode, send the FiP and your injectors off the Diesel Bob for a check-up and overhaul.
About £1500 to £2000, maybe a bit less if your Turbo is OK and you do most of the work youself.
After that you should be good to go with your normal routine.
Let us know how you get on (with pics ...)