Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Is there a Gentoo sendmail guide somewhere?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
whit
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 121
Location: VT

PostPosted: Tue Oct 29, 2002 5:58 pm    Post subject: Is there a Gentoo sendmail guide somewhere? Reply with quote

Please don't respond if you don't like sendmail. I've been running it for years on RedHat and Debian reliably and without any compromises. If I reference it's docs I can even do a good install from scratch. But I'm trying out the Gentoo way, and I really would like to know why after emerging sendmail and trying to send a test message from mutt while logged in as root I get "Program mode requires special privileges: root or TrustedUser." I _am_ root. I uncomment the TrustedUser definition of root in /etc/mail/sendmail.cf and go to /etc/init.d/sendmail to ask it to stop (and restart), and it complains it can't find its pid file, but stops. But when I go to restart it it says "Warning Sendmail has already been started." Sure - but it's not running and I want to start it. Which makes me wonder whether Gentoo really has a sane installation of sendmail, or whether I really should hand install before I run into other such incompleteness in what I suspect is a package assembled for a distro with an anti-sendmail bias that's provided it broken sort of on purpose. Pardon my paranoia, but if it's not on purpose it's still pretty much broken on install - is this just a few small details, or is it this broken all the way down? If it _is_ just the details, is there a guide to fixing them? Thanks.
Back to top
View user's profile Send private message
BackSeat
Apprentice
Apprentice


Joined: 12 Apr 2002
Posts: 242
Location: Reading, UK

PostPosted: Tue Oct 29, 2002 6:32 pm    Post subject: Re: Is there a Gentoo sendmail guide somewhere? Reply with quote

whit wrote:
Please don't respond if you don't like sendmail.


Well, I think I can at least partially help you, but I don't like sendmail - should I stop now?

whit wrote:
/etc/init.d/sendmail to ask it to stop (and restart), and it complains it can't find its pid file, but stops. But when I go to restart it it says "Warning Sendmail has already been started." Sure - but it's not running and I want to start it.


I've seen this with other services; sometimes runscript can get confused, usually when a service doesn't start properly. If sendmail (or any other service) isn't running but runscript thinks it is, you can persuade it that the service isn't running with:
Code:
/etc/init.d/sendmail zap

In my experience there is normally an error in a config file: perhaps the logfile can help you locate the problem?

whit wrote:
what I suspect is a package assembled for a distro with an anti-sendmail bias that's provided it broken sort of on purpose.

Not only is that paranoia, it's also an unnecessary insult to the Gentoo developers. Yes, you have problems, and I sympathise, but hurling insults at what is proving to be a very popular distro doesn't buy you any favours.

BS
Back to top
View user's profile Send private message
whit
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 121
Location: VT

PostPosted: Tue Oct 29, 2002 8:56 pm    Post subject: Re: Is there a Gentoo sendmail guide somewhere? Reply with quote

BackSeat wrote:
whit wrote:
"]what I suspect is a package assembled for a distro with an anti-sendmail bias that's provided it broken sort of on purpose.

Not only is that paranoia, it's also an unnecessary insult to the Gentoo developers. Yes, you have problems, and I sympathise, but hurling insults at what is proving to be a very popular distro doesn't buy you any favours.

BS


Hey, it's a great distro, and I mean no insult to the developers! And I thank you for your advice, which I'll try as soon as I've learned how to get around some other showstopper bugs in how Gentoo installs sendmail. To have a distro whose sendmail doesn't come close to working out of the box is a bit strange. I guess it's just gotten to where people are so in love with qmail or whatever that it hasn't been gotten around to - even though it's on the short list of major, most-run daemons in the world at large. Sendmail handles complex configurations very, very well. I can drop Debian on a server, edit a few lines in sendmail.cf, and it's in business. Other apps are universally compatible with it. Hopefully sendmail will soon also be a sane option on Gentoo. Meanwhile guess I need to either install sendmail from scratch or learn qmail - which I was hoping to avoid since I'm already running a buncha sendmail servers and am comfortable with it.
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 20506

PostPosted: Tue Oct 29, 2002 9:43 pm    Post subject: Reply with quote

Have you done a search to see if anyone else has reported the same problems?
_________________
Quis separabit? Quo animo?
Back to top
View user's profile Send private message
whit
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 121
Location: VT

PostPosted: Tue Oct 29, 2002 10:33 pm    Post subject: Yup - searched Reply with quote

Yes, spent a while searching on this first, and checked (and filed in) Bugzilla. Didn't see other reports of the same problems. Whether that's because few Gentoo users are doing sendmail or because I haven't mastered efficient use of this forum's search function I don't know. I've got a virgin install of the current Gentoo, though - not anything strange here sendmail should be tripping over. Was just looking at qmail docs, but it takes jumping through hoops to get it to work with procmail and fetchmail - plus I _like_ mbox, I've lost huge chunks of mail to maildir storage problems in the past - so I'll probably just hand install sendmail and do the -i thing to fake Gentoo out about it.
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Oct 29, 2002 11:28 pm    Post subject: Reply with quote

