How to follow and contribute to a research discussion when less experienced?
Don't worry about it. You're a second-year PhD student, so you're one of the least experienced people in the room. Everyone should find this reasonable. What matters is that you show a willingness to learn, to grow, to understand, to improve.
Don't be afraid of asking questions. Don't even be afraid of asking stupid questions. Most scientists will gladly elaborate if you show a genuine interest in understanding the topic better.
Study the topics in your field. Deepen your understanding in your own PhD topic, and adjacent topics on which other people at your conferences are working. If you keep working on improving your understanding, you will notice that over time, you will be able to keep up with the pace. The key is to not panic that you're not there yet, but instead display that you are willing to learn.
Your experience is normal: A second year PhD student should not keep pace with postdocs nor advisors. They should learn. It seems like you're doing that.
In a meeting setting, try to understand when it is appropriate to slow the pace to improve your understanding. Don't interrupt when you can learn later; interrupt when you can't, either to learn during the meeting or to arrange a tutorial afterwards (likely with the most junior person, beside yourself). (Meetings are presumably to get work done, so too many interrupts will preclude that.)
In a seminar setting, ask the speaker after their talk, over lunch, or arrange a one-to-one later in the day. (External speakers are usually visiting someone and will have some free time during the day.)
At conferences, you have plenty of opportunities to ask speakers for more details.
I mostly end up listening and this makes it difficult for me to find collaborations because the conversation is too one-sided.
Having conversations will allow you to build bridges. (As a PhD student, I'd suggest focusing on relationships within your department, rather than the broader field. Bridges are useful for research visits, internships, subsequent positions, etc.)
If there is no whiteboard and the discussion is over a meal, or when there are multiple people involved, it is that much harder!
Such discussions will become easier once your knowledge broadens. Sit-back and enjoy your meal. Ask questions one-to-one, e.g., after dinner, whilst walking a guest back to their hotel, or the following day.