LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Setting Up Samba (https://www.linuxquestions.org/questions/linux-newbie-8/setting-up-samba-104267/)

tapanga 10-15-2003 11:35 AM

Setting Up Samba
 
I am able to ping from a windows box to a mandrake 9.1 box.

and now i'm trying to connect to mandrake 9.1 box from windows box via samba.

I am following instructions from
http://ca.samba.org/samba/docs/man/S...html#id2859057

and testing a simple samba configuration jsut to make sure that I can actually login and that everything SAMBA is working.

smb.conf looks like this

[global]
workgroup = MIDEARTH

[homes]
guest ok = no
read only = no


i added a user called guest
gave the user a password
and then did a smbpasswd guest

i then try log in from windows box - with all the network domain information set correctly ( i know this because i have another server running samba correctly that i never set up)

I think samba is started when i boot up linux - but how and what do i need to check to make sure everything SAMBA is running.

jdc2048 10-15-2003 01:04 PM

you have "guest ok = no" but then you added a user called guest?

have you tried to smbmount the share locally back onto the mandy box as a valid user? what errors do you get?

tapanga 10-16-2003 09:13 AM

I guess i should have also stated that i added several other users and they also don't log in - please bare with me i'm very new to all this.



Quote:

have you tried to smbmount the share locally back onto the mandy box as a valid user? what errors do you get?
how do i do this???

jdc2048 10-16-2003 09:43 AM

Code:

smbmount //<servername>/<sharename> /<mountpoint> -o username=<user>

jdc2048 10-16-2003 09:48 AM

to check if samba is working (first post), try doing a "ps -ef | grep smb" and a "ps -ef | grep nmb"

You should see the 2 processes running.

on a side note, it wouldn't hurt to dump a list of iptables just to verify that you dont have some firewall rule blocking.

"iptables -L"

tapanga 10-17-2003 11:33 AM

HI

I'v been doing lots more reading and searching the forums and this is where i'm at.

smb and nmb are running. i did
"ps -ef | grep smb" and a "ps -ef | grep nmb"
and saw two processes running for each

I did iptables -L
and got

chain input (policy ACCEPT)
target prot opt source destination

chain forward (policy ACCEPT)
target prot opt source destination

chain output (policy ACCEPT)
target prot opt source destination


so i assume there are no firewall rules blocking.

then i did some more reading and decided to follow the instructions on
http://hr.uoregon.edu/davidrl/samba.html

so smb.conf looks like this now

[global]
netbios name = MYSERVER
server string = "Is It Not Nifty?"
workgroup = WORKGROUP
security = share
log file = /var/log/samba.log
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
wins support = yes

[public]
path = /tmp
guest ok = yes
writeable = yes



then i do a

smbclient -U% -L localhost

and get

Domain=[WORKGROUP] OS=[Unix] Server=[Samba 2.2.7a]
Sharename Type Comment
-------------- ----- ------------
public Disk
IPC$ IPC IPC SERVICE ("Is It Not Nifty?" )
ADMIN$ Disk IPC SERVICE ("Is It Not Nifty?" )


Server Comment
-------- ------------


Workgroup Master
-------------- ---------



I go to my windows box and at the command prompt type

NET USE O: \\MYSERVER\public /YES

and get
error 3787 : You must log on before performing this operation

I just don't know what i'm missing

i still need to try smbmount again
--------------------------------------------------------------------------------
smbmount //<servername>/<sharename> /<mountpoint> -o username=<user>

how can i check my server name?

tapanga 10-17-2003 11:44 AM

I Tried
smbmount //<servername>/<sharename> /<mountpoint> -o username=<user>

smbmount //127.0.0.1/public /mnt/samba -o username=guest
it askes for a password so i give it guest as password

then i make sure windows client for microsoft network properties is checked for log onto NT domain and the domain name is WORKGROUP and in identification tab workgroup is set to WORKGROUP

restart windows and try log in

username : guest
password : guest
domain: WORKGROUP

error message : no domain server was availalbe to validate your password

jdc2048 10-17-2003 04:07 PM

you can't use domain=WORKGROUP on your windows side unless you have a Windows NT Server serving out a domain. That is why you are getting the domain server cannot be found. Leave your windows box as using a workgroup instead.

I think with "security=SHARE" you are going to have to have a user in windows that is the same as the user on the linux box and the same password.

jdc2048 10-17-2003 04:12 PM

also add "browseable = yes" to your [public] section so that you can see it in network neighborhood.

jdc2048 10-17-2003 04:15 PM

Quote:

Originally posted by tapanga
smbmount //127.0.0.1/public /mnt/samba -o username=guest
it askes for a password so i give it guest as password
so did that work, after running that command on your linux box, can you list the contents of /mnt/samba?

If you can, then samba is working appropriately. You just need to get the workgroup sharing stuff setup so that it doesn't require a password or that you windows box provides the correct password.

By the way, which version of windows are you using?

Septus 10-17-2003 10:52 PM

I Think you need to set your Linux box up as a Primary domain controller then set up your samba shares to give the windows box access to resources on Linux box.

Go to this site and have a read.

http://www.samba.netfirms.com/index.htm

yawhum80 10-19-2003 11:51 PM

hi, i'm newbie and i had set up a samba server and when i use the smbclient -L //main/andy to test the server it work and list out the share resources. But why when i using the command like "mount -t smbfs //main/andy /tmp", it gave me a error message said "connection to main failed". When I open the windows network neigboard, i found that when i open my linux terminal it will pop up a message box and require me to enter a password. How can i ignore it?

tapanga 10-24-2003 09:45 AM

Still having Samba trouble
 
I have now tried to get the simple samba to work from the link

http://www.samba.netfirms.com/index.htm

with smb.conf as the example.
I added a user in linux just as the example and then added a user with the same user name and password on thwe win98 box.
I did not set the domain in windows - but i simply log into windows as the user and then try to do the NET USE but still get the same message.

Quote:

If you can, then samba is working appropriately. You just need to get the workgroup sharing stuff setup so that it doesn't require a password or that you windows box provides the correct password.
I am able to do a smbmount and see the files in /mnt/samba so i must be doing something wrong with the workgroup sharing setup.

another thing i tried to do was ping the windows box from linux.

I got the ipconfig off windows - could this cause my problem - even though i am able to ping to linux from windows???

I am going on to try Samba primary domain controller setup - until i hear from someone.

I really need to get this to work.

thanks you all

synaptical 10-26-2003 11:07 PM

Quote:

Originally posted by jdc2048
I think with "security=SHARE" you are going to have to have a user in windows that is the same as the user on the linux box and the same password.
i don't think so -- with "share" it should work no matter what is the user. you could probably even just leave that line out. i have security = share in my smb.conf, and i can connect fine with a different user name on 2 separate windows machines, both names of which are different from the linux user.

- - - - - - - - - - - -
edit: but i agree about not making the domain = WORKGROUP. you probably should leave the domain out altogether, just to simplify things if nothing else.
- - - - - - - - - - - -

search around on this site, see what you come up with:
http://www.oreilly.com/catalog/samba...k/ch04_01.html


All times are GMT -5. The time now is 05:36 AM.