1

Topic: Error message: head: cannot open '/etc/mailname' ....

==== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.2
- Linux/BSD distribution name and version: Ubuntu 14.04 LTS
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx): Apache
- Manage mail accounts with iRedAdmin-Pro? No
- Related log if you're reporting an issue:
====

Hallo,

I'm receiving the following error messages via mail:

/etc/cron.daily/spamassassin:
head: cannot open '/etc/mailname' for reading: No such file or directory

Do I have to do something?

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Error message: head: cannot open '/etc/mailname' ....

According to Ubuntu document, /etc/mailname should contain the fqdn name.
http://manpages.ubuntu.com/manpages/gut … ame.5.html

3

Re: Error message: head: cannot open '/etc/mailname' ....

Changed

chomp($mydomain = `head -n 1 /etc/mailname`);

to:

$mydomain = "example.com";

in /etc/amavis/conf.d/05-domain_id following a comment on this entry:

https://serverfault.com/questions/50442 … tus-header

Now the error message seems to be gone.

4

Re: Error message: head: cannot open '/etc/mailname' ....

It's better to append this setting in /etc/amavis/conf.d/50-user instead of modifying 05-domain_id.

5

Re: Error message: head: cannot open '/etc/mailname' ....

Do I have to replace the

chomp($mydomain = "ec.heinrichheinedo.de");

with

$mydomain = "example.com";

?

6

Re: Error message: head: cannot open '/etc/mailname' ....

It's ok to replace it.