Commit Graph

518 Commits

Author SHA1 Message Date
Wolfgang Bumiller
f3ccd9b4b9 Network: add disable_ipv6 and use it
Many interfaces used to get an ipv6 link-local address which
was usually unusable and therefore pointless.

In order to ensure consistency this is called in various
places:
* $bridge_add_interface() and $ovs_bridge_add_port() because
  it's generally a good choice for bridge ports.
* tap_create() and veth_create() because the activate the
  interfaces and we want to avoid the link local address to
  exist temporarily between bringing the interface up and
  adding it to a bridge.
* create_firewall_bridge_*() because firewall bridges aren't
  meant to have addresses either.
* activate_bridge_vlan() - if vlan_filtering is disabled we
  create vlan-bridges and neither them nor their physical
  ports should have link local addresses.
2016-09-29 12:45:23 +02:00
Dietmar Maurer
b54ad320a5 fix doc generator (do not convert efidisk0 to efidisk[N])
Also fix spacing in typetext generator.
2016-09-29 12:15:47 +02:00
Dietmar Maurer
1eac8b4b2c bump version to 4.0-73 2016-09-16 08:48:41 +02:00
Dietmar Maurer
05185ea25a schema_get_type_text: always access values as number
Else PVE::RESTHandler::api_dump prints values as strings.
2016-09-05 09:27:50 +02:00
Dietmar Maurer
534d427098 add typetext property for more complex types 2016-09-05 07:47:32 +02:00
Fabian Grünbichler
0ddae1ce6d bump version to 4.0-72 2016-08-16 17:16:49 +02:00
Wolfgang Bumiller
ce338f4fbc harden file_set_contents against symlink attacks 2016-08-16 17:12:55 +02:00
Wolfgang Bumiller
88a490ff71 allow Regexp objects for strings in the schema
The 'pattern' property has type string and format regex, so
it makes sense to allow Regexp objects to be used for it.

While check_type() doesn't know the format, Regexp objects
can be treated like strings anyway, including compared via
'eq' or matched via '=~', so we allow strings to generally
come from a Regexp object.
2016-07-14 10:28:57 +02:00
Wolfgang Bumiller
123921731a tools: optional prefix for random_ether_addr 2016-07-14 09:01:01 +02:00
Wolfgang Bumiller
084dc74db6 bump version to 4.0-71 2016-07-11 11:34:10 +02:00
Wolfgang Bumiller
d743b69c4b fix mac address generation limitation
Commit de9a267 introduced vec() to optimize the generation
by using binary operations instead of converting back and
forth between hex and strings, but forgot to switch over to
the binary sha1 method. This resulted in only the first 6
hex digits of the output string making up the address.
2016-07-05 13:42:30 +02:00
Fabian Grünbichler
e561bc74bb fix 1046: add non-snapshotted disks as unused 2016-07-05 09:39:20 +02:00
Wolfgang Bumiller
28705ff6d1 df: untaint the result 2016-07-04 14:13:41 +02:00
Dietmar Maurer
fb1391aae7 use new repoman toolkit 2016-06-25 15:18:39 +02:00
Wolfgang Bumiller
a3f6f8a595 bump version to 4.0-70 2016-06-22 11:25:37 +02:00
Wolfgang Bumiller
a712bf6e37 Fix #132: hold a lock while setting up vlan bridges
It's possible for two simultaneous VM starts to try to
create vlan bridges on non-vlan-aware bridges
simultaneously, which causes one of them to fail with the
error "can't add bridge ...".
2016-06-21 15:01:30 +02:00
Dietmar Maurer
6a47f4b05d bump version to 4.0-69 2016-06-21 06:54:15 +02:00
Wolfgang Bumiller
78e912a3b7 vlan fixups: remove existing vlan ids
bridge_add_interface should remove the existing vids from
the interface (which is usually 1, which was previously left
on the interface)
2016-06-21 06:53:35 +02:00
Dietmar Maurer
e94ca8c8e6 bump version to 4.0-68 2016-06-09 17:56:47 +02:00
Fabian Grünbichler
c9c6d91073 catch malformed mailto/mailfrom in sendmail 2016-06-09 17:55:38 +02:00
Fabian Grünbichler
1a0c010327 remove duplicate 'set -o pipefail' 2016-06-07 10:37:25 +02:00
Dietmar Maurer
1912759d0e bump version to 4.0-67 2016-06-03 11:27:28 +02:00
Wolfgang Bumiller
0b9cf991e5 added: enter_systemd_scope
This essentially performas the task of systemd-run while
also waiting for the job to finish.

With the systemd-run version in jessie we run into a race
condition where the executed process can start forking child
processes before the systemd daemon is done setting up the
scope's cgroups, causing the children to NOT be included in
the cgroups. This means the child processes (in our case
qemu) will not adhere to the limits we want to apply to it
via cgroups.

enter_systemd_scope() performs the setup task of systemd-run
and waits for the job to finish, after this we can spawn the
qemu process without systemd-run.
2016-06-03 11:26:13 +02:00
Wolfgang Bumiller
f0d1b04fda move Network::get_active_interfaces to ProcFSTools
This avoids a circular dependency between PVE::INotify and
PVE::Network.

Also renamed to get_active_network_interfaces since the
package name now doesn't hint at this anymore.
2016-06-03 11:22:40 +02:00
Wolfgang Bumiller
19e609fd33 add netmasks starting from /8 to local netmask list 2016-06-03 11:21:57 +02:00
Wolfgang Bumiller
e43faad9ff Consider /31 and /32 valid subnet masks.
Since we already allow this for container IP addresses it is
reasonable to assume the host might be using such a setup as
well. (You can use an additional route to reach the gateway
and then simply have no "LAN".) Some people seem to want
this...
2016-06-03 11:21:42 +02:00
Dietmar Maurer
c1a4a02b98 bump version to 4.0-66 2016-06-01 11:32:28 +02:00
Wolfgang Bumiller
c064776576 Allow O_PATH and O_TMPFILE to be exported 2016-06-01 11:29:59 +02:00
Wolfgang Bumiller
21c56a963f added: openat, mkdirat 2016-06-01 11:29:49 +02:00
Dietmar Maurer
150f4bc65a bump version to 4.0-65 2016-05-25 11:34:12 +02:00
Thomas Lamprecht
361d54c329 run_cli_handler: add no_rpcenv parameter
This can be used if a CLIHandler child class does not needs or wants
RPCEnv. E.g. this is the case with pve-cluster, as it's a dependency
of the package where RPCEnv resides (access-control), so this can be
set to avoid a implicit circular build dependency.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2016-05-25 11:33:28 +02:00
Dietmar Maurer
6e537f49bd bump version to 4.0-64 2016-05-23 06:27:01 +02:00
Wolfgang Bumiller
971353e8ac print_property_string: don't print the default key's name
We had this behavior in the past and didn't mean to change
it.
2016-05-23 06:24:46 +02:00
Dietmar Maurer
32f8e0c75b improve doc generator, introduce verbose_description property 2016-05-19 13:11:26 +02:00
Dietmar Maurer
c8e5d28e29 export bond_modes (define with 'our' instead of 'my')
So that other people can use that from outside.
2016-05-18 16:49:19 +02:00
Wolfgang Bumiller
b8246bfca7 typo fix 2016-05-18 12:55:50 +02:00
Dietmar Maurer
5ee7c8243f bump version to 4.0-63 2016-05-18 11:23:49 +02:00
Dominik Csapak
5d662b31b7 show warning when using VLAN 1 on a VLAN aware bridge
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2016-05-18 11:23:03 +02:00
Wolfgang Bumiller
899f8c4aa5 support for predictable network interface device names
Based on patch from: Igor Vlasenko <viy@altlinux.org>
2016-05-17 16:14:15 +02:00
Dietmar Maurer
cee324e053 bump version to 4.0-62 2016-05-14 11:27:46 +02:00
Dietmar Maurer
1801bdaa93 replace the smartmatch operator 2016-05-12 11:37:00 +02:00
Dietmar Maurer
b7ef63ab0a re-enable run_cli, which is still in use 2016-05-12 07:46:30 +02:00
Dietmar Maurer
2289890bad print_property_string: correctly implement skip parameter 2016-05-12 07:25:51 +02:00
Dietmar Maurer
c88c582dec fix keyAlias test 2016-05-11 13:04:01 +02:00
Dietmar Maurer
dc1401ad0f bump version to 4.0-61 2016-05-11 11:10:36 +02:00
Dietmar Maurer
d8c2b9477c JSONSchema fix property sort order
order: default_key, required options, other
2016-05-11 10:57:06 +02:00
Dietmar Maurer
bf27456b4e remove PodParser.pm, implement keyAlias feature
The keyAlias feature replaces the previous 'group_ feature.
2016-05-11 10:02:34 +02:00
Dietmar Maurer
457c3fcb1e schema_get_type_text: return format_description if available 2016-05-07 10:57:14 +02:00
Dietmar Maurer
825247bdb2 update changelog 2016-05-04 08:11:02 +02:00
Emmanuel Kasper
25eea093dd When starting in debug mode, starts the daemon without going through systemctl
This fixes the problem that debug options for daemons were ignored and sets
the following behaviour for the daemons when -debug 1 is given
 * start on foreground with debug ouput on the console
 * do not start a sytemd unit

Starting the systemd unit in debug mode makes less sense because:
 * systemd will put the daemon in the background
 * systemd ignores environment variables so the only way to start
 the daemon with options would be through reading a config file

tested with pveproxy, pve-ha-lrm, pve-ha-crm
2016-05-04 08:08:37 +02:00