mirror of https://github.com/tteck/Proxmox.git
Compare commits
No commits in common. "c702652a000056c0d9189bffa8b6111b5088b0bd" and "8ce0ad13ab1618c36cd4a80a894a1bfa4c784645" have entirely different histories.
c702652a00
...
8ce0ad13ab
|
@ -44,15 +44,11 @@ excluded_containers=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "
|
|||
|
||||
function trim_container() {
|
||||
local container=$1
|
||||
local name=$(pct exec "$container" hostname 2>/dev/null || echo "No hostname because the container is not running")
|
||||
local name=$(pct exec "$container" hostname)
|
||||
header_info
|
||||
echo -e "${BL}[Info]${GN} Trimming ${name} ${CL} \n"
|
||||
local before_trim=$(lvs | awk -F '[[:space:]]+' 'NR>1 && (/Data%|'"$container"'/) {gsub(/%/, "", $7); print $7}')
|
||||
echo -e "${RD}Data before trim $before_trim%${CL}"
|
||||
pct fstrim $container
|
||||
local after_trim=$(lvs | awk -F '[[:space:]]+' 'NR>1 && (/Data%|'"$container"'/) {gsub(/%/, "", $7); print $7}')
|
||||
echo -e "${GN}Data after trim $after_trim%${CL}"
|
||||
sleep 1.5
|
||||
sleep 1
|
||||
}
|
||||
|
||||
for container in $(pct list | awk '{if(NR>1) print $1}'); do
|
||||
|
|
|
@ -99,7 +99,7 @@ EOF
|
|||
esac
|
||||
|
||||
if [[ "${VERSION}" == "bookworm" ]]; then
|
||||
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "CEPH PACKAGE REPOSITORIES" --menu "The 'Ceph Package Repositories' provides access to both the 'no-subscription' and 'enterprise' repositories (initially disabled).\n \nCorrect 'ceph package sources?" 14 58 2 \
|
||||
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "CEPH PACKAGE REPOSITORIES" --menu "The 'Ceph Package Repositories' provides access to both the 'no-subscription' and 'enterprise' repositories.\n \nCorrect 'ceph package sources?" 14 58 2 \
|
||||
"yes" " " \
|
||||
"no" " " 3>&2 2>&1 1>&3)
|
||||
case $CHOICE in
|
||||
|
|
Loading…
Reference in New Issue