I think, you misunderstand the concept of the priority. If the group has the priority over another group, it does not mean, that this group's locant has to be smaller. It just means, that the group with the highest priority needs the lowest locant possible. Therefore you should do this:
- What is the group with the highest priority? -OH. (Therefore the name of the compound is something-ol)
- How many of them are there in the molecule? Only 1.
- What is the principal hydrocarbon – the longest one with the maximum (in this case only one) groups with the highest priority? The whole hydrocarbon! (Since the -OH group does not divide this hydrocarbon in two.)
- How long is the principal hydrocarbon? 8 carbons. (Therefore the name of this compound is octan-?-ol with some modifications we add later.)
- And now the part with the priority: Should I number the principal hydrocarbon from the left or from the right? From the right, because the -OH group is "closer" to the right. Therefore it is octan-4-ol. If numbered from the left, it would be octan-5-ol.
- And that is it. Now just add the other groups. In this case, it is just a double bond. Therefore oct-2-en-4-ol.
One last thing is stereochemistry, if you need to do that. In many cases you do not need to. As far as I know, the cis-/trans- nomenclature is obsolete now, if you speak about double bonds. Nowdays you use (E) for trans and (Z) for cis. If you understand German: E means entgegen (on the oposite side) and Z is zusammen (together). Nowdays cis/trans is used only if you speak about cycle molecules.