Brian Kendig wrote: > On Dec 15, 2005, at 4:11 PM, Vivek Khera wrote: > >> On Dec 15, 2005, at 2:04 PM, Brian Kendig wrote: >> >>> I'm running spamd as "spamd -d -x -u nobody", I've commented out AWL >>> from v310.pre, and I set "bayes_auto_learn 0" so that it shouldn't >>> try to create a Bayes database. I have no idea why it keeps >>> complaining about not being able to create a file in /dev/null. >> >> >> What is user nobody's home dir set to? > > > User "nobody"'s home directory is "/dev/null". Why is spamd 3.1.0 is > trying to create anything there, and how do I prevent it from trying to > do so? >
SpamAssassin tools in general default to creating bayes and AWL directories relative to the current user's homedir. spamd also defaults to creating a default user_prefs there. The best way to prevent it by specifying a non-root user that has a real home dir using the -u parameter to spamd. The other way is to do these things: Stop spamd from creating a user_prefs with the -c option. Disable bayes OR use SQL bayesstore OR set bayes_path to someplace not relative to the homedir. Be careful with bayes_path, as the last part is a partial filename. Basically append "/bayes" to whatever path you want to use. I'd suggest also specifying bayes_file_mode 0777 with bayes_path. Disable the AWL OR use SQL OR set auto_whitelist_path/auto_whitelist_file_mode in a similar fashion to bayes. Also append /auto_whitelist to the path, as this is really a path+filename just like with bayes.