Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Samba : shared printer tra linux e Windows
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian)
View previous topic :: View next topic  
Author Message
landolini
n00b
n00b


Joined: 08 Mar 2008
Posts: 10

PostPosted: Tue Mar 11, 2008 5:55 pm    Post subject: Samba : shared printer tra linux e Windows Reply with quote

Sto seguendo questa guida http://www.gentoo.org/doc/it/quick-samba-howto.xml?
(Cups e Samba erano gia' installati percio' aggiorno solo la configurazione ...) .
Intanto ,qualcuno e' riuscito a stampare da Windows su una stampante sotto Samba-Cups ?
Eseguendo il comando cupsaddsmb (dopo le configurazioni suggerite dalla guida ) mi trovo sul log di Cups "Unable to find IP address for server name "PrintServer" "
Inoltre la descrizione che da' la guida del comando e' diversa da quella che si ottiene con "man cupsaddsmb" .

Guida >>> # cupsaddsmb -H PrintServer -U root -h PrintServer -v NOME_STAMPANTE
(Al posto di NOME_STAMPANTE si può inserire il parametro "-a", che esporterà tutte le stampanti conosciute)
# cupsaddsmb -H PrintServer -U root -h PrintServer -a


da man >>>
SYNOPSIS
cupsaddsmb [ -H samba-server ] [ -U samba-user[%samba-password] ] [ -h
cups-server[:port] ] [ -v ] -a
cupsaddsmb [ -H samba-server ] [ -U samba-user[%samba-password] ] [ -h
cups-server[:port] ] [ -v ] printer [ ... printer ]
Back to top
View user's profile Send private message
djinnZ
Advocate
Advocate


Joined: 02 Nov 2006
Posts: 4831
Location: somewhere in L.O.S.

PostPosted: Tue Mar 11, 2008 6:40 pm    Post subject: Reply with quote

ehm... il primo printserver lo devi sostituire con il nome del computer mentre il secondo sempre con il nome del computer o localhost mi sa.
_________________
scita et risus abundant in ore stultorum sed etiam semper severi insani sunt:wink:
mala tempora currunt...mater stultorum semper pregna est :evil:
Murpy'sLaw:If anything can go wrong, it will - O'Toole's Corollary:Murphy was an optimist :wink:
Back to top
View user's profile Send private message
landolini
n00b
n00b


Joined: 08 Mar 2008
Posts: 10

PostPosted: Tue Mar 11, 2008 11:03 pm    Post subject: Reply with quote

djinnZ wrote:
ehm... il primo printserver lo devi sostituire con il nome del computer mentre il secondo sempre con il nome del computer o localhost mi sa.



Anche con >>>
lando@Lando-917e83357:~$ sudo cupsaddsmb -H Lando-917e83357 -U lando -h localhost:631 -a
[sudo] password for lando:
Password per lando necessaria per accedere a Lando-917e83357 via SAMBA:

Nel registro errori del server Cups ottengo >>>>>

[11/Mar/2008:22:45:09 +0000] Unable to find IP address for server name "PrintServer"!
E [11/Mar/2008:22:45:09 +0000] Unable to open listen socket for address :::631 - Address family not supported by protocol.
E [11/Mar/2008:22:54:59 +0000] Unable to find IP address for server name "PrintServer"!
E [11/Mar/2008:22:54:59 +0000] Unable to open listen socket for address :::631 - Address family not supported by protocol.
Back to top
View user's profile Send private message
koma
Advocate
Advocate


Joined: 06 Jun 2003
Posts: 2702
Location: Italy

PostPosted: Wed Mar 12, 2008 9:45 am    Post subject: Reply with quote

Ma l'interfaccia web non ti può aiutare? ( http://127.0.0.1:631 )
_________________
http://www.youtube.com/watch?v=_yoJI-Tl94g GLORY GLORY HYPNOTOAD
Back to top
View user's profile Send private message
djinnZ
Advocate
Advocate


