The words, A sound! My beloved is knocking,
are an exact parallel of what the woman heard in Song of Solomon 2:8, when her beloved came to her bounding over the mountain and leaping over the hills. That episode left the man on the outside of the house looking in and the woman had no regret sending him away because the time of consummation had not yet come. Now, however, in Song of Solomon 5:2 the man wants to come into the house, which highlights their marital status.1
What becomes clear in the rest of this poem is that the young woman is describing her experience as her new husband approaches her and seeks sexual intimacy with her as his newly-wed wife. She describes this approach metaphorically as him knocking on the bedroom door.
2 I slept, but my heart was awake. A sound! My beloved is knocking. “Open to me, my sister, my love, my dove, my perfect one, for my head is wet with dew, my locks with the drops of the night.”