What I understand so far based on this 2 chapters and chapters 109-110. I assume the dates based on historical figures appearing in the story, currently we have around year 1730:
Around year 600 there existed something called the Eternal Spirit, which could cure illnesses, heal wounds and bring good harvest. Understandably, people started worshiping it. Among those people was also a girl that the Eternal Spirit was particularly attached to. Then one day came this Hatano Kawakatsu guy and murdered them all, including the girl and the Eternal Spirit and from bathing in Eternal Spirit's blood Kawakatsu gained some powers. Apparently, the Eternal Spirit didn't die fully and Kawakatsu also knew that, so he established the hidden village of Mushikari to kill the Eternal Spirit when it comes back.
Let's skip forward to around year 1605 to Osaka. There, Mushibugyo is a daughter of the local lord and she really loves bugs. She also resembles the girl that the Eternal Spirit liked all those years ago. Here I assume that the Eternal Spirit either always looked like a bug or took a form of a bug after being "killed" and found his way to Osaka where he was taken in by the bug-loving Mushibugyo. It's also possible he looked differently, but after being taken in by Mushibugyo he took form of the bugs she loved so much. One day Osaka is attacked by the Tokugawa clan and destroyed. The Eternal Spirit who doesn't want to repeat the past grants the power of killing everything that comes near to Mushibugyo, so that nobody will hurt her. She herself is scared of her powers and the Eternal Spirit and runs away with the Tokugawas to Edo.
Currently, the Eternal Bug who doesn't understand Mushibugyo's feelings and is one-sidely in love with her kidnapped her back to Osaka, which he made his base, and due to his bad experiences he wants to destroy all humans. Mushibugyo still cares about humans, so she wants to kill the Eternal Bug, but her powers don't work on him. Mushikari want to fulfill their mission of killing the Eternal Bug, but since they don't know her history(or don't care), they view Mushibugyo as just another part of Eternal Bug's power and therefore a target. Mugai probably learned the truth, so he works with Mushibugyo to kill the Eternal Bug.