Proxmox
Remove No valid subscription=====>
cd /usr/share/javascript/proxmox-widget-toolkit
cp proxmoxlib.js proxmoxlib.js.bak
nano proxmoxlib.js
(ctrl+w and search No valid subscription)
(change to)
void({ //Ext.Msg.show({
title: gettext('No valid subscription'),
systemctl restart pveproxy.service
for check
grep -n -B 1 'No valid sub' proxmoxlib.js
============================================
# Disable Commercial Repo
sed -i "s/^deb/\#deb/" /etc/apt/sources.list.d/pve-enterprise.list
apt-get update
# Add PVE Community Repo
echo "deb http://download.proxmox.com/debian/pve $(grep "VERSION=" /etc/os-release | sed -n 's/.*(\(.*\)).*/\1/p') pve-no-subscription" > /etc/apt/sources.list.d/pve-no-enterprise.list
apt-get update
# Remove nag
echo "DPkg::Post-Invoke { \"dpkg -V proxmox-widget-toolkit | grep -q '/proxmoxlib\.js$'; if [ \$? -eq 1 ]; then { echo 'Removing subscription nag from UI...'; sed -i '/data.status/{s/\!//;s/Active/NoMoreNagging/}' /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js; }; fi\"; };" > /etc/apt/apt.conf.d/no-nag-script
apt --reinstall install proxmox-widget-toolkit
sed -i.bak 's/NotFound/Active/g' /usr/share/perl5/PVE/API2/Subscription.pm && systemctl restart pveproxy.service
sed -Ezi.bak "s/(Ext.Msg.show\(\{\s+title: gettext\('No valid sub)/void\(\{ \/\/\1/g" /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js && systemctl restart pveproxy.service
===============================================
wget https://github.com/Jamesits/pve-fake-subscription/releases/download/v0.0.7/pve-fake-subscription_0.0.7_all.deb
dpkg -i pve-fake-subscription_0.0.7_all.deb
pve-fake-subscription
lsblk
blkid -o list
fdisk -l
Directory form Disk
mkdir /mnt/usb-data mount /dev/sdc1 /mnt/usb-data
Setup Permanent Mount
In order to mount your USB drive permanently after reboot add a line into your /etc/fstab config file. If drives are added or removed from the Proxmox the device may change. For this reason the partion UUID will need to be used instead of the block device name.
" ls -l /dev/disk/by-uuid/* "
lrwxrwxrwx 1 root root 10 Jul 9 14:08 /dev/disk/by-uuid/17217120-ae4b-407a-90a2-d55d83dc23f1 -> ../../sdb1
lrwxrwxrwx 1 root root 10 Jul 9 14:08 /dev/disk/by-uuid/26da1ea2-5a38-47ab-821e-5059d28a7b0f -> ../../dm-1
lrwxrwxrwx 1 root root 10 Jul 9 14:08 /dev/disk/by-uuid/26ff5094-3a30-4921-b4e2-8b96dc7fb163 -> ../../dm-0
Above will give you the uuid. Open the fstab for editing
-------------------------------------------------------
" nano /etc/fstab "
Add this line to your fstab using the correct UUID.-->
-----------------------------------------------------
" /dev/disk/by-uuid/17217120-ae4b-407a-90a2-d55d83dc23f1 /mnt/usb-data ext4 defaults 0 "
/dev/disk/by-uuid/17217120-ae4b-407a-90a2-d55d83dc23f1 /mnt/usb-drive ext4 defaults 0
Mount drive-->" mount -a "
Log in via ssh and
look at the current state: pvecm status
tell the system to temporarily accept that: pvecm expected 2
stop cluster services and corosync on all servers in the cluster. systemctl stop corosync systemctl stop pve-cluster
After do this in all servers, in just one server (choose one to reboot after procedure) do: pmxcfs -l and edit the file /etc/pve/corosync.conf line:
quorum {
provider: corosync_votequorum
}
to:
quorum {
provider: corosync_votequorum
two_node: 1
}
after change, reboot this server.
Join Node to Cluster via Command Line
pvecm add IP-ADDRESS-CLUSTER
pvecm add 10.0.0.99
pvecm add <any_proxmox_node_ip) -force
Remove a Cluster Node
pvecm status
pvecm nodes
systemctl status corosync <--check if everything is working properly
systemctl restart corosync
systemctl stop pve-cluster
systemctl stop corosync
pmxcfs -l
m /etc/pve/corosync.conf
rm -r /etc/corosync/*
killall pmxcfs
systemctl start pve-cluster
pvecm delnode oldnode, pvecm delnode ProxmoxNUC , pvecm delnode ProxmoxVE
pvecm expected 1
Change Hostname
Rename a standalone PVE host, you need to edit the following files:
/etc/hosts
/etc/hostname
You can get the version of proxmox using the pveversion command.
pveversion