SOLVED and CLOSED.

The problem WAS... (and you won't believe this)...

in Debian, /var/qmail/* is basically just symlinks to various places:
sh-2.05# cd /var/qmail/
sh-2.05# ls -al
total 8
drwxr-xr-x    2 root     qmail        4096 Jan 16 00:04 .
drwxr-x--x   17 root     root         4096 Aug  3  2000 ..
lrwxrwxrwx    1 root     root           20 Jan 16 00:04 alias ->
/var/lib/qmail/alias
lrwxrwxrwx    1 root     root            9 Jan 16 00:04 bin -> /usr/sbin
lrwxrwxrwx    1 root     root           34 Jan 16 00:04 boot ->
/usr/share/doc/qmail/examples/boot
lrwxrwxrwx    1 root     root           10 Jan 16 00:04 control ->
/etc/qmail
lrwxrwxrwx    1 root     root           20 Jan 16 00:04 doc ->
/usr/share/doc/qmail
lrwxrwxrwx    1 root     root           16 Jan 16 00:04 queue ->
/var/spool/qmail
lrwxrwxrwx    1 root     root           16 Jan 16 00:04 users ->
/etc/qmail/users

What happened on the Broken box was that /var/qmail/bin was JUST
/var/qmail/bin/, an empty directory, and NOT a symlink to /usr/sbin as it
should be.

Why on EARTH strace would show the error to be with the cdb file, and why
on HECK the error message said it couldn't get into the vpopmail/domain
directory, I will never know.

If the stupid error messages were a tad more intuitive I... and everyone
that has been helping to trace down this error, wouldn't have had to spend
so much wasted time on this.

To Chris Bolt and Raghu V Singh: thanks for helping out guys. Well, what I
can say out of all this is that I learnt quite a bit about strace, and the
finer workings of qmail. I never thought it would be this problem. Sorry
:-(

If you ever come to Hong Kong, let me know :-)

Sincerely,
Jason

----- Original Message -----
From: "Raghu V Singh" <[EMAIL PROTECTED]>
To: "Jason Lim" <[EMAIL PROTECTED]>
Sent: Saturday, May 26, 2001 12:20 AM
Subject: Re: moving domains ???????


>
> Jason ,
>
>    What is inside the assign file in the users directory ? Look at the
> usids/gids ( and paths ) stored in it . Send out the contents to us if
> possible.
>
> Raghu
>
> From:"Jason Lim" <[EMAIL PROTECTED]> on 05/25/2001 11:19 PM ZE8
>
>
> Sent by: "Jason Lim" <[EMAIL PROTECTED]>
>
> Please respond to "Jason Lim" <[EMAIL PROTECTED]>
>
>
>
> To:  <[EMAIL PROTECTED]>
> cc:  "Chris Bolt" <[EMAIL PROTECTED]>(bcc: Raghu V Singh/rsingh1/LSU)
>
> Subject:  Re: moving domains ???????
>
>
>
> Heres an interesting thing for you to see:
>
> sh-2.05# cd users
> sh-2.05# ls -al
> total 24
> drwxr-xr-x    2 root     qmail        4096 May 25 21:08 .
> drwxr-xr-x    3 root     root         4096 May 25 21:08 ..
> -rw-r--r--    1 root     root         5115 May 25 21:08 assign
> -rw-------    1 root     root            0 May 25 21:08 assign.lock
> -rw-r--r--    1 root     root         4937 Feb 27 23:48 cdb
> sh-2.05# pwd
> /etc/qmail/users
> sh-2.05#
>
> Notice how cdb is dated in the FUTURE. Could that why it is having
trouble
> being read, or if you say it is being read, then maybe it is having
> trouble processing it because of the date?
> In case you are curious:
> sh-2.05# date
> Fri May 25 23:05:12 HKT 2001
>
> so the date is right ;-)
>
> Here is also something interesting:
>
> sh-2.05# qmail-newu
> sh-2.05# ls -al
> total 28
> drwxr-xr-x    2 root     qmail        4096 May 25 23:05 .
> drwxr-xr-x    3 root     root         4096 May 25 21:08 ..
> -rw-r--r--    1 root     root         5115 May 25 21:08 assign
> -rw-------    1 root     root            0 May 25 21:08 assign.lock
> -rw-r--r--    1 root     root         8608 May 25 23:05 cdb
>
> Okay... so qmail-newu regenerated cdb and made it have the right date.
> thats good. so next...
>
> sh-2.05# vadddomain test45.com
> Unknown parameter:
>
> Please enter password for postmaster:
> enter password again:
> Error: Unable to chdir to vpopmail/domains directory
> sh-2.05# ls -al
> total 28
> drwxr-xr-x    2 root     qmail        4096 May 25 23:06 .
> drwxr-xr-x    3 root     root         4096 May 25 23:06 ..
> -rw-r--r--    1 root     root         5192 May 25 23:06 assign
> -rw-------    1 root     root            0 May 25 23:06 assign.lock
> -rw-r--r--    1 root     root         8608 May 25 23:05 cdb
> sh-2.05#
> sh-2.05# qmail-newu
> sh-2.05# ls -al
> total 28
> drwxr-xr-x    2 root     qmail        4096 May 25 23:08 .
> drwxr-xr-x    3 root     root         4096 May 25 23:06 ..
> -rw-r--r--    1 root     root         5192 May 25 23:06 assign
> -rw-------    1 root     root            0 May 25 23:06 assign.lock
> -rw-r--r--    1 root     root         8706 May 25 23:08 cdb
>
> How come cdb isn't updated until I manually run qmail-newu? Something
> fishy going on there... assign increases but cdb stays the same till a
> manual update? Shouldn't this happen automagically?
>
> Your suggestions below are noted, and I will try them out very shortly,
> and report back what happened. I really hope it works.
>
> Concerning the /etc/passwd entry:
> sh-2.05# more /etc/passwd | grep vpop
> vpopmail:x:64020:64020:Vpopmail user,,,:/var/lib/vpopmail:/bin/bash
>
> Thats what Debian Linux installs vpopmail as by default. It definately
> works on the other box... and did so until recently on the broken box,
so
> I'm sure this isn't the issue thats causing it to fail now.
>
> Sincerely,
> Jason
>
> ----- Original Message -----
> From: "Chris Bolt" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, May 25, 2001 11:01 PM
> Subject: RE: moving domains ???????
>
>
> > > As you can see, it is looking at /var/qmail/users/cdb, BUT with the
> broken
> > > box, it doesn't seem to find anything, and just looks at
/vpasswd.cdb
> .
> >
> > The broken box can find /var/qmail/users/cdb
> >
> > > Obviously it should be in
> > > /var/lib/vpopmail/domains/test41.com/vpasswd.cdb, which the Working
> box
> > > has found.
> > >
> > > Now my question is... is it possible to REGENERATE the
> > > /var/qmail/users/cdb file? Maybe the problem lies there?
> >
> > /var/qmail/bin/qmail-newu does this
> >
> > > From my understanding, the cdb file contains the information on
where
> > > each domain's files are, and since the Broken box can't find it, it
> > assumes its
> > > in / .
> > >
> > > Is this thinking right? Can the cdb file even BE regenerated?
> >
> > - Remove /var/qmail/users/assign and cdb
> > - Remove all test domains from:
> >   /var/lib/vpopmail/domains
> >   /var/qmail/control/rcpthosts
> >   /var/qmail/control/virtualdomains
> >
> > And try again.
> >
> > Are you absolutely sure that
> >
> > vpopmail:x:64020:64020:Vpopmail user,,,:/var/lib/vpopmail:/bin/bash
> >
> > is EXACTLY the same on both boxes? 64020 sounds like too large of a
uid
> to
> > me.
> >
> >
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

Reply via email to