Re: [gentoo-user] Need help with samba (Possibly OT)

2010-06-15 Thread Michael Sullivan
On Mon, 2010-06-14 at 22:43 +0100, Stroller wrote:
 On 14 Jun 2010, at 21:41, Michael Sullivan wrote:
  ... When I try to connect to the samba share from my
  linux install, I get this:
 
  mich...@camille ~ $ smbclient //carter//home
  Enter michael's password:
  Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
  tree connect failed: NT_STATUS_BAD_NETWORK_NAME
  mich...@camille ~ $ smbclient //carter//michael
  Enter michael's password:
  Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
  tree connect failed: NT_STATUS_BAD_NETWORK_NAME
 
  (The host name is carter, and I didn't understand what the second part
  should be.)
 
 If you're referring to the  //first/second syntax, then the first part  
 is the computer name, the second part the share name.
 
  Also, I didn't know if michael's password meant my password on my
  local box, my password on the remote box, or some password I set up  
  for
  Samba forever ago...
 
 The second / third option.
 
 Each user on the Samba server has a password, but it isn't the same as  
 their system password. Log on to the Samba server (i.e. `ssh carter`)  
 and run smbpasswd (possibly `sudo smbpasswd -U michael`).
 
  Here's my /etc/samba/smb.conf file:
  ...
hosts allow = 192.168.1. 127.
 
 If it's been some time since this system was used, are you still using  
 the 192.168.1.x subnet? If your ISP sent you a new router, you might  
 now be on 192.168.0.x. IMO change this to:
 hosts allow = 192.168. 127.
 
 Also run `smbtree` (works without a password).
 
 I appreciate that Samba tends not to make any sense when you're  
 inexperienced, but there ought to be lots of troubleshooting guides  
 out there. Google troubleshooting samba, follow through the steps  
 suggested by 2 or 3 and report back  tell us what you've done.
 
 Stroller.
   
 
I've got a couple of new errors in the logs:

From /var/log/samba/log.___192.168.1.3:
[2010/06/15 11:56:58,  0] lib/util_sock.c:1564(matchname)
  matchname: host name/address mismatch: :::192.168.1.3 !=
camille.espersunited.com
[2010/06/15 11:56:58,  0] lib/util_sock.c:1685(get_peer_name)
  Matchname failed on camille.espersunited.com :::192.168.1.3

and from /var/log/samba/log.camille:

[2010/06/15 11:56:58,  0] smbd/service.c:942(make_connection_snum)
  Can't become connected user!


What's with the :192.168.1.3?  Camille's address IS 192.168.1.3, and
it seems to know that because it calls the host at the address
'camille'...




[gentoo-user] Need help with samba (Possibly OT)

2010-06-14 Thread Michael Sullivan
My personal workstation is a dual-boot setup with Gentoo and Windows XP.
A long time ago, I set up Samba on another computer on my network to
provide extra hard drive space to our Windows installations.  They used
to work, but we haven't used them in some time.  I tried to use it today
and it didn't work.  When I try to connect to the samba share from my
linux install, I get this:

mich...@camille ~ $ smbclient //carter//home
Enter michael's password: 
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
tree connect failed: NT_STATUS_BAD_NETWORK_NAME
mich...@camille ~ $ smbclient //carter//michael 
Enter michael's password: 
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
tree connect failed: NT_STATUS_BAD_NETWORK_NAME

(The host name is carter, and I didn't understand what the second part
should be.)
Also, I didn't know if michael's password meant my password on my
local box, my password on the remote box, or some password I set up for
Samba forever ago...

Here's my /etc/samba/smb.conf file:

carter samba # cat smb.conf
[global]
   workgroup = MYGROUP
   server string = Samba Server %v
   printcap name = cups
   load printers = yes
   printing = cups
   log file = /var/log/samba/log.%m
   max log size = 50
   hosts allow = 192.168.1. 127.
   map to guest = bad user
   security = user
   encrypt passwords = yes
   socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
   dns proxy = no 

[homes]
   comment = Home Directories
   browseable = no
   writable = yes
   valid users = michael amy
   path = /samba

