[cups.general] adding a samba printer of another network

RSalles rsalles at rsnetservices.com.br
Thu Feb 10 10:53:19 PST 2005


Luca Ferrari wrote:
> On 18:11, giovedì 10 febbraio 2005 Helge Blischke's cat walking on the 
> keyboard  wrote:
> 
> 
>>Luca Ferrari wrote:
>>
>>>On 01:48, giovedì 10 febbraio 2005 Daniel Kasak's cat walking on the
>>>keyboard
>>>
>>>wrote:
>>>
>>>>Luca Ferrari wrote:
>>>>
>>>>>On 23:30, martedì 8 febbraio 2005 Daniel Kasak's cat walking on the
>>>>>keyboard
>>>>>
>>>>>wrote:
>>>>>
>>>>>>Luca Ferrari wrote:
>>>>>>
>>>>>>>Hi,
>>>>>>>if I want to add a printer to cups (SMB printer) in the same network
>>>>>>>of the linux machine, I can use lpadmin:
>>>>>>>lpadmin -v smb://s93/hps93 .......
>>>>>>>
>>>>>>>but what if I want to add a printer of another network? Where can I
>>>>>>>specify the ip address? I've tried with something like:
>>>>>>>lpadmin -v smb://192.168.2.20/hps20
>>>>>>>and the printer is added, but it does not work then.
>>>>>>>
>>>>>>>Any help?
>>>>>>>
>>>>>>>Luca
>>>>>>
>>>>>>That looks right. I use the web admin tool, so I can't comment on the
>>>>>>'lpadmin' bit of it, but the device URI is correct.
>>>>>>
>>>>>>For smb shares, remember you may have to enter a username / password,
>>>>>>which makes your URI:
>>>>>>
>>>>>>smb://username:password@192.168.2.20/hps20
>>>>>>
>>>>>>Also check you can ping 192.168.2.20, and check that you can see the
>>>>>>share, with something like:
>>>>>>
>>>>>>smbclient -U username -L 192.168.2.20
>>>>>>[enter password]
>>>>>>
>>>>>>Also, is this 'other network' a domain? You may have to join the
>>>>>>domain before you're able to connect.
>>>>>>
>>>>>>Also, next time you post, try adding some logs. It makes it easier to
>>>>>>figure out what the problem is.
>>>>>
>>>>>Well, the network is not a domain, and I have guest access to the
>>>>>printer, so I don't need a username/password.
>>>>>Here there's an example of the output of logs:
>>>>>
>>>>>I [09/Feb/2005:09:43:12 +0100] Adding start banner page "none" to job
>>>>>40. I [09/Feb/2005:09:43:12 +0100] Adding end banner page "none" to
>>>>>job 40. I [09/Feb/2005:09:43:12 +0100] Job 40 queued on 'hp711' by
>>>>>'root'.
>>>>>
>>>>>where hp711 has the following configuration in the printers.conf:
>>>>>
>>>>><Printer hp711>
>>>>>Info Centralino Roteglia
>>>>>DeviceURI smb://192.168.2.11/hp711
>>>>>State Idle
>>>>>Accepting Yes
>>>>>JobSheets none none
>>>>>QuotaPeriod 0
>>>>>PageLimit 0
>>>>>KLimit 0
>>>>></Printer>
>>>>>
>>>>>
>>>>>Of course I can ping the machine, as well as I can smbclient it:
>>>>>
>>>>>sede:/var/log/cups # smbclient -L 711 -I 192.168.2.11
>>>>>Password:
>>>>>
>>>>>        Sharename       Type      Comment
>>>>>        ---------       ----      -------
>>>>>        PRINTER$        Disk
>>>>>        HP711           Printer
>>>>>        IPC$            IPC       Comunicazioni remote tra processi
>>>>>
>>>>>        Server               Comment
>>>>>        ---------            -------
>>>>>
>>>>>        Workgroup            Master
>>>>>        ---------            -------
>>>>>
>>>>>
>>>>>Any idea?
>>>>>
>>>>>Thanks,
>>>>>Luca
>>>>
>>>>You're using 2 different IP addresses. Your original post talks of
>>>>192.168.2.20 and your most recent post talks of 192.168.2.11
>>>>
>>>>Is this the problem?
>>>
>>>No, I'm sorry but I deleted the first printer and re-created the 2.11
>>>one. Nevertheless, the idea is that I cannot print from the network
>>>192.168.1.0 on a printer of a computer on the network 192.168.2.0.
>>>
>>>Luca
>>
>>The smbspool backend needs the server's name (in the WIndows/SMB sense)
>>as part of the URI, not the IP addr.
>>
> 
> 
> 
> I've tried with the netbios name (711), but it does not work. I have the host 
> in the /etc/hosts file, but maybe samba cannot get the netbios of the other 
> network. Could it be a samba setting?
> 
> Luca
> 
You'll nedd a wins server support running in your samba server to have 
the subnet browsing facility.
########################################
wins support = yes
name resolve order = wins lmhosts bcast
interfaces = 192.168.2.1 192.168.3.1
; exemple
########################################
It could help you to get rid of this problem.

Best regards,

RSalles




More information about the cups mailing list