--SOLUTION--
I tried running the
/usr/local/openvpn_as/scripts/sa command and this is the result I got:
Code: Select all
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "build/bdist.linux-x86_64/egg/pyovpn/sagent/sagent_entry.py", line 57, in sa
File "build/bdist.linux-x86_64/egg/pyovpn/sa/sacmd.py", line 2, in <module>
File "build/bdist.linux-x86_64/egg/pyovpn/sa/sa.py", line 3, in <module>
File "build/bdist.linux-x86_64/egg/pyovpn/db/db.py", line 3, in <module>
File "/usr/local/openvpn_as/lib/python2.7/curses/__init__.py", line 15, in <module>
from _curses import *
ImportError: libncurses.so.5: cannot open shared object file: No such file or directory
This prompted me to reinstall libncurses5 library using
sudo apt-get install libncurses5
However, when attempting to install openvpn-as again, I still got the following error:
Code: Select all
(Reading database ... 158029 files and directories currently installed.)
Removing openvpn-as (2.7.4-777bcfe6-Ubuntu18) ...
Removing scripts...
Removed /etc/systemd/system/multi-user.target.wants/openvpnas.service.
Removing files ...
Removing custom users and groups...
userdel: openvpn_as mail spool (/var/mail/openvpn_as) not found
root@jinora:~# dpkg -i openvpn-as-latest-ubuntu18.amd_64.deb
Selecting previously unselected package openvpn-as.
(Reading database ... 154951 files and directories currently installed.)
Preparing to unpack openvpn-as-latest-ubuntu18.amd_64.deb ...
Unpacking openvpn-as (2.7.4-777bcfe6-Ubuntu18) ...
Setting up openvpn-as (2.7.4-777bcfe6-Ubuntu18) ...
Regenerating etc openvpnas script...
writing systemd service to /etc/systemd/system/openvpnas.service
Created symlink /etc/systemd/system/multi-user.target.wants/openvpnas.service → /etc/systemd/system/openvpnas.service.
Regenerating startup/shutdown scripts...
Backing up configuration and DB files to /usr/local/openvpn_as/etc/backup prior to update.
ERROR: 'NoneType' object has no attribute 'db': util/options:79,db/confdb_admin:322,db/confdb:758,db/confdb:746,db/confdb:740 (exceptions.AttributeError)
ERROR: 'NoneType' object has no attribute 'db': util/options:79,db/confdb_admin:322,db/confdb:758,db/confdb:746,db/confdb:740 (exceptions.AttributeError)
ERROR: 'NoneType' object has no attribute 'db': util/options:79,db/confdb_admin:322,db/confdb:758,db/confdb:746,db/confdb:740 (exceptions.AttributeError)
Beginning with OpenVPN AS 2.6.0 compression is disabled by default and on upgrades as security patch.
ERROR: 'NoneType' object has no attribute 'db': util/options:79,db/confdb_admin:322,db/confdb:758,db/confdb:746,db/confdb:740 (exceptions.AttributeError)
When running
/usr/local/openvpn_as/scripts/sa again, this time I get the following result indicating to me that it at least has the correct libraries:
Code: Select all
sa: Wrong number of arguments.
SA tool 1.1
NOTE: This tool is intended for diagnostic usage only.
NOTE: Please use sacli for production usage.
Usage: sa [options] cmd [args...]
Commands:
Init -> initialize DB, write server output files to dest_dir
AddClient client_name -> add client to DB, write client output files to dest_dir
GetFiles client_name|'server' -> write files associated with client or server to dest_dir
DeleteClient client_name -> delete client from DB
ListClients -> list all clients in DB
Dump -> dump DB
Options:
--autologin Don't require a username/password from this client
-c, --comment= Comment for AddClient (optional)
--ca_cn= CA certificate Common Name for Init [default: OpenVPN CA]
-d, --db= Certificate DB [default:
sqlite:////usr/local/openvpn_as/etc/db/certs.db]
-e, --exp= Days till cert expiration [default: 3650]
--help Display this help and exit.
-l, --lic_dir= License store directory [default:
/usr/local/openvpn_as/etc/licenses]
--no_ovpn Disable OpenVPN-specific functionality
-o, --dest_dir= Output directory for Init, AddClient, and GetFiles
-p, --cert_pass= Private key passphrase for AddClient (optional)
-s, --keysize= Key Size (1024 or 2048) for Init [default: 1024]
--server_cn= Server certificate Common Name for Init [default: OpenVPN
Server]
-u, --user= Username for AddClient
--unique_ca Append machine name and date/time to CA common name
--version
Edit: I initially thought this meant that the install had still failed, however when running
ovpn-init the setup worked and I now have access to the web server so I guess the missing libraries was the issue.