no easy-rsa to install on my debian

Posted February 7, 2015 46.4k views

I want to install openvpn on my debian according to the web material :

root@change:~# apt-get install openvpn easy-rsa
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package easy-rsa

  • Try this:
    cp -r /usr/share/doc/openvpn/examples/easy-rsa/2.0/ /etc/openvpn/easy-rsa/

  • work! with
    cp -r /usr/share/doc/openvpn/examples/easy-rsa/2.0/ /etc/openvpn/easy-rsa/

  • What about in my case, where I’ve installed:

    apt-get install openvpn easy-rsa

    But the directory /usr/share/doc/openvpn/examples/easy-rsa/ does not exist?

    I would like to have the Easy RSA OpenVPN Sample config files and they are usually under this directory.

    :~# uname
    :~# lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 14.04.4 LTS
    Release:        14.04
    Codename:       trusty
    :~# cat /proc/version
    Linux version 3.13.0-79-generic (buildd@lcy01-24) (gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) ) #123-Ubuntu SMP Fri Feb 19 14:27:58 UTC 2016
    :~# cat /etc/*-release
    DISTRIB_DESCRIPTION="Ubuntu 14.04.4 LTS"
    VERSION="14.04.4 LTS, Trusty Tahr"
    PRETTY_NAME="Ubuntu 14.04.4 LTS"


  • I answered my own question, so I thought I would put it here for anyone else who needs it:

    I was actually not looking for the config files, but rather the Easy-RSA tools. Normally when you are setting up a VPN you would copy this folder into the /etc/openvpn/ folder and do all your work in there.

    I did find them though, the files have simply been relocated to:


    And I copy them to where I need them with:

    cp -r /usr/share/easy-rsa /etc/openvpn/easy-rsa

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
5 answers

To get a proper response to questions like these you really need to specify what Debian version you are running. For the purpose of this answer I’m going to assuming that you are running Debian Wheezy, which is the current Stable version.

Debian Wheezy comes with OpenVPN 2.2, where easy-rsa is distributed together with main OpenVPN program. On your Debian system you ought to find easy-rsa under the path /usr/share/doc/openvpn/examples/easy-rsa/.

As of OpenVPN 2.3 easy-rsa is treated as its own program, which is why Ubuntu 14.04 has it as a separate package.

Bonus answer: In case you want OpenVPN 2.3 for your Debian Wheezy you can get it from Debian Backports. One good reason to prefer OpenVPN 2.3 is that it comes with much better IPv6 support.

download the easy-rsa pacakge manually using wget


run it !

sudo dpkg -i easy-rsa_2.2.2-1_all.deb

In Debian 8, install easy-rsa by apt-get install easy-rsa.
After this, the easy-rsa directory found in: /usr/share/easy-rsa

or find using: find / -name build-ca

Think for your answer.
My debian is wheezy,it is true that easy-rsa is under the path /usr/share/doc/openvpn/examples/easy-rsa/.

Here is my installation process.
The web material is :

gunzip -c /usr/share/doc/openvpn/examples/sample-config-files/server.conf.gz > /etc/openvpn/server.conf
nano /etc/openvpn/server.conf #the same as web material
echo 1 > /proc/sys/net/ipv4/ip_forward
nano /etc/sysctl.conf #the same as web material
apt-get install ufw
ufw allow ssh
ufw allow 1194/udp
nano /etc/default/ufw #the same as web material
nano /etc/ufw/before.rules #the same as web material
ufw enable
cp -r /usr/share/doc/openvpn/examples/easy-rsa/ /etc/openvpn
mkdir /etc/openvpn/easy-rsa/keys
nano /etc/openvpn/easy-rsa/vars

root@change:/etc/openvpn/easy-rsa# . ./vars
root@change:/etc/openvpn/easy-rsa# ./clean-all
-bash: ./clean-all: No such file or directory
root@change:/etc/openvpn/easy-rsa# ./build-ca
-bash: ./build-ca: No such file or directory

What is the matter with my installation process?
“In case you want OpenVPN 2.3 for your Debian Wheezy you can get it from Debian Backports. ” to change the statement into some shell commands? to setup the openvpn?

by James
OpenVPN is a full-featured open source Secure Socket Layer (SSL) VPN solution that accommodates a wide range of configurations. In this tutorial, we'll set up an OpenVPN server on a Droplet and then configure access to it from Windows, OS X, iOS and Android. This tutorial will keep the installation and configuration steps as simple as possible for these setups.