SYSTEM WARNING: 'date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone.' in '/usr/share/mantis/www/core.php' line 264

0004277: openvpn restart script errors - MantisBT Endian Bugtracker
Endian Issue Tracker





Please see now our new Bugtracker system: JIRA








View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004277Endian FirewallOpenVPN Client and Serverpublic2012-02-08 14:402012-02-24 13:59
Reporterluca-endian 
Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version2.4 
Target VersionFixed in Version2.4.1 
Summary0004277: openvpn restart script errors
Descriptionroot@kyle:~ # restartopenvpn.py -df
2012-02-07 17:04:04,781 - restartopenvpn.py[30897] - INFO - Initializing notification for service 'openvpnserver'
2012-02-07 17:04:04,789 - restartopenvpn.py[30897] - DEBUG - Read settings file /var/efw/ethernet/settings
2012-02-07 17:04:05,030 - restartopenvpn.py[30897] - DEBUG - Dynamically assign tap device
2012-02-07 17:04:05,082 - restartopenvpn.py[30897] - DEBUG - Got device tap0
2012-02-07 17:04:05,159 - restartopenvpn.py[30897] - DEBUG - Config: {'auth_type': 'cert', 'blue_address': '192.168.2.15', 'domain': 'localdomain', 'cert_auth': '', 'push_global_dns': 'on', 'blue_netmask': '255.255.255.0', 'purple_ip_begin': '192.168.0.129', 'green_dev': 'br0', 'green_address': '192.168.0.15', 'config_type': '7', 'purple_ip_end': '192.168.0.190', 'duplicate_cn': 'off', 'purple_device': 'tap0', 'orange_netaddress': '192.168.1.0', 'blue': {'members': None, 'settings': {'ips_arr': ['192.168.2.0/255.255.255.0'], 'netaddress': '192.168.2.0', 'ips_obj': [192.168.2.0/24], 'dev': 'tun4', 'broadcast': '192.168.2.255', 'ips': '192.168.2.15/24', 'netmask': '255.255.255.0', 'address': '192.168.2.15', 'cidr': '24'}}, 'orange_address': '192.168.1.15', 'green_cidr': '24', 'bridged': 'on', 'orange': {'members': ['eth2'], 'settings': {'ips_arr': ['192.168.1.0/255.255.255.0'], 'netaddress': '192.168.1.0', 'ips_obj': [192.168.1.0/24], 'dev': 'br1', 'broadcast': '192.168.1.255', 'ips': '192.168.1.15/24', 'netmask': '255.255.255.0', 'address': '192.168.1.15', 'cidr': '24'}}, 'push_domain': '', 'green_netaddress': '192.168.0.0', 'openvpn_protocol': 'udp', 'push_global_networks': '', 'openvpn_port': '1194', 'blue_dev': 'tun4', 'client_to_client': '', 'openvpn_enabled': '', 'drop_dhcp': '', 'green_netmask': '255.255.255.0', 'bridge_to': 'GREEN', 'blue_ips': '192.168.2.15/24', 'green_broadcast': '192.168.0.255', 'orange_ips': '192.168.1.15/24', 'orange_netmask': '255.255.255.0', 'global_dns': '192.168.0.15', 'blue_cidr': '24', 'global_networks_arr': [], 'enabled': False, 'global_networks': '', 'orange_dev': 'br1', 'green': {'members': ['eth0'], 'settings': {'ips_arr': ['192.168.0.0/255.255.255.0'], 'netaddress': '192.168.0.0', 'ips_obj': [192.168.0.0/24], 'dev': 'br0', 'broadcast': '192.168.0.255', 'ips': '192.168.0.15/24', 'netmask': '255.255.255.0', 'address': '192.168.0.15', 'cidr': '24'}}, 'blue_broadcast': '192.168.2.255', 'orange_broadcast': '192.168.1.255', 'blue_netaddress': '192.168.2.0', 'purple_net': '192.168.10.0/24', 'orange_cidr': '24', 'green_ips': '192.168.0.15/24'}
2012-02-07 17:04:05,174 - restartopenvpn.py[30897] - DEBUG - Save old settings file /etc/firewall/inputfw/openvpn.conf
2012-02-07 17:04:05,180 - restartopenvpn.py[30897] - INFO - Write config file /etc/firewall/inputfw/openvpn.conf
2012-02-07 17:04:05,455 - restartopenvpn.py[30897] - DEBUG - Save old settings file /etc/sysconfig/openvpn
2012-02-07 17:04:05,466 - restartopenvpn.py[30897] - INFO - Write config file /etc/sysconfig/openvpn
2012-02-07 17:04:05,537 - restartopenvpn.py[30897] - DEBUG - Save old settings file /etc/openvpn/openvpn.conf
2012-02-07 17:04:05,555 - restartopenvpn.py[30897] - INFO - Write config file /etc/openvpn/openvpn.conf
2012-02-07 17:04:05,769 - restartopenvpn.py[30897] - INFO - Rewrite user config files
Traceback (most recent call last):
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 250, in ?
    loadConfig(username)
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 195, in loadConfig
    invalid.append(getInvalidIps(config_value.get('ORANGE')))
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 158, in getInvalidIps
    invalid.append(v.broadcast)
