Openvpn Route-up.sh called from?

Post new topic   Reply to topic    DD-WRT Forum Index -> Generic Questions
Author Message
vtphilk
DD-WRT User


Joined: 09 Nov 2006
Posts: 118
Location: RTP, USA

PostPosted: Sun Mar 23, 2008 22:55    Post subject: Openvpn Route-up.sh called from? Reply with quote
Anyone know how/where the route-up.sh gets created and run from?

The stupid thing keeps launching the default /tmp/openvpn/route-up.sh /route-down.sh scripts which has masq nat in them! I tried writting a rc_startup script to change the route-up.sh and down but no luck.


~# nvram get rc_startup
(sleep 10; cp /etc/openvpn/route-down.sh /tmp/openvpn/route-down.sh;
cp /etc/openvpn/route-up.sh /tmp/openvpn/route-up.sh ) &



/etc/openvpn is the route-up.sh i built in using the firmware mod kit.

I want to be able to use the startup methods of the standard openvpn client but just need it to us my route-up/down which is located in /etc/openvpn.

Is there any way to do this or do I have to create my own process startup/monitoring to get the openvpn to start with the --route-up /etc/openvpn/route-up.sh rather --route-up /tmp/openvpn/route-up.sh like it does.

It seems everytime the openvpn service is stop/started it re-writes the /tmp/openvpn/route-up.sh and route-down.sh files from some magical location :)

Thanks
Sponsor
vtphilk
DD-WRT User


Joined: 09 Nov 2006
Posts: 118
Location: RTP, USA

PostPosted: Fri Apr 04, 2008 21:26    Post subject: Reply with quote
bump... anyone have any idea where this is set?
Brainscanner
DD-WRT Novice


Joined: 01 Jun 2008
Posts: 14

PostPosted: Fri Aug 15, 2008 7:40    Post subject: Reply with quote
If you still have that problem take a look here: http://www.dd-wrt.com/phpBB2/viewtopic.php?t=6465
portsup
DD-WRT User


Joined: 20 Oct 2018
Posts: 210

PostPosted: Tue Dec 18, 2018 11:59    Post subject: Reply with quote
You can use the "up" command to load a script to overwrite the files in /tmp/openvpncl.

for example

place this without "" in the additional config of the services/vpn tab

"up /jffs/scriptname.sh"


in the script you have

"
#!/bin/sh
cp -a /jffs/openvpncl/* /tmp/openvpncl/
"

which writes over /tmp/openvpncl/ with anything in /jffs/openvpncl/

From memory you need to use jffs as other mounts don't load early enough.
Eleanor Richards
DD-WRT Novice


Joined: 08 Jan 2019
Posts: 1

PostPosted: Thu Jan 10, 2019 12:13    Post subject: Reply with quote
portsup wrote:
You can use the "up" command to load a script to overwrite the files in /tmp/openvpncl.

for example

place this without "" in the additional config of the services/vpn tab

"up /jffs/scriptname.sh"


in the script you have

"
#!/bin/sh
cp -a /jffs/openvpncl/* /tmp/openvpncl/
"

which writes over /tmp/openvpncl/ with anything in /jffs/openvpncl/

From memory you need to use jffs as other mounts don't load early enough casino bonus.


Great decision, thanks
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Generic Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum