Most of the authors I know work very hard to keep their stories original. There are some notable exceptions (like Laura Harner, who plagiarized entire books from best-selling authors) but for the most part we earn our legal disclaimers: we make it up ourselves.
But on the other hand, we're all influenced by what we've seen, heard and read, which means that some similarities are inevitable. So when is a story too close to another story? If I had a solid answer to that one, I could make millions as a trade infringement lawyer but the answer always boils down to: it depends.
For example, last month, Sherrilyn Kenyon launched a lawsuit against Cassandra Clare, the author of the Shadowhunter series. Kenyon and her lawyers are claiming that the main characters are too close to Kenyon's own Dark-Hunter series. Per the lawsuit, Kenyon's fans alerted her to the similarities in 2006 and Clare agreed to remove the term "shadowhunter" from her book (Mortal Instruments: City of Bones). Since then, the term has apparently crept back into the sequels and the movie.
Clare's lawyers and Kenyon's lawyers will have to battle it out. I haven't read Clare's series but I have read the Dark-Hunter books and there are surface similarities based on the description. An elite, but isolated and brooding band of men and women with supernatural powers have to fight against an unknown supernatural world, which is completely unknown to the ordinary people in the books.
The problem is that the idea of a secret society of superpowered individuals is not exactly original to either of them. One of my favourite TV shows from the early 1990's is Forever Knight, about a vampire who becomes a police officer to protect people against the hidden occult world. This predates both series. People and objects imbued with magic or other powers have been a standby since the epic of Gilgamesh, the earliest written story. Myths of shamans and heroes protecting the innocent from unseen forces, also ancient. So it comes down to the details.
Are the names too similar? Do the plots follow similar lines? Are there phrases or word choices which appear in both series? Those are the questions which must be answered to both parties' satisfaction.
Then there comes smaller details. I recently saw a post from an author who was concerned because she had created a character with a peculiar idiosyncrasy for her latest book, only to discover another recently released book with a character who did the exact same thing. The plots and genres were very different, but this one small detail matched up. In this case, given that both books are recent releases, the overlap is probably a case of parallel inspiration (the excuse usually given for why we can have two volcano disaster movies released in the same year).
This minefield is terrifyingly intimidating for a new author. Without the deep pockets of established or best-selling authors, proving that any overlap was accidental may be an out of reach goal. There are certain things which can be done to protect oneself, such as keeping records and files (both hard copies and digital) of the creative process. Also be wary of any brilliant ideas which come into your mind fully formed. You may be remembering them rather than creating them.
I've been caught by that a couple of times, such as when I was excited about an idea I had for a group of time-travellers who would go through history witnessing key events. My husband reminded me that I was basically talking about Dr. Who, Sliders, Quantum Leap and the Observers from Fringe. Now, if I'd had something original to add to that formula, I could have gone ahead, but upon further reflection, I decided I didn't really have anything new to offer which hadn't been covered in the original series.
In the end, authors simply have to forge ahead. Those of us creating our own worlds shouldn't be too afraid of the rare and few outright thieves. Inspiration is nothing to be ashamed of, but make sure that it acts as a launching pad hurling you out into unknown realms rather than a trampoline, letting you land exactly where you started.