I had the same problem. At first I though it was a permissions problem with the /var/spool/mail etc. .... I eventually got sendmail to work after setting up & using a local bind server thereby giving sendmail server a fully qualified domain name. Do a sendmail -v -bi .... it helped me.

I really think gentoo needs some guides for the common server side software like bind, postfix, sendmail, apache .....
Back to top
View user's profile Send private message
whit
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 121
Location: VT

PostPosted: Wed Oct 30, 2002 12:12 am    Post subject: Bind?? Reply with quote

col wrote:
I eventually got sendmail to work after setting up & using a local bind server thereby giving sendmail server a fully qualified domain name.


Thanks for the tip. That's not a general sendmail requirement, of course. And if Gentoo's sendmail is set to require it, it should have been in the ebuild script. But the box in question doesn't have a public IP - it's NATed and the scheme is to use sendmail/procmail with fetchmail to bring mail in, and sendmail to send it out through the NAT (it's useful to have the local log, and keeps the load down on another sendmail server on the firewall). The box has done this quite happily with RedHat and Debian - it's not that strange a use. And running bind on it would be just a waste of RAM and CPU. So ... off to the manual sendmail install.

I do agree that when complex packages like this are configured in peculiar ways, it's important that the distribution have documents saying just which options have been chosen, especially when the options themselves are paranoid and set to disable the software except in very narrow conditions. Not that there's no place for paranoia by sysadmins - but it should be a local condition, not institutionalized in the distros, imh(paranoid)o.
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 20506

PostPosted: Wed Oct 30, 2002 12:15 am    Post subject: Re: Bind?? Reply with quote

whit wrote:
Thanks for the tip. That's not a general sendmail requirement, of course. And if Gentoo's sendmail is set to require it, it should have been in the ebuild script.
Might be worth mentioning over at bugs.
_________________
Quis separabit? Quo animo?
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Wed Oct 30, 2002 2:19 am    Post subject: Re: Bind?? Reply with quote

whit wrote:
But the box in question doesn't have a public IP

Niether does mine. I tested sendmail with the 127.0.0.1 on my bind server & sendmail works fine with this DNS config :

www IN A 127.0.0.1
mail IN A 127.0.0.1
ftp IN A 127.0.0.1
ns1 IN A 127.0.0.1
linux IN A 127.0.0.1
@ IN MX 5 127.0.0.1.
@ IN MX 10 localdomain.
@ IN NS ns1.localdomain.
@ IN A 127.0.0.1


(the hostname being linux.localdomain)

set your /etc/resolv.conf to 127.0.0.1 & setup named.conf with forwarder addresses & the above zone file.

Dont ask me why but this worked for me.

mail.log:

Oct 30 14:29:24 linux sendmail[6207]: g9U3TOQ2006206: to=<col@localdomain>, ctladdr=<test@localdomain> (1838/1244), delay=00:00:00, xdelay=00:00:00, mailer=local, pri=30759, relay=local, dsn=2.0.0, stat=Sent
Oct 30 14:29:25 linux imapd[6209]: Logout user=test host=localhost [127.0.0.1]

To get a working sendmail server I emerged bind & created the above record. Then I emerged sendmail , xinetd, uw-imap and squirrelmail. It all works perfectly now but would have been lots easier with a small howto.


Last edited by col on Wed Oct 30, 2002 6:56 am; edited 2 times in total
Back to top
View user's profile Send private message
rac
Bodhisattva
Bodhisattva


Joined: 30 May 2002
Posts: 6553
Location: Japanifornia

PostPosted: Wed Oct 30, 2002 3:44 am    Post subject: Reply with quote

Just on a historical note, when I started using Gentoo there was no sendmail ebuild, so it's relatively young.
_________________
For every higher wall, there is a taller ladder
Back to top
View user's profile Send private message
klieber
Bodhisattva
Bodhisattva


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Wed Oct 30, 2002 1:24 pm    Post subject: Reply with quote

col wrote:
I really think gentoo needs some guides for the common server side software like bind, postfix, sendmail, apache .....

I doubt many people would argue that point. The larger question is, "who is going to volunteer their time to write such a guide?"

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
whit
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 121
Location: VT

PostPosted: Wed Oct 30, 2002 4:24 pm    Post subject: Reply with quote

klieber wrote:
col wrote:
I really think gentoo needs some guides for the common server side software like bind, postfix, sendmail, apache .....

I doubt many people would argue that point. The larger question is, "who is going to volunteer their time to write such a guide?"

--kurt


The smaller questions is, where are the notes from the people who put together the packages on which choices they made? Without these, particularly with something like sendmail, it becomes a complex task of reverse engineering to figure out why it's not happy without bind entries for "localhost." I imagine it was built with options (sendmail has more complex options than perhaps anything but Apache) that try to take a shortcut on having user input in order to properly set the domain as it is built - but the shortcut requires an environment with bind on the same system set in a certain way in order to work - so it's a long way around really, and we end up with a broken sendmail. But that's just a guess. It's likely that a few small edits to sendmail.cf after the build can work around this - but that's where it becomes a real reverse engineering puzzle. Besides direct edits to sendmail.cf, while common, are "wrong" according to sendmail creed. If we knew which options the package builder had included to produce the current problems, it would at least be easier to create and document the workarounds.
Back to top
View user's profile Send private message
klieber
Bodhisattva
Bodhisattva


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Wed Oct 30, 2002 4:40 pm    Post subject: Reply with quote

whit wrote:
The smaller questions is, where are the notes from the people who put together the packages on which choices they made?

Did you consider emailing the developer, asking a question on gentoo-dev, catching them on IRC or filing a bug report?

Some of the information you want is in the ChangeLog for each particular app. A great deal of the information you want is not. You're right -- it can be somewhat of an easter egg hunt.

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Wed Oct 30, 2002 10:41 pm    Post subject: Reply with quote

klieber wrote:
col wrote:
I really think gentoo needs some guides for the common server side software like bind, postfix, sendmail, apache .....

I doubt many people would argue that point. The larger question is, "who is going to volunteer their time to write such a guide?"

--kurt

It would be cool if gentoo had community built docs...like a way to submit your notes to a server in a more formal manner than these forums. Then make the docs searchable. Maintainers could also pull the best parts out of the forums & insert them into the docs. We would end up with better docs this way rather than having a single user write them.

There may be a way to use sendmail without bind using the ebuild . I did not bother looking into this because I need bind on my sendmail server.
Back to top
View user's profile Send private message
klieber
Bodhisattva
Bodhisattva


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Thu Oct 31, 2002 12:13 am    Post subject: Reply with quote

col wrote:
It would be cool if gentoo had community built docs...like a way to submit your notes to a server in a more formal manner than these forums. Then make the docs searchable. Maintainers could also pull the best parts out of the forums & insert them into the docs. We would end up with better docs this way rather than having a single user write them.

We started a Gentoo Documentation project that's since stagnated because the project leader *cough*me*cough* ran short on time. If anyone is interested in taking up the cause, feel free to send me a PM.

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
mgraves
n00b
n00b


Joined: 09 Nov 2002
Posts: 1
Location: Iowa, USA

PostPosted: Sat Nov 09, 2002 3:06 pm    Post subject: One possible solution Reply with quote

I had the same problem and since I didn't see any solution I thought I'd share. The /var/spool/clientmqueue directory has the incorrect ownership. It installed for me to root.root but should be smmsp.smmsp (e.g drwxrwx--- 2 smmsp smmsp 4096 Nov 9 09:53 clientmqueue)

Another solution might be to change

O RunAsUser=smmsp
O TrustedUser=smmsp

vars in /etc/mail/submit.cf

Hope this helps.
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Sat Nov 09, 2002 11:28 pm    Post subject: Reply with quote

I also have incorrect permissions on the clientmqueue directory. Sendmail has been working fine with this but I am getting an errors in the mail.log......
Back to top
View user's profile Send private message
Stalione
Guru
Guru


Joined: 21 Apr 2002
Posts: 335

PostPosted: Tue Mar 11, 2003 5:15 pm    Post subject: Reply with quote

mgraves was right...the dir permissions on my /var/spool/clientmqueue was:
Quote:

drwxrwx--- 2 smmsp users 104 Mar 11 11:02 clientmqueue


I changed it to
Quote:

drwxrwx--- 2 smmsp smmsp 104 Mar 11 11:02 clientmqueue


Before making this change I kept getting error messages saying:
Quote:

82445 rooster mail crit tag 2003- 03-11 10:48:53
sendmail[5638]: NOQUEUE: SYSERR(apache): can not chdir(/var/spool/clientmqueue/): Permission denied


Now it works!!! Yey!
Back to top
View user's profile Send private message
MrSpock
n00b
n00b


Joined: 13 Jan 2003
Posts: 43

PostPosted: Fri Feb 13, 2004 2:24 pm    Post subject: Reply with quote

If you encounter a simular problem (like me) check that your sendmail binary has the following permissions

Code:
-r-xr-sr-x    1 root     smmsp      667364 Feb  9 12:43 sendmail


keep an close eye to the 's' in the groups permission. that one was missing for me (normal 0444) so it didn't work. setting the 'set gid on execution' did the trick. use the mc if you don't know octal code 8)
_________________
If we could change our past,
would that also change who we are?
Back to top
View user's profile Send private message
kabutor
l33t
l33t


Joined: 12 Dec 2002
Posts: 821
Location: Benalmadena - Melrose Place

PostPosted: Tue Mar 09, 2004 12:33 am    Post subject: Reply with quote

I love you mrspock THAT did the trick .. :)
Back to top
View user's profile Send private message
MrSpock
n00b
n00b


Joined: 13 Jan 2003
Posts: 43

PostPosted: Tue Mar 09, 2004 9:21 am    Post subject: Reply with quote

always a plessure to help out a 'guru' :lol:
_________________
If we could change our past,
would that also change who we are?
Back to top
View user's profile Send private message
MindBlaster
n00b
n00b


Joined: 10 May 2004
Posts: 2
Location: Sweden

PostPosted: Mon May 10, 2004 9:04 pm    Post subject: Reply with quote

mrspock, you really helped me there!
Thank you!!
_________________
// MindBlaster
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum