I have ActiveDirectory users created with rol Administrator but when I try to open a node shell with these users I get the error "Connection failed (Error 403: Permission check failed (realm != pam)) "
raise_perm_exc("realm $realm != pam") if $realm ne 'pam';
#!/bin/bash
# Define backup directory
backup_dir="$HOME/pve-backup"
# Create backup directory if it doesn't exist
mkdir -p "$backup_dir"
# Get current date and time
datetime=$(date +"%Y%m%d%H%M%S")
# Backup file
cp /usr/share/perl5/PVE/API2/Nodes.pm "$backup_dir/nodes.pm.$datetime-bak"
# Comment out lines containing "!= pam"
sed -i '/!= pam/s/^/# /' /usr/share/perl5/PVE/API2/Nodes.pm
echo "Backup created and lines commented out."
# Restart services
systemctl restart pvedaemon.service pveproxy.service
echo "Services restarted."
I'm the only one with access to my server, I just have SSO, so I don't need to log in everywhere. I'm using OpenID and I don't have any Windows servers/machines, I could do it via LDAP but just disabling the check is way simplerYou could join your PVE server itself to the Active Directory domain at the OS level instead of the PVE GUI. There's at least two ways to go about that (samba and sssd) and a number of tutorials out there about how to join Debian to AD. I think if you were to do that the pam realm would work for all users.
But do you really want people to be able to log into the host? Seems like a bad idea.
I wish I could patch it, but sadly, PBS is a bunch of binaries.Took me quite some time to find the right thread - also using SSO here.
This patch should not only be applied to PVE but PBS too. AND: PBS is also missing setting a realm as default.
The script by @Games_Crack does not work for PBS, since those files do not exist.