Two things to keep in mind: At very high levels, you have very high saves, and you have access to obscene amounts of powerful gear.
I played in a 3.5 epic campaign (we were well into the high-30s by the time it ended), and truth be told, the spell casters were the ones at a disadvantage, because everything had high resistances that had to be overcome, and if that was accomplished the would-be victim then got to roll his ridiculously high saving throw.
We actually had to house-rule in items and abilities and meta-magic feats to boost the power of spell casters! Yes, their spells can be immensely powerful at that level (although remember that epic-level spells are obscenely expensive (at least in 3.5, I don't know about Pathfinder) to research, and even then few mages will have many epic-level slots; also, almost all non-epic spells have caps on their damage-dealing ability), but they fail or get countered with such regularity that a non-magic user is actually at a considerable advantage over them.
I had no trouble at all fielding rogues, barbarians, various assorted prestige classes, and even once a pure fighter (those that died fell to other fighter-types (with one exception, and that was at the hands of a fellow PC), while others I simply grew tired of and discarded -- it's my curse to always get bored with whatever my current PC is). I never fielded a magic user because, even with our house rules boosting them, I felt they were horribly gimped at those levels, not to mention obscenely complex to build properly.
I would caution against too many classes/prestige classes. The most effective builds used no more than 2 prestige classes (with one exception, which used 3 of the most horribly broken prestige classes) built upon a single base class, although there was a rather effective barbarian/fighter PC. If you mix things up too much, you'll find that, while you have a large array of abilities, too many of them are based upon your class level (i.e. most class abilities are based on your levels in that class), not your character level (i.e. the combined levels of all your classes), and thus are so underpowered as to be effectively useless. Exceptions abound, of course (the rogue's sneak attack is useful no matter how few levels you have, for example), but as a general rule of thumb you want as many levels in as few classes as possible in order to be effective.
If you find yourself at a huge disadvantage compared to magic users, I would look here first, rather than looking at the magic users as being too over-powered.
Some items you should definitely have:
- Anything that grants spell resistance
- Anything that grants Mindblank; there's an epic-level version of the Cloak of Elvenkind that gives you something like +30 to Move Silently as well as Mindblank, and it was so useful that literally every single character in the party bought one and considered it absolutely indespensible, even those for whom sneaking around was never something they did.
- Anything that boosts your saves
- You should of course have all the +5 Tomes to boost all your stats.
- Any item that grants Death Ward, or similar proof against death effects (so common in our game that mages simply gave up using spells with death effects altogether)
I wouldn't bother with any ranks of Use Magic Device, as the previous answerer has suggested. Your ability to use magic items will be so weak compared to everyone else that you might as well use those skill points to boost something you're already good at. There simply are no Jacks-of-all-trades at epic levels; everyone specializes in the few things they are really damned good at, and ignores the rest. Jacks-of-all-trades are really really useful at low levels, but worthless at epic levels.