"Can the buyer buy my painting and then sell it without the painter knowing? Who owns the copyright?"Having possession of the physical painting isn't the same as owning copyright over it. Unless it was work for hire or you transferred copyright when you sold the painting, it remains yours.
There's nothing stopping someone from selling a painting they've bought, and they don't have to inform you. Whether the new owners will know about the copyright situation is an uncertainty. Providing a certificate of authenticity with the painting that stipulates this might help. Some countries provide artists resale rights over a certain value, but private sellers are excluded from this.