LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-24-2008, 09:34 AM   #1
ziggy25
Member
 
Registered: Aug 2005
Distribution: Debian 5.2
Posts: 56

Rep: Reputation: 15
Need help setting up samba between Linux and Windows X P


Hi all,

I have to machines that i would like to be able to access from one to the other. I would like to be able to access shares on the Linux (Fedora 8) machine from my Windows XP machine.

The IP addresses are configured as below

Code:
XP - 192.168.0.2
Linux - 192.168.0.3

Both XP and linux machines have the following configuration
Subnet mask - 255.255.255.0
Gateway(Router address) - 192.168.0.1
I have installed Samba and it is running. The problem i have is that when i try to map to the linux share on my XP machine the username and password are never accepted.

The username i am logged on as on the XP box is the same username and password that is configured on Samba. I try to access it using the "Map to Network Drive" option on explorer. I then type the share path as

Code:
\\192.168.0.3\music
I get a login prompt but when i enter the login details they get rejected. Here is the samba configuration file.

Code:
# Global Parameters

        workgroup = WORKGROUP
        netbios name = samba
;       encrypt passwords = yes

[homes]
        read only = no
        browseable = no

[music]
        path = /tmp
;       browseable = yes
        write list = ziggy, root
        writeable = yes
        guest ok = yes

[everyone]
        path = /data/everyone
        read only = no
;       browseable = yes

[apps]
        path = /data/apps
;       browseable = yes
        valid users = @admins, ziggy, root
        write list = @admin, ziggy, root
At the moment i am just testing the connection so im using the [music] share which is just pointing to the /tmp directory.

One other thing that i found interesting is that i can ping the linux box from the XP box but not the other way round.

One other interesting thing is that when i click on
Start > My Computer > My Network Places > View Workgroup computers on the XP machine i see an icon called "samba 3.0.30.fc8(Samba)". Wheni click on it i get the following error.

Code:
\\samba is not accessible. You might not have permision to use this network resource.
Im not sure why its refered to as \\samba.

Can anyone please offer some help as to what i am doing wrong.

thanks


Thanks

Last edited by ziggy25; 08-24-2008 at 10:20 AM.
 
Old 08-24-2008, 10:27 AM   #2
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,215

Rep: Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849
Let me see if I can help.

Quote:
One other thing that i found interesting is that i can ping the linux box from the XP box but not the other way round.
You need IP connectivity in both directions, first. The rest of the issues can not be sorted until this is fixed.

My guess, you probably have the firewall on XP blocking the reverse ping. Try turning it off, and try the ping again. I have several XP systems, and a vista box all working. You can run the firewall, but have to open the posts for windoze networking for it to work. Since you have a router, they are usually firewalled, so unless you have an internal security concern, you can leave the windbloze firewall off. Your choice, but if it is on, ports have to be open.

In general terms, you do not share anything in the '/' root directory. So the permission issue is probably related to the /tmp ( root ) location. Create a /home/yourusername/music directory, put a mp3 in there and share it. Try again. You will need to add the share to the /etc/samba/smb.conf file.

If the user names are the same on both systems, and the passwords are the same, and you added the users and passwords to samba with 'smbpasswd' command, then the only other thing that may cause problems is the encryption. You have
Quote:
; encrypt passwords = yes
Note, the ';' is commenting out this line. I think encryption = yes is the default, and this is what XP sends, unless you have altered it in the registry. So, remove the ';' character, unless you edited the registry.

Post back your results.
 
Old 08-24-2008, 11:00 AM   #3
ziggy25
Member
 
Registered: Aug 2005
Distribution: Debian 5.2
Posts: 56

Original Poster
Rep: Reputation: 15
I've disabled the XP firewall and can now ping both ways.

I changed the smb.conf file and restarted samba as you suggested but i still cant connect to it. Here is the changed smb.conf file. I changed the [music] share to point to a directory that exists in my home directory.

Code:
# Global Parameters

        workgroup = WORKGROUP
        netbios name = samba
        encrypt passwords = yes

[homes]
        read only = no
        browseable = no

[music]
        path = /home/ziggy/Pictures
        browseable = yes
        write list = ziggy, root
        writeable = yes
        guest ok = yes

[everyone]
        path = /data/everyone
        read only = no
;       browseable = yes

[apps]
        path = /data/apps
;       browseable = yes
        valid users = @admins, ziggy, root
        write list = @admin, ziggy, root
