@GonfuzzaBeat the rancor on Jedi Master difficulty during my first Koboh visit. I died like a zillion times but I worked it out. I had to keep running like an idiot from the meditation point just outside the mines because the rancor meditation point is glitched.
Best strategy: dual wield + parry.
You can't out damage the rancor or out evade him. The best strategy is to parry the cr@p out of the rancor. It is hard because the rancor hits like a truck and you'll get instakilled... but parrying is The Way. If you learn to parry the rancor, you literally can bully the sh!t out of the rancor.
It took me like a 100 deaths to finally calm down and work it out. The trick with the rancor is not to panic and just start treating him like a joke so you can focus. I died so many times that sometimes the rancor would glitch and not be there in the cave. I'd have to use task master to kill the game and restart/reload to get the b@stard back into the ring so I can get back to learning to parry his @ss and using my lightsaber to make him 'one with the force'.
With most enemies you immediately hit block to parry as soon as you see the enemy flinch or raise their hand. The rancor is different. You've got to hold your nerve and not hit block when you see the rancor raise its hand to hit down vertically or wind back its hand to swipe horizontally. The rancor has a big wind up and the temptation is to freak and hit block immediately because you're scared, you see that big claw coming, and the rancor can kill in one hit. This is a mistake: You hit block at the very last second JUST AS THE RANCOR'S CLAWS ARE ABOUT TO TOUCH YOUR HEAD. If you take damage or die, you'll know you blocked too soon. If you do it right you'll hear a weird short circuit sound. Then release block and get ready to parry the second attack.
You could hold on Y to focus parry but it uses The Force + there is a slow wind up so you can't react instantly and you'll probably end up dead as you try to parry the wrong attack (e.g. the ground stomp or red charge). It's easy to parry the rancor reliably once you wait until his claw is about to touch you and your reaction times will always be super quick with no wind up. And if you need to evade, you can because you're not charging up the Y focus parry which leaves you vulnerable to stomping shock waves or being grabbed+eaten.
I avoid throwing my lightsabers at the rancor because I can't move whilst the lightsabers are in flight and this is a fatal mistake as you need to be able to dodge/evade the red ground stops and red charges. Even at a distance, these attacks can and will kill you. The rancor's attack range is deceptive. As soon as you see him swinging its arms, it means you're in range... even if psychologically the distance feels too long and you think you're safe (Hint: you're not). The rancor's attacks never miss unless you evade, hence why throwing lightsabers is a really bad idea.
Try to stay in the centre of the ring to bait the rancor into your next parry and give yourself room to manoeuver for jumping shockwaves or evading red charges. Avoid the walls for this reason.
Medium distance works best: you can see what's coming in terms of parry or evade and still close enough to hit once your double parry is complete.
Parry the overhead strikes. They are always in pairs.
Parry the horizontal swipes. They are always in pairs.
If you're too close press evade to back away and bait the next parry. Be ready to press jump in case the rancor does some ground stops (again always in pairs) and the shockwave hits you. Always keep your finger near evade and jump. Only move finger near the hit button once you parry him twice and there is an opportunity to deal damage. Otherwise the rancor will red charge you and you'll be too slow and get eaten if you keep your finger hovering over the hit button at all times.
Don't be greedy with your hits: give him a few swipes and then back off. You need to wear this guy down slowly and parry the F*** out of him.
Keep your finger near evade/jump at all times to avoid his red charging attack and red ground thump.
Shoving my lightsaber up that beast's @nus at the end was thoroughly satisfying.
After going through that, I fear nothing.
PS. You get an awesome shatter perk after you beat the rancor but I was disappointed that you only get 1 measly skill point for defeating such a God damn hard creature. I remember when I killed the Oggdo Bogdo in Fallen Order... I got like 3 skill points. The rancor was waaaaaaaaaaay harder than that fight! Anyway....