[printers]
   comment = All Printers
   path = /var/spool/samba
   browseable = no
   guest ok = no
   writable = no
   printable = yes

[print$]
   path = /var/lib/samba/printers
   browseable = yes
   read only = yes
   write list = @adm root
   guest ok = yes

[tmp]
   comment = Temporary file space
   path = /samba
   read only = no
   public = yes
   valid users = michael amy

I'm sure I've screwed something up somewhere, I'm just not sure what it
is.





Re: [gentoo-user] Need help with samba (Possibly OT)

2010-06-14 Thread Stroller


On 14 Jun 2010, at 21:41, Michael Sullivan wrote:

... When I try to connect to the samba share from my
linux install, I get this:

mich...@camille ~ $ smbclient //carter//home
Enter michael's password:
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
tree connect failed: NT_STATUS_BAD_NETWORK_NAME
mich...@camille ~ $ smbclient //carter//michael
Enter michael's password:
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
tree connect failed: NT_STATUS_BAD_NETWORK_NAME

(The host name is carter, and I didn't understand what the second part
should be.)


If you're referring to the  //first/second syntax, then the first part  
is the computer name, the second part the share name.



Also, I didn't know if michael's password meant my password on my
local box, my password on the remote box, or some password I set up  
for

Samba forever ago...


The second / third option.

Each user on the Samba server has a password, but it isn't the same as  
their system password. Log on to the Samba server (i.e. `ssh carter`)  
and run smbpasswd (possibly `sudo smbpasswd -U michael`).



Here's my /etc/samba/smb.conf file:
...
  hosts allow = 192.168.1. 127.


If it's been some time since this system was used, are you still using  
the 192.168.1.x subnet? If your ISP sent you a new router, you might  
now be on 192.168.0.x. IMO change this to:

   hosts allow = 192.168. 127.

Also run `smbtree` (works without a password).

I appreciate that Samba tends not to make any sense when you're  
inexperienced, but there ought to be lots of troubleshooting guides  
out there. Google troubleshooting samba, follow through the steps  
suggested by 2 or 3 and report back  tell us what you've done.


Stroller.
 



Re: [gentoo-user] Need help with samba (Possibly OT)

2010-06-14 Thread Michael Sullivan
On Mon, 2010-06-14 at 22:43 +0100, Stroller wrote:
 If it's been some time since this system was used, are you still using  
 the 192.168.1.x subnet? If your ISP sent you a new router, you might  
 now be on 192.168.0.x. IMO change this to:
 hosts allow = 192.168. 127.
 
I bought a brand new Linksys Wireless-N router a few months ago.  I
configure it to start addresses after 192.168.1.1 because that's what
we've always used, it's what all the computers on our LAN are set up
for, and I see no reason to change it.
 Also run `smbtree` (works without a password).
 
 I appreciate that Samba tends not to make any sense when you're  
 inexperienced, but there ought to be lots of troubleshooting guides  
 out there. Google troubleshooting samba, follow through the steps  
 suggested by 2 or 3 and report back  tell us what you've done.
 
 Stroller.
   

I actually started today at
http://www.samba.org/samba/docs/man/Samba-HOWTO-Collection/install.html

carter ~ # testparm /etc/samba/smb.conf
Load smb config files from /etc/samba/smb.conf
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Processing section [homes]
Processing section [printers]
Processing section [print$]
Processing section [tmp]
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions

[global]
workgroup = MYGROUP
server string = Samba Server %v
map to guest = Bad User
log file = /var/log/samba/log.%m
max log size = 50
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
printcap name = cups
dns proxy = No
hosts allow = 192.168.1., 127.

[homes]
comment = Home Directories
path = /samba
valid users = michael, amy
read only = No
browseable = No
browsable = No

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

[print$]
path = /var/lib/samba/printers
write list = @adm, root
guest ok = Yes

[tmp]
comment = Temporary file space
path = /samba
valid users = michael, amy
read only = No
guest ok = Yes

mich...@camille ~ $ smbclient -L carter  
Enter michael's password: 
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]

