I'd say DS9 was definitely influenced a lot by B5. But B5 was influenced a lot in its presentation by Star Trek so it's really only fair.
Yeah. My opinion on this old debate is and always shall be that DS9's writers clearly borrowed ideas from B5, but in the end both shows were good in their own right. B5 was influenced by Star Trek, as well as by Lord of the Rings.