Fedora - Installation This forum is for the discussion of installation issues with Fedora. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
05-21-2005, 10:30 AM
|
#1
|
Member
Registered: Aug 2004
Posts: 296
Rep:
|
Samba and FC4
Does anyone know if they will be fixing Samba (finally) in FC4? Everything worked so well under FC1 until they broke it in FC2.
Thanks.
============
"samba
Browsing of Windows shares (also known as SMB browsing) fails on Fedora Core 3 systems that have the standard firewall configured. This is most easily noticed in the failure of Nautilus to display shares. The failure is due to the firewall disrupting the broadcast mode of SMB browsing, which is Samba's default setting. There are two workarounds:
*
Configure a WINS server on the network, and set the "wins server" option in smb.conf to the address of the WINS server.
*
Disable the firewall"
|
|
|
05-21-2005, 10:33 AM
|
#2
|
Senior Member
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Rep:
|
How about the obvious other option to fix it.... keep your firewall enabled but add some rules to let the samba ports through....
|
|
|
05-24-2005, 05:46 AM
|
#3
|
Member
Registered: Aug 2004
Posts: 296
Original Poster
Rep:
|
Samba and FC4
I'm just a beginner with Linux. I wouldn't know how and I'm not especially keen on putting holes in the firewall since I wouldn't know what I'm doing.
|
|
|
05-24-2005, 09:36 AM
|
#4
|
Senior Member
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Rep:
|
Code:
#!/bin/sh
#Setup the path to your iptables firewall.
IPTABLES=/sbin/iptables
#Allow incoming Samba connetions
${IPTABLES} -A INPUT -p tcp --dport netbios-ssn -j ACCEPT
${IPTABLES} -A INPUT -p tcp --dport microsoft-ds -j ACCEPT
${IPTABLES} -A INPUT -p udp --dport netbios-ns -j ACCEPT
${IPTABLES} -A INPUT -p udp --dport netbios-dgm -j ACCEPT
Try running the above script and see if that fixes your problem. Your going to have to run it as root, and make sure to set IPTABLES= to the path to your iptables executable on your system.
|
|
|
05-28-2005, 01:53 PM
|
#5
|
Member
Registered: Aug 2004
Posts: 296
Original Poster
Rep:
|
Thanks for the help. I'll give it a try.
|
|
|
06-16-2005, 10:39 AM
|
#6
|
LQ Newbie
Registered: Jun 2005
Posts: 2
Rep:
|
Hi!
I just downloaded and installed FC4 (6-14-2005).
I thought I'd share how I got Samba to work.
By the way, my problem was not Samba. It works just fine.
My problem was misunderstanding SELinux.
In a nutshell, I did three things:
1) Opened the firewall for Windows SMB, et al.
2) Relaxed SELinux security.
3) Configured and started Samba.
If you're using Gnome, you can find the firewall and SELinux
configurations under "Desktop/System Setings." Look to
SELinux configuration to relax the Samba-related stuff.
Look to the Firewall configuration to open ports for Samba
with this:
137:udp,137:tcp,139:udp,139:tcp,445:udp,445:tcp
Alternatively, just add the lines to /etc/sysconfig/iptables
with this:
-A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 137 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 137 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 139 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 139 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 445 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 445 -j ACCEPT
The SELinux stuff is pretty obvious in the GUI, and I haven't yet checked
out the configuration files on the filesystem.
Then, just configure Samba however you normally do it.
Because the firewall is letting everything in, you might want to specify
the allowed hosts in smb.conf, something like this:
hosts allow = 192.168. 127.
Christopher
|
|
|
06-27-2005, 03:14 PM
|
#7
|
LQ Newbie
Registered: May 2005
Posts: 28
Rep:
|
hey i'm having a problem with samba, when i enter the username and password the prompt keeps coming back up and i am entering the correct username and password i'm doing everything i normally do for the previous versions of fedora but it is just not logging in
|
|
|
06-27-2005, 04:02 PM
|
#8
|
Senior Member
Registered: Oct 2003
Location: /earth/usa/nj (UTC-5)
Distribution: RHEL, AltimaLinux, Rocky
Posts: 1,151
Rep:
|
froggo: Provided you have the proper “holes” in your firewall, the login problem you are describing often has to do with the target folder’s ownership and permission settings.
If the samba client (i.e., you) is the folder’s owner and you don’t want to share the folder, set permission to 700. Otherwise, set the permission to 777 and any valid samba client with login rights for the folder can view/edit the folder’s contents. Likewise, any file you want to access needs to have similar ownership/permission settings. To change these settings globally for the folder, look at:
man chown
man chgrp
man chmod
Examples:
chown -R owner_name /home/samba/folder
chgrp -R group_name /home/samba/folder
chmod -R 777 /home/samba/folder
Be sure to read the man pages before you use these commands, as a mistake can be very difficult to correct (e.g. “chmod -R 777 /” or "chown -R user_name /" #PS: Absolutely do not run these commands).
Last edited by WhatsHisName; 06-27-2005 at 04:08 PM.
|
|
|
06-27-2005, 08:53 PM
|
#9
|
LQ Newbie
Registered: Jun 2005
Posts: 2
Rep:
|
Also...
If you have SELinux installed, and have not relaxed the SELinux security settings,
then you will see "the same thing." You can see if this is what is happening by
taking a look at the log files in /var/log/samba. SELinux somehow convinces Samba
that the share's filesystem directory is not valid directory. All the Samba client knows
is that things didn't work out.
Try relaxing the SELinux settings if this is happening.
Chris
|
|
|
07-06-2005, 09:36 PM
|
#10
|
LQ Newbie
Registered: Jul 2005
Distribution: Suse, FC, RHEL
Posts: 2
Rep:
|
Gnome Samba access broke with FC4
I had a working Samba share setup in Gnome (Places-->Connect to server, Nautilus, etc) using my Fedora laptop to access my home server. After installing FC4, it's broken: I always get "You do not have the permissions necessary to view the contents of ...." when trying to open my home directory on the server. I can access it using smbclient from the laptop, or mount it via "mount -t smbfs...." (as root on the laptop), just can't get to it with the GUI. I never get prompted for a Samba password, nor for the Gnome keyring password. Probably simple, but it's eluding me.
|
|
|
09-24-2005, 12:43 PM
|
#11
|
LQ Newbie
Registered: Mar 2004
Posts: 9
Rep:
|
You need to set the context of the smbpasswd and secrets.tdb files to samba_secrets_t and add samba_enable_home_dirs=1 to the booleans.local file. These changes plus the changes to the iptables will allow the smb service to start and users to connect to their home directories.
|
|
|
09-24-2005, 01:56 PM
|
#12
|
LQ Newbie
Registered: Jul 2005
Distribution: Suse, FC, RHEL
Posts: 2
Rep:
|
Thanks for your interest. As I indicated, the shares are usable with the command line tools, just not with Gnome, so it's not likely to be file permissions or network. Anyway, that looks like Selinux stuff, and I have:
SELINUX=disabled
|
|
|
10-14-2005, 12:43 PM
|
#13
|
LQ Newbie
Registered: Oct 2005
Posts: 1
Rep:
|
FC4 and SAMBA 3.0.2
James Ecker said:
> Distribution: You need to set the context of the smbpasswd and secrets.tdb files to samba_secrets_t and add
> samba_enable_home_dirs=1 to the booleans.local file. These changes plus the changes to the iptables will allow
> the smb service to start and users to connect to their home directories.
This problem is going to bite again as FC4 users like me upgrade to the new (3.0.2) distribution - installing it from the rpm seems to mess up the selinux setups, even if they were OK before. James' fixes seem to solve the problem. To save time for others, you may find it useful to know that smbpasswd and secrets.tdb are in ,/etc/samba, and booleans.local is in /etc/selinux/targeted (at least in FC4)
|
|
|
12-29-2005, 11:39 AM
|
#14
|
Member
Registered: Mar 2005
Distribution: Ubuntu 7.10
Posts: 40
Rep:
|
Must I something do in the SELinux configuration, if I dibabled it in the bott command with "selinux=0"?
|
|
|
All times are GMT -5. The time now is 05:20 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|