Sharename   Type  Comment
-     ---
print$  Disk  
tmp Disk  Temporary file space
IPC$IPC   IPC Service (Samba Server 3.4.6)
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]

Server   Comment
----
CARTER   Samba Server 3.4.6

WorkgroupMaster
----
MYGROUP  CARTER

mich...@camille ~ $ smbclient  //carter/tmp   
Enter michael's password: 
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]
tree connect failed: NT_STATUS_LOGON_FAILURE


Then I went to the Samba Checklist:
http://www.samba.org/samba/docs/man/Samba-HOWTO-Collection/diagnosis.html

1: Run testparm; already did that.
2: Ping test:

mich...@camille ~ $ ping carter
PING carter.espersunited.com (192.168.1.2) 56(84) bytes of data.
64 bytes from carter.espersunited.com (192.168.1.2): icmp_seq=1 ttl=64
time=0.157 ms
64 bytes from carter.espersunited.com (192.168.1.2): icmp_seq=2 ttl=64
time=0.145 ms
^C
--- carter.espersunited.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 999ms
rtt min/avg/max/mdev = 0.145/0.151/0.157/0.006 ms

carter ~ # ping camille
PING camille.espersunited.com (192.168.1.3) 56(84) bytes of data.
64 bytes from camille.espersunited.com (192.168.1.3): icmp_seq=1 ttl=64
time=0.158 ms
64 bytes from camille.espersunited.com (192.168.1.3): icmp_seq=2 ttl=64
time=0.155 ms
^C
--- camille.espersunited.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 999ms
rtt min/avg/max/mdev = 0.155/0.156/0.158/0.012 ms

3: carter ~ # smbclient -L carter   
Enter root's password: 
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]

Sharename   Type  Comment
-     ---
print$  Disk  
tmp Disk  Temporary file space
IPC$IPC   IPC Service (Samba Server 3.4.6)
Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.4.6]

Server   Comment
----
CARTER   Samba Server 3.4.6

WorkgroupMaster
----
MYGROUP  CARTER

4: mich...@camille ~ $ nmblookup -B BIGSERVER __SAMBA__
querying __SAMBA__ on 192.168.1.255
192.168.1.2 __SAMBA__00

4:  carter ~ # nmblookup -B camille *
querying xorg.conf.new on 192.168.1.3
name_query failed to find name xorg.conf.new

*I'm not sure what finding xorg.conf.new has 

Re: [gentoo-user] Need help with samba (Possibly OT)

2010-06-14 Thread Alex Schuster
Michael Sullivan writes:

 4: mich...@camille ~ $ nmblookup -B BIGSERVER __SAMBA__
 querying __SAMBA__ on 192.168.1.255
 192.168.1.2 __SAMBA__00
 
 4:  carter ~ # nmblookup -B camille *
 querying xorg.conf.new on 192.168.1.3
 name_query failed to find name xorg.conf.new
 
 *I'm not sure what finding xorg.conf.new has to do with Samba, but it's
 on the checklist...

The shell replaces the * by files in your current directory. I do not know 
about nmblookup, but I gues you have to escape the *. That is, use '*' or 
\* instead.

Wonko



Re: [gentoo-user] Need help with samba (Possibly OT)

2010-06-14 Thread Michael Sullivan
On Tue, 2010-06-15 at 02:12 +0200, Alex Schuster wrote:
 Michael Sullivan writes:
 
  4: mich...@camille ~ $ nmblookup -B BIGSERVER __SAMBA__
  querying __SAMBA__ on 192.168.1.255
  192.168.1.2 __SAMBA__00
  
  4:  carter ~ # nmblookup -B camille *
  querying xorg.conf.new on 192.168.1.3
  name_query failed to find name xorg.conf.new
  
  *I'm not sure what finding xorg.conf.new has to do with Samba, but it's
  on the checklist...
 
 The shell replaces the * by files in your current directory. I do not know 
 about nmblookup, but I gues you have to escape the *. That is, use '*' or 
 \* instead.
 
   Wonko
 

carter ~ # nmblookup -B camille '*'
querying * on 192.168.1.3
name_query failed to find name *

What is this command looking for?