[GH-ISSUE #1863] configparser.NoSectionError: No section: 'centosplus' #1460

Closed
opened 2026-02-27 11:17:13 +03:00 by kerem · 4 comments
Owner

Originally created by @Super-Gil on GitHub (Apr 1, 2020).
Original GitHub issue: https://github.com/modoboa/modoboa/issues/1863

Impacted versions

  • Modoboa: Newest
  • installer used: Yes/No ? Yes
  • Webserver: Nginx/Apache Nginx

Steps to reproduce

  1. reset my centos server to version centos 7.7
  2. yum update
  3. yum install python36
  4. git clone https://github.com/modoboa/modoboa-installer
  5. cd modoboa-installer
  6. sudo ./run.py [mydomain]

Current behavior

Raising error when installing postfix

Expected behavior

Should complete the installation.

Error message:

[root@iZj6c78t3hp8rnwcpnk0mnZ modoboa-installer]# sudo python3 ./run.py anckak.tech
Welcome to Modoboa installer!

Warning:
Before you start the installation, please make sure the following DNS records exist for domain 'anckak.tech':
mail IN A
IN MX mail.anckak.tech.

Your mail server will be installed with the following components:
modoboa automx amavis clamav dovecot nginx razor postfix postwhite spamassassin uwsgi radicale opendkim
Do you confirm? (Y/n) y
The process can be long, feel free to take a coffee and come back later ;)
Starting...
Overwrite the existing SSL certificate? (y/N) y
Generating new self-signed certificate
Installing amavis
Installing spamassassin
Installing razor
Installing clamav
Installing modoboa
User modoboa already exists, skipping creation but please make sure the /srv/modoboa directory exists.
Target directory for Modoboa deployment (/srv/modoboa/instance) already exists. If you choose to continue, it will be removed.
Do you confirm? (Y/n) y
Installing automx
User automx already exists, skipping creation but please make sure the /srv/automx directory exists.
Installing radicale
User radicale already exists, skipping creation but please make sure the /srv/radicale directory exists.
Installing uwsgi
Installing nginx
Installing opendkim
Installing postfix
Traceback (most recent call last):
File "./run.py", line 136, in
main(sys.argv[1:])
File "./run.py", line 126, in main
scripts.install("postfix", config, args.upgrade)
File "/root/modoboa-installer/modoboa_installer/scripts/init.py", line 22, in install
getattr(script, appname.capitalize())(config, upgrade).run()
File "/root/modoboa-installer/modoboa_installer/scripts/base.py", line 151, in run
self.install_packages()
File "/root/modoboa-installer/modoboa_installer/scripts/postfix.py", line 41, in install_packages
config.set("centosplus", "enabled", "1")
File "/usr/lib64/python3.6/configparser.py", line 1193, in set
super().set(section, option, value)
File "/usr/lib64/python3.6/configparser.py", line 901, in set
raise NoSectionError(section) from None
configparser.NoSectionError: No section: 'centosplus'

