Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Samba con 2 subnet
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
Ciccio Bueo
l33t
l33t


Joined: 19 Oct 2004
Posts: 834
Location: Treviso

PostPosted: Wed Sep 21, 2005 3:26 pm    Post subject: Samba con 2 subnet Reply with quote

Allora, la situazione:

1 serverino con gentoo e 3 interfacce di rete, una per l'adsl, 1 una per la lan via ethernet, 1 virtuale per la lan bluetooth,

finchè devo usare solo la rete cablata non ci sono problemi, la condivisione delle cartelle e di cups funziona perfettamente, ma se devo aggiungere un'altra interfaccia di rete... no.


ip:

eth0 10.10.0.1 --> va all'hub per la connessione alla rete cablata.
eth1 --> diventa ppp0 per l'adsl
pan0 10.10.1.1 --> è il bridge di rete necessario al bluetooth


configurazione di samba:

Code:
 # cat /etc/samba/smb.conf
[global]

workgroup = SPEEDNETWORK
server string = Gentoo Linux Server
encrypt passwords = True
security = share
smb passwd file = /etc/samba/private/smbpasswd
log file = /var/log/samba/log.%m
socket options = IPTOS_LOWDELAY TCP_NODELAY
domain master = Yes
local master = Yes
preferred master = Yes
os level = 65
dns proxy = No
name resolve order = lmhosts host bcast
bind interfaces only = True
interfaces = lo, eth0, pan0
hosts deny = ALL
hosts allow = 10.10.0.0/24, 10.10.1.0/24, 127.0.0.1 (list of allow hosts here)
debug level = 1
create mask = 0644
directory mask = 0755
level2 oplocks = True
read raw = no
write cache size = 262144

[printers]
comment = All Printer
path = /var/spool/samba
browseable = yes
printable = yes

[public]
comment = Public Files
browseable = yes
writable = yes
public = yes
create mode = 0766
guest ok = yes
path = /home/samba/public



configurazione di cups:

Code:
# cat /etc/cups/cupsd.conf | grep -ve "#"

ServerName homeserver
ServerAdmin root@homeserver
AccessLog /var/log/cups/access_log
DocumentRoot /usr/share/cups/docs
ErrorLog /var/log/cups/error_log
FileDevice Yes
LogLevel error
User lp
Group lp
Port 631
MaxClients 100
Browsing On
BrowseAddress @IF(eth0)
BrowseAddress @IF(pan0)
SystemGroup lp
<Location />
Order Deny,Allow
Deny From All
Allow From 10.10.0.* 10.10.1.*
</Location>
<Location /admin>
AuthType Basic
AuthClass System
Allow From 10.10.0.* 10.10.1.*
Order Deny,Allow
Deny From All
</Location>


