cad / ovpm

OpenVPN Management Server - Effortless and free OpenVPN server administration tool
GNU Affero General Public License v3.0
365 stars 76 forks source link

Cant init ovpm : ERROR[001] #82

Closed rtripon closed 5 years ago

rtripon commented 5 years ago

Hello, I'm trying to install ovpm and keep hitting this error after the service is started : May 14 12:00:57 wg ovpmd[6640]: time="2019-05-14T12:00:57+03:00" level=info msg="OVPM 0.2.7 is running gRPC:9090, REST:8080 ..." May 14 12:00:57 wg ovpmd[6640]: time="2019-05-14T12:00:57+03:00" level=error msg="can't retrieve server from db: record not found" May 14 12:00:57 wg ovpmd[6640]: time="2019-05-14T12:00:57+03:00" level=error msg="can not launch OpenVPN because system is not initialized" [root@wg server]# ovpm v i -s wg.example.net -t -n 10.255.0.0/16 -d 192.168.0.1 -p 1194 This operation will cause invalidation of existing user certificates. After this opeartion, new client config files (.ovpn) should be generated for each existing user.

Are you sure ? (y/N) y ERRO[0002] url must resolve to a known looback ip addr url="grpc://localhost:9090"

ovpm vpn init --hostname 192.168.0.1 This operation will cause invalidation of existing user certificates. After this opeartion, new client config files (.ovpn) should be generated for each existing user.

Are you sure ? (y/N) y ERRO[0001] url must resolve to a known looback ip addr url="grpc://localhost:9090"

cad commented 5 years ago

@rtripon can you make sure that your /etc/hosts file contains a line, mapping localhost to 127.0.0.1.

It should look similar with below.

$ cat /etc/hosts

# Static table lookup for hostnames.
# See hosts(5) for details.
127.0.0.1 localhost
rtripon commented 5 years ago

Hello, Seems that my VM doesnt add 127.0.0.1 to /etc/hosts. I've tried on another machine and manage to start ovpm.

rtripon commented 5 years ago

Can be closed, was a VM issue.