mailx works for root only, other users can't.

When i'm logged in as root, mail works perfectly, but with any other user it doesn't. Here is output of the command: mailx -v -s test < /dev/null  
bash-2.03$ /etc/mail/ line 0: cannot open: Permission denied  
I'm running sendmail 8.12.11 ... I've tried so many things. its driving me insane.

Who is Participating?
OtetelisanuConnect With a Mentor Commented:
[root@pluto2:/] ll /etc/mail/
-r--r--r--   1 bin      bin        28407 Mar  1  2000 /etc/mail/

look the permission for  /etc/mail/

it is a permission promblem

kalmenAuthor Commented:
Thanks alot for that. I stopped getting the error message. And when I run the command:
mailx -v -s test < /dev/null
it waits for a while, and then it sends the message, but at least i get it.
But when I use:

bash-2.03$ mailx
Subject: Helo. This is a test
Testing 123

it just hangs... nothing happens and no mail is sent, i just have to kill it.
Do you have any suggestions?
kalmenAuthor Commented:
I gave up on sendmail. I'm using mailrelay through another host. Now Root works fine, but any other user will give me:
Can't create transcript file ./xfi3D7mPa03041: Permission denied
Cannot create ./dfi3D7mPa03041: Permission denied
queueup: cannot create queue temp file ./tfi3D7mPa03041, uid=100: Permission denied

Any advise? I know its a permissions problem, but i just can't find it.
kalmenAuthor Commented:
I'm so sorry for the hiccup. I realized that the sendmail program lost its suid flag, so chmod u+s /path/to/sendmail has fixed this problem.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.