0

System info:

Distributor ID: Ubuntu | Ubuntu 14.04.5 LTS | Release: 14.04 | Codename: trusty

Problem:

I am having trouble. I am trying to get openVPN and I am following this guide here: Link to guide.

I have successfully done the first two commands, but when I do this code:

gunzip -c /usr/share/doc/openvpn/examples/sample-config-files/server.conf.gz > /etc/openvpn/server.conf

I get an error: `bash: /etc/openvpn/server.conf: Permission Denied.

Can anybody help? Feel free to ask for additional information.

2 Answers2

0

Try running

sudo -i

After that, try

gunzip -c 

again.

guntbert
  • 13,134
0

You can't write into the /etc/ directory without using sudo. The guide omits this little fact in many cases. Notice the first command apt-get update which also won't work without sudo. I think the guide assumes you are logged in as root.

Modify the command as follows:

gunzip -c /usr/share/doc/openvpn/examples/sample-config-files/server.conf.gz | sudo tee /etc/openvpn/server.conf

b_laoshi
  • 4,660
  • 4
  • 25
  • 46
Organic Marble
  • 23,641
  • 15
  • 70
  • 122