The most common solution is a strain-relief bushing, and the prominent brand is Heyco.
When you use the proper size, they grip the cable so well that the cable will break before they let go.
But they need exactly the right size hole and they are tricky to install/remove with ordinary pliers.

https://www.heyco.com/Strain_Relief_Bushings/product.cfm?product=Original-Strain-Relief-Round-1
They were/are called 'Nylon Cable Gland' or 'Nylon Cable Entry Gland' the last time I bought some in a few sizes,
they are very handy quick fixes, and a painless upgrade for stiff or deteriorating rubber grommet 'disater waiting to happen' devices
and yes they are tricky to remove if fitted securely, unless you have the purpose made tool,
or a customized/butchered

pair of cheapie pliers or grippers
FWIW if they are not a perfect fit, or loose/wonky and a suss grip, you can wrap electrical tape around the cable first to beef it up, then press down on the gland and slot it in to the chassis
I have successully used this method for round holes too and it works well enough (an internal silicone gob 'may' be required for zero rotation movement) as these Nylon Cable Entry Glands are designed to stay put in oblong shaped holes
If aesthetics are involved, conceal the black electrical tape under length of the gland,
or just get it sorted and then carefully trim off the excess tape for a pro look
Other cable diameter beef up methods are heatshrink or thin wall rubber tubing, but electrical tape works fine (UL listed preferably) if the cable isn't being removed or replaced.
My personal preference is good quality black or grey duct tape, it's wide, performs well under the pressure, it's one solid adhesive piece that I stretch a bit for extra grip, to ensure it won't budge or go gooey over time and temperature extremes
Hard to put it in words, hope it made sense
