Vast amounts of gas are sometimes a sign of SIBO (small intestinal bacterial overgrowth). When I had SIBO a few months of doxycycline took care of it. I’m told that rifaximin is commonly used now for SIBO, and that should have a very low risk of side effects. Good luck!