Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SAMBA] shares in read-only [RISOLTO]
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
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Mon Jul 19, 2004 8:23 pm    Post subject: [SAMBA] shares in read-only [RISOLTO] Reply with quote

ho creato una macchina nuova di zecca, ci ho messo apache e samba e il minimo indispensabile.

per samba, ho seguito questo howto: http://www.gentoo.org/doc/en/quick-samba-howto.xml
ho saltato la parte cups e antivirus perche' non m'interessavano

sono riuscito a configurare gli shares in modo che vengano visti da windows... oddio... visti... devo fare \\ip.del.pc.samba anziche' \\nome.del.pc.samba ma questo non e' un problema primario
(si, i 2 pc: windows e linux hanno lo stesso workgroup)

il problema e' che gli share sono tutti in sola lettura, mentre io vorrei che fossero anche "scrivibili". ho cercato sul forum vari hints, ho aggiunto la stringa
Quote:
writeable = yes
agli shares, ma non va.
questo e' il mio smb.conf:
Code:
[global]

workgroup = STARS

server string = Samba Server %v

log file = /var/log/samba/log.%m
max log size = 50

socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

interfaces = lo eth0
bind interfaces only = yes

#hosts allow = 127.0.0.1 192.168.1.0/24
#hosts deny = 0.0.0.0/0

# The default is user
security = share

# No passwords, so we're going to use a guest account!
guest account = samba
guest ok = yes
# unix extensions = yes

# We create a new share that we can read/write to from anywhere
# This is kind of like a public temp share, anyone can do what
# they want here.

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


il risultato e' che posso accedere agli share da windows ma se provo a creare un file mi da accesso negato, nei logs non appare nulla di interessante apparte
Code:
[2004/07/19 21:57:59, 1] smbd/service.c:make_connection_snum(619)
  192.168.0.2 (192.168.0.2) connect to service public initially as user samba (uid=1002, gid=100) (pid 610)
[2004/07/19 21:57:59, 0] smbd/service.c:set_current_service(56)
  chdir (/home/samba/public) failed
[2004/07/19 21:57:59, 0] smbd/service.c:set_current_service(56)
  chdir (/home/samba/public) failed
[2004/07/19 21:58:00, 0] smbd/service.c:set_current_service(56)
  chdir (/home/samba/public) failed
...

dove sbaglio?
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler


Last edited by pascalbrax on Mon Jul 19, 2004 8:43 pm; edited 1 time in total
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Mon Jul 19, 2004 8:33 pm    Post subject: Reply with quote

hai controllato i permessi sulla dir sharata?
ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Mon Jul 19, 2004 8:41 pm    Post subject: Reply with quote

come da howto, ho fatto chmod 755 sulle varie dir.
ora per prova ho fatto chmod 777 e funziona anche in scrittura... mah ;)

grazie! :D
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Mon Jul 19, 2004 8:44 pm    Post subject: Reply with quote

il punto e' che accedi come guest (e sembra che ti mappi come user samba).

Togli l'accesso pubblico e configurati il tuo user :)
A quel punto puoi rimettere 755 (o anche + conservativo)

ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Mon Jul 19, 2004 9:23 pm    Post subject: Reply with quote

si ma come guest avevo mappato samba
e la cartella in share e' proprio sotto /home/samba
cosa ce' che non afferro? :)
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
FonderiaDigitale
Veteran
Veteran


Joined: 06 Nov 2003
Posts: 1710
Location: Rome, Italy

PostPosted: Tue Jul 20, 2004 6:48 am    Post subject: Reply with quote

ocio che samba non usa shadow o passwd (ovvero gli account di sistema) per i propri utenti.
devi creare utenti separati per il proprio db (che puo' essere anche mysql, e che con apposite utility puo essere tenuto in sincrono con quello unix solito).
per aggiungere un utente in samba,
Code:
smbpasswd -a utente

_________________
Come disse un amico, i sistemisti sono un po' come gli artigiani per l'informatica :)
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Tue Jul 20, 2004 11:48 am    Post subject: Reply with quote

si, questo l'avevo fatto, proprio come nell'howto...
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Tue Jul 20, 2004 11:53 am    Post subject: Reply with quote

a questo punto controlla effettivamente il proprietario della directory.
ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Tue Jul 20, 2004 11:55 am    Post subject: Reply with quote

la cartella /home/samba e /home/samba/pubblic appartengono a...
[rullo di tampuri]
samba!!
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Tue Jul 20, 2004 12:00 pm    Post subject: Reply with quote

risetta i permessi a 755 (in modo ricorsivo sulla dir per essere sicuro)
e prova a mettere security = user in samba.conf

ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Tue Jul 20, 2004 12:08 pm    Post subject: Reply with quote

gia' testato. usando security = user, su windows mi appare una finestra di login quando tento di accedere allo share... inutile dire che qualsiasi combinazionei di login e password mi da sempre accesso negato. :lol:
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Tue Jul 20, 2004 12:14 pm    Post subject: Reply with quote

mettendo public = yes?
e' strano.

cmq taglierei la testa al toro abilitando un tuo user unix (ziopippo ad es)
facendo il solito smbpasswd -a ziopippo

e lasciando security=user

e' meglio che lasciarlo pub!

ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
pascalbrax
Apprentice
Apprentice


Joined: 21 Jan 2004
Posts: 280
Location: 127.0.0.1

PostPosted: Tue Jul 20, 2004 12:16 pm    Post subject: Reply with quote

beh, per funzionare, funziona.
ho messo i permessi a 777 e tenuto security = share come avevi suggerito tu. ma il mio era piu' che altro una curiosita' didattica :)
_________________
"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler
Back to top
View user's profile Send private message
xchris
Advocate
Advocate


Joined: 10 Jul 2003
Posts: 2824

PostPosted: Tue Jul 20, 2004 12:24 pm    Post subject: Reply with quote

si pero' non ti ho mai consigliato security = share :lol:

io un 777 non lo terrei sul sistema :)

prova con altro utente. (non samba)

ciao
_________________
while True:Gentoo()
Back to top
View user's profile Send private message
FonderiaDigitale
Veteran
Veteran


Joined: 06 Nov 2003
Posts: 1710
Location: Rome, Italy

PostPosted: Tue Jul 20, 2004 5:24 pm    Post subject: Reply with quote

primo, security=share e' il diavolo.
secondo, ogni utente smb deve essere accoppiato a un utente di sistema
_________________
Come disse un amico, i sistemisti sono un po' come gli artigiani per l'informatica :)
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