I did nothing understands , but the solution for my problem
-
- delete certbot all ( source-list not delete)
apt purge certbot-nginx
script
#!/bin/bash
list="/var/lib/systemd/timers/stamp-certbot.timer
/var/lib/dpkg/info/python3-certbot.postinst
/var/lib/dpkg/info/python3-certbot.md5sums
/var/lib/dpkg/info/python3-certbot.prerm
/var/lib/dpkg/info/python3-certbot.list
/var/lib/apt/lists/ppa.launchpad.net_certbot_certbot_ubuntu_dists_xenial_main_binary-i386_Packages
/var/lib/apt/lists/ppa.launchpad.net_certbot_certbot_ubuntu_dists_xenial_InRelease
/var/lib/apt/lists/ppa.launchpad.net_certbot_certbot_ubuntu_dists_xenial_main_i18n_Translation-en
/var/lib/apt/lists/ppa.launchpad.net_certbot_certbot_ubuntu_dists_xenial_main_binary-amd64_Packages
/usr/share/doc/python3-certbot
/usr/lib/python3/dist-packages/certbot-0.26.1.egg-info
/usr/lib/python3/dist-packages/certbot"
#/etc/apt/sources.list.d/certbot-ubuntu-certbot-xenial.list.save #
#/etc/apt/sources.list.d/certbot-ubuntu-certbot-xenial.list # not delete
#/etc/apt/trusted.gpg.d/certbot_ubuntu_certbot.gpg
#/etc/apt/trusted.gpg.d/certbot_ubuntu_certbot.gpg~
for i in $list ; do
rm -rf $i
done
echo "certbot was deleted"
exit 0
-
- update or delete certificates
apt-get install --reinstall ca-certificates
dpkg-reconfigure ca-certificates
or
apt remove --purge ca-certificates
apt autoremove
apt install ca-certificates
apt install software-properties-commo
apt install libwww-perl #if you use GET
-
- add certifficate
certbot --nginx -d next.exapmle.com