Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 07-20-2006, 03:44 PM   #1
LQ Newbie
Registered: Nov 2005
Posts: 6

Rep: Reputation: 0
connecting to samba server?


I am relativly new to linux, but have some basic knowledge.
I was running fedora core 4 up until 6 months ago as a web server , we then moved house and the machine was in storage as we have been busy reenovating the house. On switching the fedora box back on the disk failed - an ideal time to move on to Fedora core 5.
I have installed the system and it works fine only I am having problems with Samba.
I have set up a share to the var/www folder and I can see the share on my Windows XP laptop only when I try to access the folder I am propted for a user name and password. I have tried every combination of user name and password to access the share but can not gain access to the folder what am I doing wrong?



Last edited by cirrus42; 07-20-2006 at 03:58 PM.
Old 07-20-2006, 04:01 PM   #2
Registered: Sep 2005
Distribution: Slackware 13.37
Posts: 112

Rep: Reputation: 15
You can check your /etc/samba/smbpasswd file to see which users are registered to use samba shares then check the share in your smb.conf file to see which of the users or groups you have assigned to the share.

You can always change a users password by using smbpasswd [username].

Hope this helps
Old 07-20-2006, 05:59 PM   #3
Registered: Apr 2006
Location: Nairobi
Distribution: CentOS
Posts: 78

Rep: Reputation: 21
you could also make the share public and browseable by all.
Old 07-20-2006, 06:12 PM   #4
LQ Newbie
Registered: Nov 2005
Posts: 6

Original Poster
Rep: Reputation: 0
All the samaba users and passwords appear to be correct and are assigned to the correct shares.
I have tried making the shares public and browsable by all, no sucess
I have allowed access to guests to see if this helps, this has caused futher problems as now instead of the windows user name/password prompt I am being told that the workgroup is not accessable.
On top of this Apache has failed and will not restart, looks like I will have to reinstall.
I think I will go back to core 4 as I never had problems like this

Last edited by cirrus42; 07-20-2006 at 06:14 PM.
Old 07-20-2006, 10:32 PM   #5
LQ Newbie
Registered: Jul 2006
Location: Canberra Australia
Posts: 28

Rep: Reputation: 16
I had a similar problem with fc5. I fixed it by linking the folder to an existing share. I did this because after a lot of playing with samba configuration the only folder i could successfully share with the windows network was the home directory of a generic network user. I know this is a newbie solution to a newbie problem so don't flame me guys

Last edited by lazyFoot_theMighty; 07-21-2006 at 11:16 AM.
Old 07-21-2006, 03:47 AM   #6
LQ Newbie
Registered: Nov 2005
Posts: 6

Original Poster
Rep: Reputation: 0
After playing with the server for half the night, everything fell over, VNC, Apache and Samba have failed completely and reinstalling the paclages only got apache to work. I am currently reinstalling Fedora 5 once I have done this I will outline the complete set up I have and if some one can guide me through I would be very grateful, I dont want to have to go back to core 4 if I dont need to!
Old 07-21-2006, 09:18 AM   #7
LQ Newbie
Registered: Nov 2005
Posts: 6

Original Poster
Rep: Reputation: 0
Lets start again
I have reinstalled fedora 5
Apache is working as is VNC, if someone can guide me through setting up Samba to share the www folder I would be very grateful.

A few details first

I have a windows workgroup - name cirrus42
3 windows XP machines all with a a log on named webdev which have XP admin privilages.
I want to log in from my laptop which has the name laptop

The fedora box has been named
There are just 2 logons to the fedora box - root and webdev

I want to log onto the fedora box from the windows machines while I am logged into them as webdev
I only require access to the www folder and its subdirectories on fedora

I would prefer to use the GUI tools provided with fedora to set up this share, or if someone can guide me through setting up SWAT as well I dont mind using that

so if some one would like to spend 10 mins writing an explaination on how I do this correctly I will be very happy
Old 07-22-2006, 01:19 PM   #8
LQ Newbie
Registered: Nov 2005
Posts: 6

Original Poster
Rep: Reputation: 0

can some please help me with this as it is driving me completely mad

I have tried everything and the best I can do is see the shares from the window laptop, if I try and log in to a share I am asked for user name and password, I input these but nothinh happens.

I have set it up to allow guest accouts and again I am still asked for a password

Nothing I do allows me access to shares.

I am begining to think that Fedora 5 is a waste of time
Old 07-28-2006, 04:04 AM   #9
Registered: Sep 2005
Distribution: Slackware 13.37
Posts: 112

Rep: Reputation: 15
It would be good for us to know what distribution you use, this way we will know what your system's preconfiguration is.
Fedora has an option to run SELinux you might want to turn it off, as it blocks samba.

This is of course if you think that everything you dhave configured is correct.

Here is something I wrote when I 1st used Samba on Redhat 8 ... Fedora should be pretty much the same:

How to configure Samba:

Redhat Linux comes with Samba preconfigured., so there are very few steps to be taken:

Log as root User:

Create the Samba Password File (if it does not exist already):
cat /etc/passwd | > /etc/samba/smbpasswd

Edit the File and remove all users you do not want to use Samba:

Then Protect the File to only have root changing it:
chmod 600 /etc/samba/smbpasswd

Generate the passwords for Users, as the smbpassword file while creation does only generate the users but not passwords:
/etc/samba/smbpasswd username !Username must exist in Linux passwd

Edit the file /etc/samba/smb.conf :
workgroup = MYGROUP
server string = Samba Server

Generate Filesharing entries:
comment = Whatever
path = Share Folder !Must exist or be created
valid users = jim john or you can use a group: @accounting
public = yes
writable = yes
printable = no
create mask = 0770 !Create and Directory mask like chmod: Owner-Group-Others
directory mask = 0770

Start the Samba Service by checking smb in services, save ad then start it.

The path (Share Folder) should be located in a place where it can be accessed by all users. IE you could create a folder sambaroot in / and give it 0777 access then put the share in there.

The Shared Folder has to be owned by the group that accesses it or the user that owns it. So, do the necesary chown and chmod:
IE: chown john:accounting /sambaroot/sharefolder
chmod 0770 /sambaroot/sharefolder

I hope this is not too complicated.
Also look at the samples smb.conf; there is some cool stuff for share ideas.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Connecting to Samba server rexthecoollion Linux - Networking 2 06-09-2006 02:21 AM
Connecting Windows XP client to Samba server srini2001 Linux - Networking 5 03-15-2006 10:25 AM
Samba (again!) and connecting to server cyclic Linux - Networking 2 03-18-2004 04:33 AM
Connecting Samba to Windows 2000 server domain subzero80 Linux - Networking 0 12-01-2003 06:35 PM
Connecting to Samba Server from Windows explorer Linux - Networking 7 03-16-2003 06:26 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:13 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration