You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Matt Kettler <mk...@verizon.net> on 2009/04/08 06:50:55 UTC
Re: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, line 2.
alexus wrote:
> I keep getting this line in my logs everytime there is a spamd calles
>
> Apr 8 03:55:15 mx1 spamd[36109]: Use of uninitialized value $dir in
> scalar chomp at /usr/local/bin/spamd line 2118, <GEN103> line 2.
>
> i dont suppose this is normal
>
Are you using the -v parameter when you start spamd, but are passing a
username that's not a vpopmail user with working vuserinfo?
Code:
---------------------
if ( $opt{'vpopmail'} ) {
my $vpopdir = $dir;
$dir = `$vpopdir/bin/vuserinfo -d \Q$username\E`;
if ($? != 0) {
#
# If vuserinfo failed $username could be an alias
#
$dir = `$vpopdir/bin/valias \Q$username\E`;
if ($? == 0 && $dir !~ /.+ -> &/) {
$dir =~ s,.+ -> (/.+)/Maildir/,$1,;
} else {
undef($dir);
}
}
chomp($dir);
}
----------------------
Re: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, line 2.
Posted by Matt Kettler <mk...@verizon.net>.
alexus wrote:
> On Thu, Apr 23, 2009 at 4:08 PM, alexus<al...@gmail.com> wrote:
>
>> On Wed, Apr 8, 2009 at 12:50 AM, Matt Kettler <mk...@verizon.net> wrote:
>>
>>> alexus wrote:
>>>
>>>> I keep getting this line in my logs everytime there is a spamd calles
>>>>
>>>> Apr 8 03:55:15 mx1 spamd[36109]: Use of uninitialized value $dir in
>>>> scalar chomp at /usr/local/bin/spamd line 2118, <GEN103> line 2.
>>>>
>>>> i dont suppose this is normal
>>>>
>>>>
>>> Are you using the -v parameter when you start spamd, but are passing a
>>> username that's not a vpopmail user with working vuserinfo?
>>>
>>>
>>> Code:
>>> ---------------------
>>> if ( $opt{'vpopmail'} ) {
>>> my $vpopdir = $dir;
>>> $dir = `$vpopdir/bin/vuserinfo -d \Q$username\E`;
>>> if ($? != 0) {
>>> #
>>> # If vuserinfo failed $username could be an alias
>>> #
>>> $dir = `$vpopdir/bin/valias \Q$username\E`;
>>> if ($? == 0 && $dir !~ /.+ -> &/) {
>>> $dir =~ s,.+ -> (/.+)/Maildir/,$1,;
>>> } else {
>>> undef($dir);
>>> }
>>> }
>>> chomp($dir);
>>> }
>>> ----------------------
>>>
>>>
>>>
>>>
>>>
>> i even tried with vpopmail user instead of spamd user, I still get this warning
>>
>> --
>> http://alexus.org/
>>
>>
>
> sorry for getting back for older post, but i never got around to fix
> this issue, and I think it should be fixed...
> can someone suggest me how to resolve this issue?
>
> let me recap
>
> every time an email comes in, I get following line in my syslog
>
> spamd[30649]: Use of uninitialized value $dir in scalar chomp at
> /usr/local/bin/spamd line 2118, <GEN990> line 2.
>
> that's how I run spamd
>
> root 1736 0.0 0.5 70044 40568 ?? SsJ 23May09 3:53.05
> /usr/local/bin/spamd --allow-tell --daemonize --vpopmail
> --username=spamd --socketpath=/tmp/spamd.sock --pidfile
> /usr/local/var/run/spamd.pid (perl)
>
>
Ok, so you're running with vpopmail, and spamd is running as the "spamd"
user.
So, what virtual user are you passing to spamc's -u parameter?
What happens when you run vuserinfo and pass the above username to it?
Re: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, line 2.
Posted by alexus <al...@gmail.com>.
On Thu, Apr 23, 2009 at 4:08 PM, alexus<al...@gmail.com> wrote:
> On Wed, Apr 8, 2009 at 12:50 AM, Matt Kettler <mk...@verizon.net> wrote:
>> alexus wrote:
>>> I keep getting this line in my logs everytime there is a spamd calles
>>>
>>> Apr 8 03:55:15 mx1 spamd[36109]: Use of uninitialized value $dir in
>>> scalar chomp at /usr/local/bin/spamd line 2118, <GEN103> line 2.
>>>
>>> i dont suppose this is normal
>>>
>> Are you using the -v parameter when you start spamd, but are passing a
>> username that's not a vpopmail user with working vuserinfo?
>>
>>
>> Code:
>> ---------------------
>> if ( $opt{'vpopmail'} ) {
>> my $vpopdir = $dir;
>> $dir = `$vpopdir/bin/vuserinfo -d \Q$username\E`;
>> if ($? != 0) {
>> #
>> # If vuserinfo failed $username could be an alias
>> #
>> $dir = `$vpopdir/bin/valias \Q$username\E`;
>> if ($? == 0 && $dir !~ /.+ -> &/) {
>> $dir =~ s,.+ -> (/.+)/Maildir/,$1,;
>> } else {
>> undef($dir);
>> }
>> }
>> chomp($dir);
>> }
>> ----------------------
>>
>>
>>
>>
>
> i even tried with vpopmail user instead of spamd user, I still get this warning
>
> --
> http://alexus.org/
>
sorry for getting back for older post, but i never got around to fix
this issue, and I think it should be fixed...
can someone suggest me how to resolve this issue?
let me recap
every time an email comes in, I get following line in my syslog
spamd[30649]: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, <GEN990> line 2.
that's how I run spamd
root 1736 0.0 0.5 70044 40568 ?? SsJ 23May09 3:53.05
/usr/local/bin/spamd --allow-tell --daemonize --vpopmail
--username=spamd --socketpath=/tmp/spamd.sock --pidfile
/usr/local/var/run/spamd.pid (perl)
--
http://alexus.org/
Re: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, line 2.
Posted by alexus <al...@gmail.com>.
On Wed, Apr 8, 2009 at 12:50 AM, Matt Kettler <mk...@verizon.net> wrote:
> alexus wrote:
>> I keep getting this line in my logs everytime there is a spamd calles
>>
>> Apr 8 03:55:15 mx1 spamd[36109]: Use of uninitialized value $dir in
>> scalar chomp at /usr/local/bin/spamd line 2118, <GEN103> line 2.
>>
>> i dont suppose this is normal
>>
> Are you using the -v parameter when you start spamd, but are passing a
> username that's not a vpopmail user with working vuserinfo?
>
>
> Code:
> ---------------------
> if ( $opt{'vpopmail'} ) {
> my $vpopdir = $dir;
> $dir = `$vpopdir/bin/vuserinfo -d \Q$username\E`;
> if ($? != 0) {
> #
> # If vuserinfo failed $username could be an alias
> #
> $dir = `$vpopdir/bin/valias \Q$username\E`;
> if ($? == 0 && $dir !~ /.+ -> &/) {
> $dir =~ s,.+ -> (/.+)/Maildir/,$1,;
> } else {
> undef($dir);
> }
> }
> chomp($dir);
> }
> ----------------------
>
>
>
>
i even tried with vpopmail user instead of spamd user, I still get this warning
--
http://alexus.org/
Re: Use of uninitialized value $dir in scalar chomp at
/usr/local/bin/spamd line 2118, line 2.
Posted by alexus <al...@gmail.com>.
I do run spamd as a spamd user with a flag --vpopmail
$ ~vpopmail/bin/vuserinfo postmaster@XXX.XXX
Error: unable to setuid
$
I even tried with following, still same thing....
$ chmod u+s vuserinfo
$ ls -ld ~vpopmail/bin/vuserinfo
-rws--x--x 1 vpopmail vchkpw 225377 Mar 25 01:15 /home/vpopmail/bin/vuserinfo
$
On Wed, Apr 8, 2009 at 12:50 AM, Matt Kettler <mk...@verizon.net> wrote:
> alexus wrote:
>> I keep getting this line in my logs everytime there is a spamd calles
>>
>> Apr 8 03:55:15 mx1 spamd[36109]: Use of uninitialized value $dir in
>> scalar chomp at /usr/local/bin/spamd line 2118, <GEN103> line 2.
>>
>> i dont suppose this is normal
>>
> Are you using the -v parameter when you start spamd, but are passing a
> username that's not a vpopmail user with working vuserinfo?
>
>
> Code:
> ---------------------
> if ( $opt{'vpopmail'} ) {
> my $vpopdir = $dir;
> $dir = `$vpopdir/bin/vuserinfo -d \Q$username\E`;
> if ($? != 0) {
> #
> # If vuserinfo failed $username could be an alias
> #
> $dir = `$vpopdir/bin/valias \Q$username\E`;
> if ($? == 0 && $dir !~ /.+ -> &/) {
> $dir =~ s,.+ -> (/.+)/Maildir/,$1,;
> } else {
> undef($dir);
> }
> }
> chomp($dir);
> }
> ----------------------
>
>
>
>
--
http://alexus.org/