Search This Blog

Sunday, December 11, 2011

The [printers] Share Section (SAMBA) - PART8


Samba has special shares just for printers, and these are configured in the [printers] section of SWAT. There is also a share under [printers] called printers which governs common printer settings. Print shares always have the printable parameter set to yes. The default smb.conf [printers] share section looks like this:
[printers]
    comment = All Printers
    path = /var/spool/samba
    printable = Yes
    browseable = No

Wednesday, December 7, 2011

The [netlogon] and [profiles] Share Sections (SAMBA, SWAT) - PART7


The [netlogon] share section contains scripts that the windows clients may use when they log into the domain. The [profiles] share section stores settings related to the look and feel of windows so that the user has the same settings no matter which Windows PC is logged into. The [profiles] share section stores things such as favorites and desktop icons.
Your smb.conf file should look like this when you're finished:
[netlogon]
       path = /home/samba/netlogon
       guest ok = Yes

[profiles]
       path = /home/samba/profiles
       read only = No
       create mask = 0600
       directory mask = 0700
Here's how to do it.
  1. Click the Shares button.
  2. Create a [netlogon] share.
  3. Modify the path and guest ok settings.
  4. Click on the Commit Changes button.
  5. Create a [profiles] share section.
  6. Modify the path, mask and read only settings. The mask settings allow only the owner of the netlogon subdirectory to be able to modify its contents.
  7. Click on the Commit Changes button.
Remember to create these share directories from the command line afterwards.
[root@bigboy tmp]# mkdir -p /home/samba/netlogon
[root@bigboy tmp]# mkdir -p /home/samba/profile
[root@bigboy tmp]# chmod -R 0755 /home/samba

Invitation to Join Techgig.com

Dec 07, 2011Techgig
Invitation to join Techgig.com

Dear rarunraj040488.snub,
I would like to invite you to be a part of my exclusive professional network on Techgig.com


Alternatively, you can paste the below address in your browser:
http://www.techgig.com/register.php?InvID=cb2dfd22ca3948f1acf158f3d9663b84

Warm Regards,

Arun
Arun Raj
System Administrator at Ahana Systems and Solutions

Why you should join Techgig.com
We believe that you are a sum of the projects you have been involved in. Big or small, successful or not, it tells the world a lot about you. They are your real work. We envision TechGig to become a leading platform for you to showcase your true work with projects, interact with your peers in technology industry, get latest news and updates and access new opportunities. We want to see you as part of the most exciting Technology community platform.
If you do not want to receive these kind of email notifications, adjust your email settings on Techgig.com to unsubscribe.To make sure this email is not sent to your "junk/bulk" folder, select "Add/save to Address Book" in your email browser and follow the appropriate instructions.
Techgig
2011 TechGig | Terms of Use | Contact Us
TechGig.com (Times Center), FC - 6, Sector 16 A, Film City, Noida - 201301 Uttar Pradesh, India

Tuesday, December 6, 2011

Using The SWAT Wizard (SAMBA) - PART6


The SWAT utility has a Wizard button that can be used to configure your server as a PDC quickly. However the defaults may not be to your liking, for example, the default domain is MYGROUP and some of the [global] parameters mentioned previously will be set to auto.

The [homes] Section

Part of the process of adding a user to a Samba domain requires you to create a Linux user on the Samba PDC itself. When you log into the Samba PDC, you'll see a new drive, usually named Z:, added to your PC. This is actually a virtual drive that maps to the corresponding Linux users' login directories on the Linux PDC.
Samba considers all directories to be shares that can be configured with varying degrees of security. The [homes] section governs how Samba handles default login directories.
Table 10-3 explains the minimum settings you need to create a functional [Homes] section.

Table 10-3 : smb.conf Minimum Settings, "Home" Section

ParameterValueDescription
browseableNoDoesn't allow others to browse the contents of the directory
read onlyNoAllows the samba user to also write to their Samba Linux directory
create mask0664Makes new files created by the user to have "644" permissions. You want to change this to "0600" so that only the login user has access to files.
directory mask0775Makes new sub-directories created by the user to have "775" permissions. You want to change this to "0700" so that only the login user has access to directories.
Here's how to set the values using SWAT:
  1. Click on the SWAT shares button to proceed to where shared directories are configured.
  2. Click the Advanced button to see all the options.
  3. Choose the Homes share.
  4. Make your changes and click on the Commit Changes button when finished.
  5. Your smb.conf file should resemble this when finished. You can view the contents of the configuration file by logging in to the samba server via a command prompt and using the cat /etc/samba/smb.conf to verify your changes as you do them.
[homes]
  read only = No
  browseable = No
  create mask = 0644
  directory mask = 0755

Monday, December 5, 2011

How To Make SWAT Changes Immediate (SAMBA) - PART5


SWAT immediately changes the functioning of Samba whenever you commit your changes through the web GUI.

Creating A Starter Configuration

I'll now illustrate how to configure a Samba server to be the PDC for a small network is by using SWAT. You'll need to edit the various sections of the smb.conf file, so I'll walk you through what you'll find in each.

The [Global] Section

The [global] section governs the general Samba settings. Table 10-2 explains the parameters you need to set in order to create a PDC.

Table 10-2 : smb.conf Minimum Settings, "Global" Section

ParametervalueDescription
domain logonsYesTells Samba to become the PDC
preferred masterYesMakes the PDC act as the central store for the names of all windows clients, servers and printers on the network. Very helpful when you need to "browse" your local network for resources. Also known as a local master browser.
domain masterYesTells Samba to become the master browser across multiple networks all over the domain. The local master browsers register themselves with the domain master to learn about resources on other networks.
os level65Sets the priority the Samba server should use when negotiating to become the PDC with other Windows servers. A value of 65 will usually make the Samba server win.
wins supportYesAllows the Samba server to provide name services for the network. In other words keeps track of the IP addresses of all the domain's servers and clients.
time serverYesLets the samba server provide time updates for the domain's clients.
workgroup"homenet"The name of the Windows domain we'll create. The name you select is your choice. I've decided to use "homenet".
securityuserMake domain logins query the Samba password database located on the samba server itself.
smb passwd file/etc/samba/smbpasswdIt is useful to specify the name and location of the Samba password file. This helps to make Samba version upgrades where the default locations may change.
private dir/etc/sambaSpecifies default directory for some supporting temporary files. As with the password file, it is a good practice to specify this value.
Here's how to set the values using SWAT.
  1. Log into SWAT and click on the [global] section.
  2. Click the Advanced button to see all the options.
  3. Make your changes and click on the Commit Changes button when finished.
  4. Your smb.conf file should resemble the example below when you're finished. You can view the contents of the configuration file by logging in to the samba server via a command prompt and using the cat /etc/samba/smb.conf to verify your changes as you do them.
[global]

       workgroup = HOMENET
       time server = Yes
       domain logons = Yes
       os level = 65
       preferred master = Yes
       domain master = Yes
       smb passwd file = /etc/samba/smbpasswd
       private dir = /etc/samba
Note: security = user and WINS support = yes are default settings for Samba and they may not show up in your smb.conf file, even though you may see them in SWAT.