If there are no abnormal noises, no grinding, whining, whiring, tapping it may be worth flushing the engine (diesel or kerosene) fitting a new filter and replacing the oil. Try it for a couple hours and then drop the oil and replace the filter again.
The state of your filter is quite alarming but it could well be sloppy workmanship by a previous owner. They may have fixed the problem and not replaced the filter, and it’s not unheard of for people to reuse the oil the drained out!
The state of your filter is quite alarming but it could well be sloppy workmanship by a previous owner. They may have fixed the problem and not replaced the filter, and it’s not unheard of for people to reuse the oil the drained out!