I'm a relatively new player, and I've always had trouble getting a foothold in a fortress, and end up restarting - either because I feel I haven't progressed enough to defend against a raid or because a raid has torn through my fortress, and there's no point in continuing.
But the game I'm currently playing is going particularly well.
I started out by digging into a mountain and blocking off the entrance with walls and a hinged Drawbridge (so I can accept merchants), and was able to survive quite comfortably.
Up until my first Goblin raid. Though I made every effort to lock down my fort (by removing all hills to the upper meadows where I identified any sort of defence compromise), the buggers (all of them crossbow users, btw) shot at my peasants from above.
I mobilised my infantry squad (Steel axes, chainmail, breastplate and about 500 combat related xp between them) and pointed them towards the invaders.
I killed just 1 goblin before the group of 6 were chased away, but suffered two fatalities and a very mangled squad.
I got straight to fortifying the upper meadows by first building floors over the holes, then changing my mind after about 5 had been laid (and anticipating how long it was going to take) and then deciding to build makeshift walls around the openings instead.
Luckily, my medic was able to patch both the soldiers' broken limbs into something that may swing an axe again (albeit, one with lifetime gripping issues), and continued with my den.
I built my first well (so my peasants won't have to go outside any more) and several other rooms before I was paid a "visit".
"Osmuth Alásubi Atupkasumci" - a seven headed Hydra arrived. I wasn't going to mess about this time, and locked down the fort's main entrance - the Drawbridge out front.
"But what's this? Urist has been interrupted by a hydra. The stupid sod must have nipped outside before I raised the drawbridge. Where is he...?"
[checks Urist's whereabouts]
"(AARGH! There's a hydra in my base!!)" (He got in through the easily accessable staircase I forgot to account for)
I sent my squad of 8 moderately armed, lightly trained infantry after him, and lost 2 in quick succession. My dwarfs were getting stuck in, and were able to fell the beast with a third fatality from attrition. A fourth soldier of the squad was critically wounded (her right lower leg was yellow, while her whole right arm is absent), and proceded to pass out where the hydra dropped for 2 months or so.
She came to, but wouldn't visit the hospital, but she seemed happy to start hauling rocks around, but I think she deserves better than that. So I made her a farmer.
Now I have to build up my militia again (and look into a crossbow/bow squad), but I'm happy to say I've successfully defended against a small raid and a (lets be honest) fairly unspectacular great beast without my fortress descending into total anarchy.
Some of the dwarves did get a bit upset after seeing a dwarf's child/sibling/random aquaintance littering the halls, but I was a bit busy trying to repel a hydra to worry about bashing out some coffins.
Next time a raid or Great beast turns up, I'll definitely prepare some coffins.