The Pictures directory has the following permissions set and i am loggin on as the ziggy user.
Code:
8 drwxr-xr-x 8 ziggy ziggy 4096 2008-07-31 19:44 Pictures
Is there anything else i can check/do to get it to work? Do i need to do anything with the router firewall?

Last edited by ziggy25; 08-24-2008 at 11:02 AM.
 
Old 08-24-2008, 12:03 PM   #4
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,215

Rep: Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849
Your firewall to the outside world should have nothing to do with the problem. For now, leave it alone. You now have IP connectivity.

You do not have much in the Global section, so you are using samba defaults. Not sure what is now causing the problem.

Can you 'see' the shares it you go to Network Neighborhood or what ever they call it this week at M$ ?

I'm going to post my smb.conf, you will see I'm using wins config. If you can not see the shares, then enable Wins in samba, and config it on your winbloze system. That may help, it won't hurt and will improve speed at finding things on the network. Make sure the workgroup name is the same on all machines... also.

Quote:
[global]
workgroup = CLIFFSHOME
server string = Samba Server %v
map to guest = Bad User
guest account = guest
log level = 3
log file = /var/log/samba/%m.log
max log size = 50
printcap cache time = 60
printcap name = cups
os level = 255
preferred master = Yes
dns proxy = No
wins support = Yes

[homes]
comment = Home Directories
read only = No
browseable = No

[printers]
comment = All Printers
path = /var/spool/samba
create mask = 0700
guest ok = Yes
printable = Yes
print command = lpr-cups -P %p -o raw %s -r # using client side printer drivers.
use client driver = Yes
browseable = No

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

[pdf-gen]
comment = PDF Generator (only valid users)
path = /var/tmp
printable = Yes
print command = /usr/share/samba/scripts/print-pdf "%s" "%H" "//%L/%u" "%m" "%I" "%J" &
lpq command = /bin/true

[Music]
comment = For any user to browse and listen
path = /home/cliff/Music

[pictures]
comment = Cliffs digcam pics
path = /home/cliff/Pictures
valid users = cliff, corinne, sheena, @cliff
read list = corinne, sheena, peigi
write list = cliff
read only = No
 
Old 08-24-2008, 12:29 PM   #5
ziggy25
Member
 
Registered: Aug 2005
Distribution: Debian 5.2
Posts: 56

Original Poster
Rep: Reputation: 15
Thanks guys for your help i can now see the shares. I changed the file as shown below and it now seems to be working. I dont quite know what change fixed it.
Code:
# Global Parameters

        workgroup = WORKGROUP
        netbios name = Samba
        encrypt passwords = yes
        security = share

[homes]
        read only = no
        browseable = no

[media]
        path = /media
        browseable = yes
        writeable = yes
        valid users = ziggy, root
I noticed you have cliff and @cliff in the valid users section. What does it mean when it is prefixed with the @ sign?

Thanks
 
Old 08-24-2008, 01:35 PM   #6
xologist
LQ Newbie
 
Registered: Aug 2008
Location: Pensacola, Fl. Lived in MD, DC and VA area for years
Distribution: Debian Etch
Posts: 17

Rep: Reputation: 0
I am currently working with Samba to set up my multi dimensional Microslop and Linux network and stumbled on a free Samba ebook that addresses alot of issues discussed in your post. The link, if the ebook isn't in your documentation is http://oreilly.com/catalog/9780596002565/. They go into detail with each MS operating system network config for interfacing Samba with the exception of Windows Server 2003 which I also have lashed up to my network. At any rate I thought the documentation resource might be worthwhile as it is well written and seems pretty comprehensive. I am not an expert of course. Good luck.

Jim Frock
 
Old 08-24-2008, 03:59 PM   #7
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,215

Rep: Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849Reputation: 849
The @cliff allows members of the cliff group to use the share. I added my family members to the cliff group.
 
  


Reply



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
setting up a printer with cups on RH7 for windows with samba TreeHugger Linux - Networking 2 11-11-2004 11:31 AM
Setting up SAMBA with ADS toa Windows Active Directory llyr Linux - Software 3 09-11-2004 10:20 PM
Setting up Samba with Windows XP and Redhat 9.0 Intrepid-XC Linux - Newbie 3 04-01-2004 07:20 AM
Setting up Samba 3.0 as a PDC for windows/linux. Mike@Work Linux - Networking 3 02-16-2004 06:44 AM
setting up Samba so i can access a dir from my other Windows PC's andara Linux - Newbie 3 11-21-2003 12:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:25 AM.

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