Check first whether all events are always sent through the server container. It is better to do this by also checking the browser network (just specify your measurement id ga4 in the filter). Make sure that every event goes through the server container.
In 90% of cases this problem is due to the fact that some events, in particular conversion events are sent directly to google-analytics.com instead of your server container url.
Since GA4 web events and server events use different cookies - such events are considered as events from different users and this breaks many reports in GA4.
However, I did not duplicate the tags, I don’t understand why this happens.
To set the server-side tracking, I use the setting parameter “server_container_url” in my Google tag to send my data from GTM web container to my GTM server container.
What can I do to stop the data to be sent to Google Analytics ?
If you have one google tag in the container this usually means something is overwriting it from other source.
It could be for example a third party integration or plugin that also sends events to GA4.
Or gtag() js snippets in the site code.
It is also worth checking if your GA4 is connected with Universal Analytics property (it is easiest to see it in UA settings) - it is better to disable it.
Also check the GA4 datastream ‘collect UA events’ in the GA4 settings (in this case if you have ga() scripts somewhere or any old UA events interactions active - this may cause this behaviour.
I succeed to fix our problem, I send the solution to help if anyone is in the same situation that I was.
I did not select the setting about migrating the javascript client ID in the client tag in my server container. I am surprised that it is not checked by default.
After checking this setting as my screenshot shows, the attribution works normally.