Joined: 02 Nov 2006
Posts: 4831
Location: somewhere in L.O.S.

PostPosted: Wed Mar 12, 2008 11:34 am    Post subject: Reply with quote

landolini wrote:
cupsaddsmb -H Lando-917e83357 -U lando -h localhost:631 -a
Lando-917e83357 ... è il nome dell'host linux vero?
per cortesia posta smb.conf opportunamente depurato dei commenti etc. ed elimina le stampanti precedentemente create, koma ti ha suggerito il link.
_________________
scita et risus abundant in ore stultorum sed etiam semper severi insani sunt:wink:
mala tempora currunt...mater stultorum semper pregna est :evil:
Murpy'sLaw:If anything can go wrong, it will - O'Toole's Corollary:Murphy was an optimist :wink:
Back to top
View user's profile Send private message
landolini
n00b
n00b


Joined: 08 Mar 2008
Posts: 10

PostPosted: Wed Mar 12, 2008 5:35 pm    Post subject: Reply with quote

djinnZ wrote:
landolini wrote:
cupsaddsmb -H Lando-917e83357 -U lando -h localhost:631 -a
Lando-917e83357 ... è il nome dell'host linux vero?
per cortesia posta smb.conf opportunamente depurato dei commenti etc. ed elimina le stampanti precedentemente create, koma ti ha suggerito il link.


Lando-917e83357 e' il nome dell ' host linux.
Smb.conf e' la copia di quello in >>>
http://www.gentoo.org/doc/it/quick-samba-howto.xml?

Ho messo solo il nome della mia stampante S300 al posto di [NOME_STAMPANTE]...
Ecco il testparm >>>
lando@Lando-917e83357:~$ testparm
Load smb config files from /etc/samba/smb.conf
Processing section "[print$]"
Processing section "[S300]"
Processing section "[printers]"
Processing section "[public]"
Processing section "[AMULE]"
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions

[global]
server string =
interfaces = lo, eth0
bind interfaces only = Yes
null passwords = Yes
passdb backend = tdbsam
username map = /etc/samba/smbusers
syslog only = Yes
announce version = 5.0
name resolve order = bcast hosts wins
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE SO_RCVBUF=8192 SO_SNDBUF=8192
printcap name = CUPS
guest ok = Yes
hosts allow = all
printing = cups
print command =
lpq command = %p
lprm command =

[print$]
comment = Printer Drivers
path = /etc/samba/printer # questo path mantiene la struttura dei driver

[S300]
comment = DESCRIZIONE DELLA STAMPANTE
path = /var/spool/samba
printable = Yes

[printers]
comment = All Printers
path = /var/spool/samba
printable = Yes
browseable = No

[public]
comment = Public Files
path = /home/samba/public
create mask = 0766

[AMULE]
path = /home/lando/AMULE
read only = No


Comunque Riesco a stampare con S300 usando smbclient con >>>
lando@Lando-917e83357:~$ smbclient //192.168.1.300/S300
Password:
Domain=[LANDO-917E83357] OS=[Unix] Server=[Samba 3.0.26a]
smb: \> print /home/lando/......

Non ci riesco da Windows...non mi riconosce la stampante S300 , invece legge i files condivisi (AMULE) ...

PS- Empiricamente ho trovato che Samba ha indirizzo 192.168.1.xxx (con xxx che va da 260 fino a 999...) e usando questo indirizzo supero i problemi di IP invalidi che avevo usando i nomi..... non ne so molto di rete....li ho trovati a forza di provare !
Back to top
View user's profile Send private message
djinnZ
Advocate
Advocate


Joined: 02 Nov 2006
Posts: 4831
Location: somewhere in L.O.S.

PostPosted: Wed Mar 12, 2008 6:39 pm    Post subject: Reply with quote

landolini wrote:
Lando-917e83357 e' il nome dell'host linux.
prima cosa: ma come ti è venuto di assegnare nomi del genere?
A parte il fatto che porta sfiga non battezzare i computer se proprio non vuoi avere fantasia almeno definiscili secondo la loro collocazione... che so: cucina, gabinetto, camera da letto... :lol:
Code:
        server string =
        announce version = 5.0
        printcap name = CUPS
        name resolve order = bcast hosts wins