AttributeError: 'PlainFile' object has no attribute 'broadcast'
Traceback (most recent call last):
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 250, in ?
    loadConfig(username)
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 195, in loadConfig
    invalid.append(getInvalidIps(config_value.get('ORANGE')))
  File "/usr/local/bin/rewriteopenvpnuserconfig.py", line 158, in getInvalidIps
    invalid.append(v.broadcast)
AttributeError: 'PlainFile' object has no attribute 'broadcast'
2012-02-07 17:04:09,089 - restartopenvpn.py[30897] - INFO - Stop openvpn
2012-02-07 17:04:09,370 - restartopenvpn.py[30897] - DEBUG - Openvpn should not start. Don't start openvpn
Tagspurple
Attached Files

- Relationships

-  Notes
(0007706)
luca-endian (developer)
2012-02-09 13:41

No data are pushed to the client.
Tested with static ip addres
(0007707)
thomas-endian (developer)
2012-02-09 13:45

every new parameter under accounts and new accounts are no longer written /var/openvpn/clients files
(0007708)
thomas-endian (developer)
2012-02-09 13:46

I think only on the new ARM the account renew/rewirte work...
(0007709)
thomas-endian (developer)
2012-02-09 14:04

the error comes with the last 11 updates, on our Live Firewall with 11 open packages everything is wonderful...
(0007710)
luca-endian (developer)
2012-02-09 14:04

Yes because the error is triggered by this script:
/usr/local/bin/rewriteopenvpnuserconfig.py
Seems something wrong while getting green configuration

    invalid.append(getInvalidIps(config_value.get('GREEN')))

I confirm arm works.
(0007712)
luca-endian (developer)
2012-02-09 15:57

seems that the error comes with endian-core-2.4.23-0.endian10
(0007713)
ardit-endian (developer)
2012-02-09 16:27

work-around (simple)

copy an old /var/openvpn/clients/$username file to a new one and edit it pushing your desired routes.
(0007714)
peter-endian (administrator)
2012-02-09 17:25

great, this is a funny error because in reality this was wrong since ever
only that it did not traceback before the update of these which added something completely not related to the error.

we will fix it high priority for 2.5, 2.4-arm, 2.4

2.4-arm should not traceback because there was no update of endian-core. but the error is also there.

- Issue History
Date Modified Username Field Change
2012-02-08 14:40 luca-endian New Issue
2012-02-08 14:47 luca-endian Tag Attached: purple
2012-02-09 13:41 luca-endian Note Added: 0007706
2012-02-09 13:45 thomas-endian Note Added: 0007707
2012-02-09 13:46 thomas-endian Note Added: 0007708
2012-02-09 13:51 luca-endian Status new => confirmed
2012-02-09 14:04 thomas-endian Note Added: 0007709
2012-02-09 14:04 luca-endian Note Added: 0007710
2012-02-09 15:57 luca-endian Note Added: 0007712
2012-02-09 16:27 ardit-endian Note Added: 0007713
2012-02-09 17:25 peter-endian Note Added: 0007714
2012-02-24 13:59 luca-endian Status confirmed => closed
2012-02-24 13:59 luca-endian Resolution open => fixed
2012-02-24 13:59 luca-endian Fixed in Version => 2.4.1

Copyright © 2005-2008 Endian, SRL. All rights reserved.


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker