Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

After connecting to OVPN, I need to add many routes (more than 3000).

It can be done by sudo reoute add X.X.X.X/X X.X.X.X for each one rules, but it's really slow. Is there any other alternative methods to add them more quickly?

To be more clear, I use a bash script to achieve this, so the problem should be how to write a more efficient bash script.

share|improve this question

migrated from May 7 '13 at 10:03

This question came from our site for professional and enthusiast programmers.

Are you asking how to write a program to add routes? – Gabe May 7 '13 at 4:36
@Gabe Thx for quickly reply, yes, I use a bash script to achieve this. – huxuan May 7 '13 at 4:38

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.