questi già non mi convincono. Per una complicata questione legata all'inefficienza di windozz valorizza server string e senza il %v, anche solo ripetendo il nome dell'host e valorizza workgroup. Il resolve order è al contrario se usi il dhcp (ma questo influenza le prestazioni più che altro)

consiglio: in futuro usa il tag [code] rendi più leggibile il post

Secondo problema: sei in dhcp? L'ip di samba, a meno che non gli dici diversamente è lo stesso del pc linux

Se la stampante è accessibile da cups come http://dite:631/printers/S300 vedi che riportarla identica fa incasinare samba, prova a commentare la sezione S300, serve per caricare delle stampanti specifiche.

a questo punto da windows all'indirizzo \\Lando-917e83357 dovresti vedere gli share e la stampante.
NB: Tra una modifica e l'altra ricordati di lanciare /etc/init.d/samba restart per ricaricare le modifiche.

Quote:
con xxx che va da 260 fino a 999
8O questo è impossibile. Gli indirizzi vanno da 0 a 254. Se qualcuno me la sa spiegare...
_________________
scita et risus abundant in ore stultorum sed etiam semper severi insani sunt:wink:
mala tempora currunt...mater stultorum semper pregna est :evil:
Murpy'sLaw:If anything can go wrong, it will - O'Toole's Corollary:Murphy was an optimist :wink:
Back to top
View user's profile Send private message
landolini
n00b
n00b


Joined: 08 Mar 2008
Posts: 10

PostPosted: Thu Mar 13, 2008 9:45 am    Post subject: Reply with quote

Quote:

Se la stampante è accessibile da cups come http://dite:631/printers/S300 vedi che riportarla identica fa incasinare samba, prova a commentare la sezione S300, serve per caricare delle stampanti specifiche.

:?: se la tolgo da smb.conf non stampa piu'...attraverso samba !



Quote:

Citazione:
con xxx che va da 260 fino a 999
8O questo è impossibile. Gli indirizzi vanno da 0 a 254. Se qualcuno me la sa spiegare..


...e voila' >>>>>

lando@Lando-917e83357:~$ smbclient //192.168.1.999/AMULE
Password:
Domain=[LANDO-917E83357] OS=[Unix] Server=[Samba 3.0.26a]
smb: \>
Back to top
View user's profile Send private message
MeMyselfAndI
l33t
l33t


Joined: 15 Nov 2005
Posts: 784
Location: Between the monitor and the chair

PostPosted: Thu Mar 13, 2008 12:47 pm    Post subject: Reply with quote

Si vede che ci sara' un altro metodo di riconoscimento dei servizi samba oltre alla ricerca per IP. 999 E' IMPOSSIBILE assegnare quell'ip perche' NON esiste :D
Back to top
View user's profile Send private message
landolini
n00b
n00b


Joined: 08 Mar 2008
Posts: 10

PostPosted: Thu Mar 13, 2008 4:46 pm    Post subject: Reply with quote

MeMyselfAndI wrote:
Si vede che ci sara' un altro metodo di riconoscimento dei servizi samba oltre alla ricerca per IP. 999 E' IMPOSSIBILE assegnare quell'ip perche' NON esiste :D


Non direi proprio .......

lando@Lando-917e83357:~$ smbclient //192.168.1.255/AMULE
timeout connecting to 192.168.1.255:445
timeout connecting to 192.168.1.255:139
Error connecting to 192.168.1.255 (Operazione già in corso)
Connection to 192.168.1.255 failed (Error NT_STATUS_ACCESS_DENIED)

lando@Lando-917e83357:~$ smbclient //192.168.1.256/AMULE
Password:
Domain=[LANDO-917E83357] OS=[Unix] Server=[Samba 3.0.26a]
smb: \>
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum