An earthquake of moderate intensity today shook Kishtwar and Doda districts in Jammu and Kashmir, triggering panic among people.