• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

List all domains with "Mail sent to non-existent users"

MislavO

Regular Pleskian
Hello.

In my documents I have command:
# mysql -uadmin -p`cat /etc/psa/.psa.shadow` psa -e "select name from domains" | grep -v 'name' > domains.txt; while read i; do echo $i; /usr/local/psa/bin/domain_pref -i $i | grep nonexistent; done < domains.txt

but it seems like that is no longer working. I've tried to search psa database to find this option "Mail sent to non-existent users", but no success.

What I want to do is list all domains settings for "Mail sent to non-existent users" or even filter them - list only domains that have option set other then Reject.
 
The problem here in incorrect parameter for grep command. It should be 'non-existent' instead of 'nonexistent'. For example:

# /usr/local/psa/bin/domain_pref -i ppu12-5.demo.pp.plesk.ru | grep non-existent
What to do with mail sent to non-existent users: 'reject'
 
Back
Top