You can hold up 2' of dirt with wood structures. That's essentially what wood planter boxes are. But will it look good? Probably not...at least, not over time. Wood is flexible, gets wet, gets sun damaged, and the posts supporting it will suffer the same fate. If you don't care about looks, then it's probably OK, but if you want it to look OK over time, I'd suggest you consider retaining wall blocks or the like.
Coming back to this as I think I answered before I saw the photo. I think you could probably make this work. However, I don't see a whole lot of space between the fence and the side of the house. Do you have a basement? If so, this slope is probably intentional to provide adequate surface run-off to keep your basement dry. Do you live in an area where you can get heavy rains at time? If so, I'd suggest not leveling this part of the yard.