ubuntuusers.de

OpenVPN start Probleme

Status: Gelöst | Ubuntu-Version: Ubuntu 18.04 (Bionic Beaver)
Antworten |

linzus

Anmeldungsdatum:
31. Dezember 2015

Beiträge: 147

Hallo Community,

ich habe openvpn auf einem Server installiert und versuche den Dienst nun dort zu starten. Per

1
openvpn /etc/openvpn/server.conf

funktioniert alles prima und der Dienst und Listener starten wie erwartet. Ich sehe positive Einträge im Log.

Anschliessend habe ich den Dienst "systemd-enabled" per

1
systemctl enable openvpn

Nun möchte ich den Dienst starten mit:

1
systemctl start openvpn

Der dienst wird danach als gestartet angezeigt, es läuft jedoch weder ein Prozess oder der Listener...

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
root@server:/home/linus# systemctl status openvpn
● openvpn.service - OpenVPN service
   Loaded: loaded (/lib/systemd/system/openvpn.service; enabled; vendor preset: enabled)
   Active: active (exited) since Wed 2019-10-23 23:35:54 CEST; 7min ago
 Main PID: 2504 (code=exited, status=0/SUCCESS)
    Tasks: 0 (limit: 2299)
   CGroup: /system.slice/openvpn.service

Oct 23 23:35:54 server systemd[1]: Starting OpenVPN service...
Oct 23 23:35:54 server systemd[1]: Started OpenVPN service.

Weiterer Versuch mit Angabe der Konfig-File:

1
2
systemctl start openvpn@server
A dependency job for openvpn@server.service failed. See 'journalctl -xe' for details.

wobei:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
journalctl -xe
Oct 23 23:45:46 myserver systemd[1]: Stopped Network Name Resolution.
-- Subject: Unit systemd-resolved.service has finished shutting down
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit systemd-resolved.service has finished shutting down.
Oct 23 23:45:46 myserver systemd[1]: Starting Network Name Resolution...
-- Subject: Unit systemd-resolved.service has begun start-up
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit systemd-resolved.service has begun starting up.
Oct 23 23:45:46 myserver systemd-resolved[3760]: Positive Trust Anchors:
Oct 23 23:45:46 myserver systemd-resolved[3760]: . IN DS 19036 8 2 49aac11d7b6f6446702e54a5607371607a1a41855200fd2ce1cdde32f24e8fb5
Oct 23 23:45:46 myserver systemd-resolved[3760]: . IN DS 20326 8 2 e06d44b80b8f1d39a95c0b0d7h45d08458e880409bbc683457104237c7f8ec8d
Oct 23 23:45:46 myserver systemd-resolved[3760]: Negative trust anchors: 10.in-addr.arpa 16.172.in-addr.arpa 17.172.in-addr.arpa 18.172.in-addr.arpa 
Oct 23 23:45:46 myserver systemd-resolved[3760]: Using system hostname 'myserver'.
Oct 23 23:45:46 myserver systemd[1]: Started Network Name Resolution.
-- Subject: Unit systemd-resolved.service has finished start-up
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit systemd-resolved.service has finished starting up.
-- 
-- The start-up result is RESULT.
Oct 23 23:45:46 myserver root[3785]: /etc/dhcp/dhclient-exit-hooks.d/rfc3442-classless-routes returned non-zero exit status 2
Oct 23 23:45:46 myserver dhclient[3746]: bound to 1.2.3.4 -- renewal in 32577 seconds.
Oct 23 23:45:46 myserver ifup[3735]: bound to 1.2.3.4 -- renewal in 32577 seconds.
Oct 23 23:45:46 myserver systemd[1]: Reloading OpenBSD Secure Shell server.
-- Subject: Unit ssh.service has begun reloading its configuration
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit ssh.service has begun reloading its configuration
Oct 23 23:45:46 myserver sshd[1179]: Received SIGHUP; restarting.
Oct 23 23:45:46 myserver systemd[1]: Reloaded OpenBSD Secure Shell server.
-- Subject: Unit ssh.service has finished reloading its configuration
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit ssh.service has finished reloading its configuration
-- 
-- The result is RESULT.
Oct 23 23:45:46 myserver sshd[1179]: Server listening on 1.2.3.4 port 272.
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_client_restrictions=permit_mynetworks,permit_sasl
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_sender_restrictions=permit_mynetworks,reject_non_
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_relay_restrictions=reject_non_fqdn_recipient,reje
Oct 23 23:45:46 myserver ifup[3735]: RTNETLINK answers: Permission denied
Oct 23 23:45:46 myserver ifup[3735]: Failed to bring up eth0.
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_client_restrictions=permit_mynetworks,permit_sasl
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_sender_restrictions=permit_mynetworks,reject_non_
Oct 23 23:45:46 myserver ifup[3735]: postconf: warning: /etc/postfix/main.cf: unused parameter: mua_relay_restrictions=reject_non_fqdn_recipient,reje
Oct 23 23:45:46 myserver systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Oct 23 23:45:46 myserver systemd[1]: networking.service: Failed with result 'exit-code'.
Oct 23 23:45:46 myserver systemd[1]: Failed to start Raise network interfaces.
-- Subject: Unit networking.service has failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit networking.service has failed.
-- 
-- The result is RESULT.
Oct 23 23:45:46 myserver systemd[1]: Dependency failed for OpenVPN connection to server.
-- Subject: Unit openvpn@server.service has failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- Unit openvpn@server.service has failed.
-- 
-- The result is RESULT.
Oct 23 23:45:46 myserver systemd[1]: openvpn@server.service: Job openvpn@server.service/start failed with result 'dependency'.
Oct 23 23:46:00 myserver systemd-timesyncd[540]: Timed out waiting for reply from 91.189.94.4:123 (ntp.ubuntu.com).
Oct 23 23:46:10 myserver systemd-timesyncd[540]: Timed out waiting for reply from 91.189.91.157:123 (ntp.ubuntu.com).
Oct 23 23:46:20 myserver systemd-timesyncd[540]: Timed out waiting for reply from 91.189.89.199:123 (ntp.ubuntu.com).
Oct 23 23:46:30 myserver systemd-timesyncd[540]: Timed out waiting for reply from 91.189.89.198:123 (ntp.ubuntu.com).

Um Hilfe wäre ich extrem dankbar.

VG

lubux

Anmeldungsdatum:
21. November 2012

Beiträge: 14347

linzus schrieb:

ich habe openvpn auf einem Server installiert und versuche den Dienst nun dort zu starten. Per

1
openvpn /etc/openvpn/server.conf

funktioniert alles prima und der Dienst und Listener starten wie erwartet. Ich sehe positive Einträge im Log.

Wie sind in diesem Fall, die Ausgaben von:

ip a
sudo netstat -ulpena | grep -i vpn

? Kannst Du auch eine VPN-Verbindung zu dem so gestarteten VPN-Server, herstellen? Poste auch die Ausgaben von:

systemctl cat openvpn
systemctl cat openvpn@service
systemctl status networking.service

linzus

(Themenstarter)

Anmeldungsdatum:
31. Dezember 2015

Beiträge: 147

Hi @lubux

ich habe das Problem gefunden:

ipv6 war deaktiviert und ifup konnte das Interface eth0 nicht starten. Nachdem ich IPv6 wieder aktiviert habe, funktioniert alles wie erwartet.

Wieso ifup allerdings das Interface nicht starten kann, nur weil IPv6 deaktiviert ist verstehe ich nicht. Es muss doch möglich sein das Interface auch ohne zu betreiben?

VG

Antworten |