Как настроить apt -listchanges для отправки уникального сводного электронного письма при выполнении автоматических -обновлений

Я создал скрипт на основе пользовательского ввода, чтобы избежать ошибок

    #!/bin/bash
    echo "enter the character need to display"
    read old
    echo "enter the  need character to be replaced"
    read new
    sed "s/$old/$new/g" r.txt>file_$old.txt



First it will ask for old content which need to be replaced. 
Second it will ask for new content which needs to be replaced with old content
THird it saves the file  after each iteration

Based on how  characters need to be replaced you can add above mentioned script in for loop
1
15.04.2021, 14:25
1 ответ

Проблема была сunattended-upgrades:с версии buster, введена система minimal steps

// Split the upgrade into the smallest possible chunks so that

// they can be interrupted with SIGTERM. This makes the upgrade

// a bit slower but it has the benefit that shutdown while a upgrade

// is running is possible (with a small delay)

//Unattended-Upgrade::MinimalSteps "true";

Поскольку каждый пакет по умолчанию обновляется независимо от других, программа apt-listchangesвызывалась несколько раз, поэтому в процессе обновления отправлялось письмо по каждому пакету, обновленному для каждой машины.

Чтобы решить эту проблему, я просто изменил параметр на Unattended-Upgrade::MinimalSteps "false";; Надеюсь, это поможет другим =)

1
28.04.2021, 22:52

Теги

Похожие вопросы