If you actually have an inguinal hernia, any type of strenuous exercise including core strengthening may worsen your hernia
Next Steps
Visit a general surgeon, and confirm whether or not there is an inguinal hernia. If there is one, you need to get it treated by surgery and exercises can start 3-6 months after surgery. If there's only muscle weakness and no hernia you can start core strengthening exercises immediately.
Health Tips
Please don't exercise or lift heavy weights till you have confirmed whether or not you have a hernia