The problem we have is that we have elevated man to a God like status. What God does is beyond our grasp.
Everything that has been done by God and is recorded in the Bible is just. Whether we fully understand it or not is irrelevant.
I'm interested as to why you focus on one book and not others. Are all holy books just or just the one you have chosen? And did God choose which books when into the Christian bible or men, given the Dead Sea scrolls continue to give up a fascinating alternate versions of the New Testament and additional lost books from it - are these lost books divine and just too, and if not why not?
I do understand that it is easier to not to try and understand. After all, if you add up all the people that were killed according to the Bible as a result of God's actions it comes to around 25,000,000 as an estimate. That includes God-sent floods, plagues, ethnic cleansings, God ordered stonings of entire families etc. (he'd surely be a shoe-in for ISIS membership!).
The Bible tells us that Satan only killed 10 people in the same period, but that these were as a result of a bet with God so were actually God's fault anyway as God gave Satan permission. I've never worked out why poor old Satan gets such a bad rap if you believe that the Bible is true because surely it is God who is 'evil'? In fact the Cathars appear to have sussed that one out quite well, but for their trouble entire communities were put to death by the Church for pointing out the blinkin' obvious, but it is that old 'justice' thing again isn't it?
The way around this of course is to take Ludwig Feuerbach as a starting point for looking at God as a psychological projection of man. In other words it is us who create the gods (and we have created many thousands of them over the years of human existence), the gods don't create us. Besides, anyone who comes up with the line “I would rather be a devil in alliance with truth, than an angel in alliance with falsehood” has got to be worth taking seriously