You aren't alone, I have had problems sleeping as well since as far back as I can remember. Some nights it is so bad, so many thoughts will keep flooding through my mind, and nothing I do can make them go away.., it is very scary, and I am sorry you are going through that. The best thing you can do is to get out of bed, and since you are posting on here, you obviously have

Just get up and walk around, or try reading when you feel that way, it sometimes helps