The reason we say, for example, "5 metres in length" is to show that the measurement of 5 metersmetres is the length and not any other dimension such as breadthwidth. We don't always prefix "length" with "in".
You are right in saying that "lumber" and "timber" are non-countable nouns, but "a length" can be used as a noun for a specific cut of timber, the plural of which is "lengths".
So you could say:
We can cut timber into a minimum of 5 meters-metre minimum lengths.*
*you have to be careful this does not sound like you mean 5 lengths of one metre each, because a 1-metre length can be called "a metre length".
or
We can cut timber into lengths no shorter than 5 metersmetres.
(these are using "length" as a noun for the piece of cut timber)
or
The minimum length we can cut timber into is 5 metersmetres.
(this is using "length" as a noun for the measurement)