View previous topic :: View next topic |
Author |
Message |
SZwarts l33t


Joined: 13 Oct 2003 Posts: 629 Location: Sydney, NSW, Australia
|
Posted: Mon Apr 17, 2006 8:37 am Post subject: Samba Client, login in to domain |
|
|
On my work I am more or less in control over my own computer, and I have installed Gentoo there.
Now when using smbclient and smbmount my username and my password I can access the files on our fileserver, so far so good.
Now a collegue has shared a folder on his computer (windows XP) and has given me read rights.
I was selected fromt he list of people in our domain, let's say XXX
Now if I login to a random windows computer here, with my username and I log in to domain XXX I can access these shares.
However using linux and smbclient //computer/share -U myusername and my password for this domain I cannot get access to this shares. (Although on that computer I can use that username and password to log in)
After some searching around I found the hint to join a domain using net join. This seemed to be a step in the right direction.
However a net join fails:
Code: |
$ net join -w XXX -U username
Password:
[2006/04/17 18:14:04, 0] utils/net_rpc_join.c:net_rpc_join_newstyle(295)
error setting trust account password: NT_STATUS_ACCESS_DENIED
Unable to join domain XXX.
|
This is checking my password, because if I mistype my password I get:
Code: |
Could not connect to server SITH
The username or password was not correct.
|
Now my question is, am I right in thinking this problem is caused by not being a member of the domain?
And if so how do I join?
To make it clear, I don't have a samba server running, the only thing I want is to access the shares of someone else. (The moment I start searching on samba and domain people tell me how to configure a domain server, this is not what I want) _________________ only when it is dark enough, can you see the stars |
|
Back to top |
|
 |
bhun n00b

Joined: 01 Dec 2002 Posts: 70
|
Posted: Mon Apr 17, 2006 9:37 am Post subject: Re: Samba Client, login in to domain |
|
|
SZwarts wrote: |
To make it clear, I don't have a samba server running, the only thing I want is to access the shares of someone else. (The moment I start searching on samba and domain people tell me how to configure a domain server, this is not what I want)
|
Erm, we're stuck on NT4 at work and have workstation doing a live cd boot from gentoo (I then just chroot to some unused partition). Anyways, I connect to the rest of the Windows network by first adding alias for the netbios server names to my /etc/hosts:
Code: |
$ cat /etc/hosts
127.0.0.1 tomato localhost
171.21.76.229 fe80008
171.21.76.227 fe80006
|
And added two functions to my bash login profile (I tend not to write separate scripts for a oneliner for personal use) :
Code: |
# Lists all availabe shares on a windows server
-smb-list () { smbclient -L $1 --user <domain>\\<username> ; }
# Pull in a remote share using SMB.
-smb-mount () { smbmount $1 $2 -o username=<domain>\\<username> ; }
|
Replace <domain> with your logon domain and <username> with your windows user name. I can then just list the shares on a smb server using (I'm prompted for a password afterwards):
Code: |
-smb-list <computername>
|
Mounting a share is done using the other function (prompted for a password again):
Code: |
-smb-mount //<server-name>/<share-name> <mountpoint>
|
bhun. |
|
Back to top |
|
 |
nobspangle Veteran


Joined: 23 Mar 2004 Posts: 1318 Location: Manchester, UK
|
Posted: Mon Apr 17, 2006 10:02 am Post subject: |
|
|
You may need to include your domain name when trying to connect to shares on another PC.
Code: | smbclient //computer/share -U myusername -W mydomainname |
|
|
Back to top |
|
 |
SZwarts l33t


Joined: 13 Oct 2003 Posts: 629 Location: Sydney, NSW, Australia
|
Posted: Tue Apr 18, 2006 6:58 am Post subject: |
|
|
nobspangle wrote: | You may need to include your domain name when trying to connect to shares on another PC.
Code: | smbclient //computer/share -U myusername -W mydomainname |
|
Great... this works...
But...
from a windows computer a get a nice listing of shared directories.
From linux I only get the list of defaults shares (like c$ etc..)
If I know the name of the share I can still enter it but it doesn't show with a smbclient -L
(even with my username password and domain)
anyway who can explain this? _________________ only when it is dark enough, can you see the stars |
|
Back to top |
|
 |
nobspangle Veteran


Joined: 23 Mar 2004 Posts: 1318 Location: Manchester, UK
|
Posted: Tue Apr 18, 2006 7:10 am Post subject: |
|
|
try adding a wins server to your smb.conf that might do the trick |
|
Back to top |
|
 |
SZwarts l33t


Joined: 13 Oct 2003 Posts: 629 Location: Sydney, NSW, Australia
|
Posted: Wed Apr 19, 2006 1:54 am Post subject: |
|
|
nobspangle wrote: | try adding a wins server to your smb.conf that might do the trick |
Two questions:
Why would a wins server know about the shares which are only accesible for me? I can see all the "normal" shares but I can't list the shares which are made for me only. So I don't understand why adding a wins server would do the trick.
And isn't smb.conf the server configuration anyway?
Two, how do I find what the wins server is. If I recall correctly that information is given by the DHCP server, but /etc/resolve.conf doesn't mention a wins server. _________________ only when it is dark enough, can you see the stars |
|
Back to top |
|
 |
|
|
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
|
|