ovviamente così non funziona su nesuna delle due reti... :(
Back to top
View user's profile Send private message
Dr.Dran
l33t
l33t


Joined: 08 Oct 2004
Posts: 766
Location: Imola - Italy

PostPosted: Wed Sep 21, 2005 9:05 pm    Post subject: Reply with quote

Ciao! :wink:

Dunque le configurazioni a primo acchito sembrano ottime, hai provato a fare un tail -f /var/log/...... samba o cups?
Cioè tu mentre esegui il tail fai le normali operazioni, fai anche un broadcast con un client smb per vedere cosa dice, se effettivamente arriva qualche cosa alle interfaccie oppure no, in quest amaniera possiamo partire ad analizzare il tutto :D
_________________
:: [Dr.Dran] Details ::
- Linux User # 286282
- IT FreeLance Consultant
- President of ImoLUG [Imola & Faenza Linux User Group]
Back to top
View user's profile Send private message
Ciccio Bueo
l33t
l33t


Joined: 19 Oct 2004
Posts: 834
Location: Treviso

PostPosted: Thu Sep 22, 2005 6:09 am    Post subject: Reply with quote

umm... a parte che ho i log invasi da shorewall.... (non è che posso metterli da un'altra parte? ho visto che da shorewall posso indicare un altro file dove far finire i suoi log?)

ecco, se dal client linux che viaggia sulla eth9 con ip assegnato trami dhcp (10.10.0.250) cerco di collegarmi tramite browser alla pagina 10.10.0.1:631 che è quella del server di stampa:

Code:
Sep 22 07:47:51 homeserver Shorewall:all2all:REJECT:IN=eth0 OUT= MAC=00:10:5a:f4:9e:1a:00:40:63:de:00:00:08:00 SRC=10.10.0.250 DST=10.10.0.1 LEN=60 TOS=0x00 PREC=0x00 TTL=64 ID=13692 DF PROTO=TCP SPT=3040 DPT=631 WINDOW=5840 RES=0x00 SYN URGP=0
Sep 22 07:47:54 homeserver Shorewall:rfc1918:DROP:IN=ppp0 OUT= MAC= SRC=192.168.100.1 DST=224.0.0.1 LEN=28 TOS=0x00 PREC=0xC0 TTL=1 ID=12392 PROTO=2
Sep 22 07:47:55 homeserver Shorewall:net2all:DROP:IN=ppp0 OUT= MAC= SRC=84.59.196.139 DST=87.0.242.58 LEN=44 TOS=0x00 PREC=0x00 TTL=112 ID=14057 PROTO=UDP SPT=18841 DPT=4676 LEN=24



se vado alla pagina normale di cups, ovvero digito http://localhost:631, vedo il normale cups, ma senza stampanti.... seprovo ad aggiungerla inserendo i dati (corretti), indicando che la stampante unsa il protocollo http, all'idirizzo del server etc. etc., non funziona, infatti mi dice la pagina di cups sul client appena configurato: "unable to lockup host homeserver"

se provo samba, dal client linux via eth0 la navigazione delle cartelle funziona.

Dal client windows, via pan0 (che è un bridge fra diverse bnep), non vedo ne lo share di samba, ne cups, mentre invece navigo in internet....

Code:
Sep 22 08:04:16 homeserver pan0: port 1(bnep0) entering learning state
Sep 22 08:04:16 homeserver pan0: topology change detected, propagating
Sep 22 08:04:16 homeserver pan0: port 1(bnep0) entering forwarding state
Sep 22 08:04:18 homeserver net.agent[32301]: add event not handled
Sep 22 08:04:40 homeserver Shorewall:net2all:DROP:IN=ppp0 OUT= MAC= SRC=84.56.226.71 DST=87.0.242.58 LEN=45 TOS=0x00 PREC=0x00 TTL=115 ID=29269 PROTO=UDP SPT=60828 DPT=4676 LEN=25
Sep 22 08:04:47 homeserver Shorewall:all2all:REJECT:IN= OUT=eth0 SRC=10.10.0.1 DST=10.10.0.255 LEN=135 TOS=0x00 PREC=0x00 TTL=64 ID=2916 DF PROTO=UDP SPT=631 DPT=631 LEN=115
Sep 22 08:04:47 homeserver Shorewall:all2all:REJECT:IN=pan0 OUT= MAC= SRC=10.10.1.1 DST=10.255.255.255 LEN=135 TOS=0x00 PREC=0x00 TTL=64 ID=2917 DF PROTO=UDP SPT=631 DPT=631 LEN=115
Sep 22 08:04:47 homeserver Shorewall:all2all:REJECT:IN= OUT=pan0 PHYSOUT=bnep0 SRC=10.10.1.1 DST=10.255.255.255 LEN=135 TOS=0x00 PREC=0x00 TTL=64 ID=2917 DF PROTO=UDP SPT=631 DPT=631 LEN=115
Sep 22 08:04:51 homeserver Shorewall:net2all:DROP:IN=ppp0 OUT= MAC= SRC=82.55.136.234 DST=87.0.242.58 LEN=48 TOS=0x00 PREC=0x00 TTL=121 ID=61391 DF PROTO=TCP SPT=1751 DPT=6346 WINDOW=16384 RES=0x00 SYN URGP=0
Sep 22 08:04:54 homeserver Shorewall:net2all:DROP:IN=ppp0 OUT= MAC= SRC=82.55.13


Grazie :wink:
Back to top
View user's profile Send private message
Dr.Dran
l33t
l33t


Joined: 08 Oct 2004
Posts: 766
Location: Imola - Italy

PostPosted: Thu Sep 22, 2005 5:24 pm    Post subject: Reply with quote

Sembrerebbe che le porte siano castrate da shorewall, hai provato a disabilitarlo e a provare il tutto senza firewall? Ovviamente solo come prova... :wink:
_________________
:: [Dr.Dran] Details ::
- Linux User # 286282
- IT FreeLance Consultant
- President of ImoLUG [Imola & Faenza Linux User Group]
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