TNG / inet_aton

Luke Kenneth Casson Leighton lkcl at samba.org
Thu Jan 13 23:02:22 GMT 2000


can someone evaluate this, i have no idea if it's correct [the fork()
bit].

also, iain, give me more info.  what is the workstation name.  which is
the samba server.  which log file has the trust account error message?

etc.

On Thu, 13 Jan 2000, Iain MacDonnell wrote:

> 
> Cool - roaming profiles now work, and the code compiles without need for
> inet_aton! THANKS!
> 
> Now, printing.. yup, it's not quite right. I can print, but only to a
> printer that's already been added on the NT desktop. If I browse my server,
> I don't see the services for my printers, where I did with the 12/12/1999
> main-branch smbd. I suspect it may be something to do with this:
> 
> trust_password_lock: cannot open file /opt/samba-tng/private/DSEVEN.ORG.REDDWARF.mac - Error was No such file or directory.
> trust_get_passwd: unable to open the trust account password file for trust REDDW
> 
> (reddwarf is the server, dseven.org is the domain) - I've seen some mention
> of .mac files on the list recently, but haven't had time to look in detail.
> 
> One thing I did change in the code, which I *think* fixed a problem with
> printing ... I noticed errors to the effect of "Running command
> 'lpstat -o<queue>' returned -1". I traced this to the following bit of
> lib/smbrun.c :
> 
>         if ((pid=fork())) {
>                 int status=0;
>                 /* the parent just waits for the child to exit */
>                 if (sys_waitpid(pid,&status,0) != pid) {
>                         DEBUG(2,("waitpid(%d) : %s\n",pid,strerror(errno)));
>                         return -1;
>                 }
>                 return status;
>         }
> 
> Bearing in mind that I know nothing about fork()ing, I had a look at this,
> and waitpid(2), and decided that it was waiting on the wrong process - it
> should be waiting on *children* of the main process to exit, not children
> of the *child*. I changed it to:
> 
>                 if (sys_waitpid(getpid(),&status,0) != pid) {
> 
> and the error went away! And I could print! As I say, I'm not familiar with
> this sort of code, so I could be completely wrong, and just fluked getting
> the print jobs though :)
> 
> Anyway, I hope this helps ... the server is Solaris 7, and I'm using SYSV
> printing with "printcap name = lpstat".
> 
> :)
> 
>     ~Iain
> 
> 
> 
> 
> 
> Luke Kenneth Casson Leighton writes:
> : On Thu, 13 Jan 2000, Iain MacDonnell wrote:
> : 
> : > 
> : > Hi Luke,
> : > 
> : > Thanks for the updates - I'll test tonight!
> : > 
> : > The main thing I like about TNG is that, aside from the inevitable developm
> + ent
> : > bugs, it just works... this is the first time that I've been able to do all
> : > the things that I want at the same time - domain logons, domain groups,
> : > printing, etc - previously, I've only seemed to be able to do a subset with
> : > any particular release before.
> : 
> : WILD!
> : 
> : ... you got printing to work?  please tell us how, i have someone who
> : couldn't.
> :  
> : > As for the daemon architecture, it seems to make a lot of sense. Aside from
> : > being able to take individual services in and out of operation without
> : > killing the whole server, not bundling all of those services into one
> : > big daemon feels like a good move. Persumably it ought to run more effecien
> + tly
> : > on larger (MP) servers, too ?
> : 
> : i should hope so.
> 

<a href="mailto:lkcl at samba.org"   > Luke Kenneth Casson Leighton    </a>
<a href="http://www.cb1.com/~lkcl"> Samba and Network Development   </a>
<a href="http://samba.org"        > Samba Web site                  </a>
<a href="http://www.iss.net"      > Internet Security Systems, Inc. </a>
<a href="http://mcp.com"          > Macmillan Technical Publishing  </a>

 ISBN1578701503 DCE/RPC over SMB: Samba and Windows NT Domain Internals



More information about the samba-ntdom mailing list