OpenVPN trouble installing (beginning)
-
I'm running ubuntu 8.04 and openVPN 2.1_rc7.
I'm stuck on running the vars script in the openVPN setup, http://openvpn.net/index.php/documentation/howto.html#pki.
I've run the vars script a number of ways, but it never creates the keys directory.
I've tried,
sudo sh vars
sudo sh ./vars
source vars
source ./vars
sudo /bin/bash ./varsIt seems that the vars script attempts to export environment variables, but when I call env or sudo env I don't see them.
If I try to execute the next install script, sudo sh clean-all, it tells me "Please source the vars script first (i.e. "source ./vars")".
I know it's something simple, but I can't figure it out right now.
-
This is not a pfSense question.
Please post on the openVPN maillist.Did you modify the vars file so it acutally contains what you want in it?
-
I figured out "source vars" does run the vars script properly, as it sets a bunch of environment variables.
The script has to be run as sudo because the environment variables need to be set for the root account.
The problem is you can't execute "sudo source vars". How do I execute "source vars" as sudo, or root user?
-
Yes I modified to vars with custom key information.
-
The problem is you can't execute "sudo source vars". How do I execute "source vars" as sudo, or root user?
I'd stay stop pissing around using "sudo this" and "sudo that" and just drop straight into a root shell. You're administering a firewall, not a desktop PC.
"su - " (supply root password) or "sudo -s" (supply your password) will do the trick, then run all the commands you need without any more crappy "sudo" prefixes.
-
There is no need to run any of the scripts as root or with sudo, you can run them as normal user and they should work just fine.
Edit: Make a copy of the easy-rsa directory to your own home directory and use the copy for making keys.
-
Thanks got it working now.