IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
Otherwise the created vlan bridge has the default MTU, which is
unexpected when the original bridge has some other MTU configured.
We already do this for the firewall bridges, so we should do so too for
the vlan bridges.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This patch introduces callback based filtering functionality for logfile dumps.
Further, the `dump_logfile` function is split into a reusable part for dumps
generated based on a filehandle. The state parameter can be used to keep the
state for multiple consecutive function invocations.
Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
It's possible to have a
/proc/sys/net/ipv6/ directory
but no
/proc/sys/net/ipv6/conf/$iface/disable_ipv6
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
The dump_logfile now returns the whole log file if the limit
parameter is set to 0. This must be done explicitly though, as in the
case of 'limit' being undefined, the default as before, 50 will be
used.
Signed-off-by: Daniel Tschlatscher <d.tschlatscher@proxmox.com>
ovs port don't have sysfs path
"/sys/class/net/$iface/brport/learning"
We need to check if the value is undef too
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
under some conditions, like when calling it in the api where we have
a 30s pveproxy limit, we want to make use of the '--timeout' parameter
of the file-restore binary, but we may want to call it in the future
where we don't want add timeout.
To achieve that, add an extendable 'extra_params' hash parameter to
'file_restore_list' and use the timeout from there.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
as we now auto-detect if the 'bridge-disable-mac-learning' is set in
the Network::tap_plug method and disable learning if so, we need to
ensure that the qemu-server and pve-container can cope with that by
manually registering the guests MAC into the FDB.
So this certainly isn't a hard break, but as network is dead for the
guest on update, if that option is set and the new qemu-server and/or
pve-container packages ain't yet updated, it seems still worthy of a
break.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
avoids that we need to repeat the same code hunk two times each for
CT and VM call sites.
If required it can be simply overridden by setting it explicitly on
call.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
that unless stuff is just hard to read and against our code style.
note that there's also basically the same helper in SysFSTools, and
neither is really dependent on sysfs or procfs semantics, so both
probably should go away..
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
as often only warn really makes it out of perl/our pit of std out/err
handling (e.g., I had a case where neither print STDERR nor syslog
worked, but warn did)
also, the tests are rather brittle w.r.t their expect_fail variant,
as the actual expected error should be enforced.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
this can result in a broken config due to it getting written out on
write_config serialization, and if a plugin did not declare `id` as
an option it understood (none do currently), it would then fail the
next parse, far from ideal...
As the section ID is available already anyway we should probably just
drop this, but for now avoid rushed changes and just make it
conforming to section config semantics and check if the option is
actually understood by the respective section type we're working on.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
It was PVE::Jobs::Plugin in pve-manager so we don't have any clash
potential, so no Breaks record required in d/control.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This adds an opt-in flag to `parse_config` and
`write_config` to allow for unknown section types.
This will simply be left unverified.
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
The only expression it appears in short-circuits, because the line
before ensures that $shares is guaranteed to be set.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
from qemu-server, for re-use in pve-container.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
Reviewed-by: Fiona Ebner <f.ebner@proxmox.com>
Instead, use the one from the initial configuration. The only current
caller is in PMG and the namespace parameter set there agrees with
the one from the initial configuration, so this is not actually a
breaking change.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
All existing callers for functions with namespaced parameters just
re-use the one that's passed in via the initial configuration already,
so there is no need for namespaced parameters currently.
If the need for one PBS client to handle multiple namespaces arises, a
set_namespace() function could be added, or the relevant functions
could take an additional parameter, either for just the namespace or
like $cmd_opts in restore_pxar().
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
For get_snapshots(), also set the default when no namespaced parameter
is present at all.
This would break any callers that have a namespace in the initial
config and explicitly don't set it for a later call, but the only
such caller is restore_pxar() in PMG, which /should/ be using the
namespace!
In other words, this implicitly fixes the restore_pxar() call in PMG
and avoids the need to extract the namespace from the configuration
(which already is present in the client) on the call site for all
functions that currently take a namespaced parameter.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Otherwise, there will be
Result: {
"data": null
}
when calling via a CLI tool for example. This also makes it consistent
with PVE in preparation to switch to using PBSClient there.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
It's currently possible to add a remote in PMG without password (via
API), but deletion of such a remote would fail here.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Based on a patch from Fiona[0] that proposed to move it to
guest-common, rather go for common where the CGroup module resides to
avoid having to touch multiple sites if this changes another time
(hopefully not)
[0]: https://lists.proxmox.com/pipermail/pve-devel/2022-October/054225.html
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Since even in pure unified layouts there may be a `name=systemd` v1
cgroup mounted additionally (manually or potentially via
systemd-nspawn apparently), we should check what's actually mounted
at `/sys/fs/cgroup` rather than whether v1 cgroups exist.
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>