Apt install postfix fails with bad demiliter
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
postfix (Ubuntu) |
Incomplete
|
Undecided
|
Unassigned |
Bug Description
# Trying to install postfix keeps on adding a delimiter (two dots at end of hostname) making newaliases and then the postfix installation fail
# i have tried fixing it a lot of times by changing hostname and info in the hosts file
# And also changing the myhostname in /etc/postfix/
# But it just changes myhostname to rpi4-ubuntudesk
# It just continuously fail's to install
# I believe i need help to fix this or quite possible a bug
# here are my steps and info
sudo apt install postfix
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
postfix is already the newest version (3.5.6-1).
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up postfix (3.5.6-1) ...
# ->
# Here is the info in the interactive part
choose internet
choose mail name -> rpi4-ubuntudesktop
# -<
sudo apt install postfix
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Suggested packages:
procmail postfix-mysql postfix-pgsql postfix-ldap postfix-pcre postfix-lmdb postfix-sqlite sasl2-bin
| dovecot-common postfix-cdb postfix-doc
The following packages will be REMOVED:
lsb-invalid-mta
The following NEW packages will be installed:
postfix
0 upgraded, 1 newly installed, 1 to remove and 1 not upgraded.
Need to get 0 B/1,200 kB of archives.
After this operation, 4,233 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Preconfiguring packages ...
dpkg: lsb-invalid-mta: dependency problems, but removing anyway as you requested:
lsb-core depends on lsb-invalid-mta (>= 11.1.0ubuntu2) | mail-transport-
Package lsb-invalid-mta is to be removed.
Package mail-transport-
Package lsb-invalid-mta which provides mail-transport-
lsb-core depends on lsb-invalid-mta (>= 11.1.0ubuntu2) | mail-transport-
Package lsb-invalid-mta is to be removed.
Package mail-transport-
Package lsb-invalid-mta which provides mail-transport-
(Reading database ... 162385 files and directories currently installed.)
Removing lsb-invalid-mta (11.1.0ubuntu2) ...
Selecting previously unselected package postfix.
(Reading database ... 162379 files and directories currently installed.)
Preparing to unpack .../postfix_
Unpacking postfix (3.5.6-1) ...
Setting up postfix (3.5.6-1) ...
Adding group `postfix' (GID 135) ...
Done.
Adding system user `postfix' (UID 128) ...
Adding new user `postfix' (UID 128) with group `postfix' ...
Not creating home directory `/var/spool/
Creating /etc/postfix/
Adding group `postdrop' (GID 136) ...
Done.
setting myhostname: rpi4-ubuntudesk
setting alias maps
setting alias database
mailname is not a fully qualified domain name. Not changing /etc/mailname.
setting destinations: $myhostname, rpi4-ubuntudesktop, localhost.
setting relayhost:
setting mynetworks: 127.0.0.0/8 [::ffff:
setting mailbox_size_limit: 0
setting recipient_
setting inet_interfaces: all
setting inet_protocols: all
Postfix (main.cf) is now set up with a default configuration. If you need to
make changes, edit /etc/postfix/
Postfix configuration values, see postconf(1).
After modifying main.cf, be sure to run 'systemctl reload postfix'.
Running newaliases
newaliases: warning: valid_hostname: misplaced delimiter: rpi4-ubuntudesk
newaliases: fatal: file /etc/postfix/
dpkg: error processing package postfix (--configure):
installed postfix package post-installation script subprocess returned error exit status 75
Processing triggers for ufw (0.36-7.1) ...
Rules updated for profile 'Samba'
Skipped reloading firewall
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for rsyslog (8.2102.0-2ubuntu1) ...
Processing triggers for libc-bin (2.33-0ubuntu5) ...
Errors were encountered while processing:
postfix
E: Sub-process /usr/bin/dpkg returned an error code (1)
----
nano /etc/hostname
rpi4ubuntudesktop
----
nano /etc/hosts
127.0.0.1 localhost
127.0.1.1 rpi4-ubuntudesktop
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
i of couse made a typo
The steps in taking is valid from
# ->
# Here is the info in the interactive part
choose internet
choose mail name -> rpi4-ubuntudesktop
# -<
----
And
nano /etc/hostname
# Is really
rpi4-ubuntudesktop