Originally created by @Super-Gil on GitHub (Apr 1, 2020). Original GitHub issue: https://github.com/modoboa/modoboa/issues/1863 # Impacted versions * Modoboa: Newest * installer used: Yes/No ? Yes * Webserver: Nginx/Apache Nginx # Steps to reproduce 1. reset my centos server to version centos 7.7 2. yum update 3. yum install python36 4. git clone https://github.com/modoboa/modoboa-installer 5. cd modoboa-installer 6. sudo ./run.py [mydomain] # Current behavior Raising error when installing postfix # Expected behavior Should complete the installation. # Error message: [root@iZj6c78t3hp8rnwcpnk0mnZ modoboa-installer]# sudo python3 ./run.py anckak.tech Welcome to Modoboa installer! Warning: Before you start the installation, please make sure the following DNS records exist for domain 'anckak.tech': mail IN A <IP ADDRESS OF YOUR SERVER> IN MX mail.anckak.tech. Your mail server will be installed with the following components: modoboa automx amavis clamav dovecot nginx razor postfix postwhite spamassassin uwsgi radicale opendkim Do you confirm? (Y/n) y The process can be long, feel free to take a coffee and come back later ;) Starting... Overwrite the existing SSL certificate? (y/N) y Generating new self-signed certificate Installing amavis Installing spamassassin Installing razor Installing clamav Installing modoboa User modoboa already exists, skipping creation but please make sure the /srv/modoboa directory exists. Target directory for Modoboa deployment (/srv/modoboa/instance) already exists. If you choose to continue, it will be removed. Do you confirm? (Y/n) y Installing automx User automx already exists, skipping creation but please make sure the /srv/automx directory exists. Installing radicale User radicale already exists, skipping creation but please make sure the /srv/radicale directory exists. Installing uwsgi Installing nginx Installing opendkim Installing postfix Traceback (most recent call last): File "./run.py", line 136, in <module> main(sys.argv[1:]) File "./run.py", line 126, in main scripts.install("postfix", config, args.upgrade) File "/root/modoboa-installer/modoboa_installer/scripts/__init__.py", line 22, in install getattr(script, appname.capitalize())(config, upgrade).run() File "/root/modoboa-installer/modoboa_installer/scripts/base.py", line 151, in run self.install_packages() File "/root/modoboa-installer/modoboa_installer/scripts/postfix.py", line 41, in install_packages config.set("centosplus", "enabled", "1") File "/usr/lib64/python3.6/configparser.py", line 1193, in set super().set(section, option, value) File "/usr/lib64/python3.6/configparser.py", line 901, in set raise NoSectionError(section) from None configparser.NoSectionError: No section: 'centosplus'
kerem closed this issue 2026-02-27 11:17:14 +03:00
Author
Owner

@tonioo commented on GitHub (Apr 2, 2020):

@Super-Gil Can you check the content of the /etc/yum.repos.d/CentOS-Base.repo please.

<!-- gh-comment-id:607722655 --> @tonioo commented on GitHub (Apr 2, 2020): @Super-Gil Can you check the content of the `/etc/yum.repos.d/CentOS-Base.repo` please.
Author
Owner

@Super-Gil commented on GitHub (Apr 2, 2020):

Thanks for your reply!
Here is the result of "nano /etc/yum.repos.d/CentOS-Base.repo"
[base]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7

[updates]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7

[extras]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/extras/$basearch/
gpgcheck=1
gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7

<!-- gh-comment-id:607746409 --> @Super-Gil commented on GitHub (Apr 2, 2020): Thanks for your reply! Here is the result of "nano /etc/yum.repos.d/CentOS-Base.repo" [base] name=CentOS-$releasever enabled=1 failovermethod=priority baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/os/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7 [updates] name=CentOS-$releasever enabled=1 failovermethod=priority baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/updates/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7 [extras] name=CentOS-$releasever enabled=1 failovermethod=priority baseurl=http://mirrors.cloud.aliyuncs.com/centos/$releasever/extras/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7
Author
Owner

@tonioo commented on GitHub (Apr 2, 2020):

Strange. You should have a [centosplus] section has mentionned here: https://wiki.centos.org/AdditionalResources/Repositories/CentOSPlus.
Can you try to add it?

<!-- gh-comment-id:607838075 --> @tonioo commented on GitHub (Apr 2, 2020): Strange. You should have a `[centosplus]` section has mentionned here: https://wiki.centos.org/AdditionalResources/Repositories/CentOSPlus. Can you try to add it?
Author
Owner

@tonioo commented on GitHub (Sep 11, 2020):

@Super-Gil Any news?

<!-- gh-comment-id:691173681 --> @tonioo commented on GitHub (Sep 11, 2020): @Super-Gil Any news?
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/modoboa-modoboa#1460
No description provided.