smbprint (or: print to nt with smbclient)

Angie.Cabrera at LogixCom.com Angie.Cabrera at LogixCom.com
Wed May 9 00:45:31 GMT 2001


I can connect to the drive shares without any trouble.  And I can connect to
the printer share because I get to the smb> prompt.   The syntax I am using
does not pass the file as a file to print but as commands.  Oh course it
does not recognize the commands.

And you are right about the slashes, that's just a habit.  I tried the -W
and that didn't work.  For example my test file has "This is a test file."
as its content.  I type:
cat file | smbclient \\\\server\printer -U user%password

And receive back :

added interface ip=172.31.44.5 bcast=172.31.44.255 nmask=255.255.255.0
Domain=[LOGIX] OS=[Windows NT 4.0] Server=[NT LAN Manager 4.0]
smb: \> This is a test file.
This: command not found
smb: \> 

So it looks like it's connecting.....help.

-----Original Message-----
From: Christian Barth [mailto:barth at cck.uni-kl.de]
Sent: Tuesday, May 08, 2001 12:43 AM
To: samba at lists.samba.org; Cabrera, Angie
Subject: Re: smbprint (or: print to nt with smbclient) 


> I am having the same issue.  I am running Linux Red Hat V7.0 and Samba
> 2.2.0.  I am simply trying to print to a printer on an NT server.  
> 
> I have tried :
> cat file | smbclient \\\\server\printer -U user%password
> But this does not work it gets me to the smb prompt and interprets the
first
> word of my file as an undefined smb command.  
> I have tried: 
> cat file | smbclient \\\\server\printer -Uuser%password -c 'print -' 
> This does the same thing.
> smbclient \\\\server\printer -Uuser%password -c 'print file' 
One (or more) of your combinations should do it. But with
 smbclient \\\\server\\printer ...
(2 \ in fornt of the server, each one escaped form the shell, that 
are 4; 1 \ between server and share, escaped form the shell that are 
2). But with recend versios von smbclient it should work as smbclient 
//server/printer

May try the -W parameter as well.

Can you connet to the printer, or any share on the server with 
smbclient interactivly?

Christian


> Which does not print the file at all.
> And I have tried 
> (echo "print -" ; cat file ) | smbclient .....
> Which does not print the file at all either.
> 
> Samba is working as far as shares are concerned, etc.  I know I can talk
to
> the printer because I am getting blank pages and error handler pages.  I
> just can't seem to figure out the correct syntax.  help!
> 
> 
> 
> 
> 
> 
> 
> -- 
> To unsubscribe from this list go to the following URL and read the
> instructions:  http://lists.samba.org/mailman/listinfo/samba
> 


_______________________________________________________________________
In a world without walls and fences, who needs windows and gates? (SUN)




More information about the samba mailing list