Home arrow Site Administration arrow Page 5 - Dancing The Samba (part 1)

Meet Joe Nobody - Administration

Tired of paying hundreds of dollars for commercial file serversoftware? Looking for an application that lets you share *NIX andWindows files seamlessly across a network? Say hello to Samba, softwarethat's so cool, it'll make you want to kick up your heels and dance,dance, dance!

  1. Dancing The Samba (part 1)
  2. Speaking In Tongues
  3. Building Blocks
  4. Temporary Insanity
  5. Meet Joe Nobody
  6. Home Sweet Home
  7. Access Denied
  8. Mounting Up
By: icarus, (c) Melonfire
Rating: starstarstarstarstar / 12
October 02, 2002

print this article


When you configure a temporary file area on the server using the bare-bones setting above, files and directories created in that area by a specific user are owned by that user alone, and other users cannot delete them. This is because the user and group permissions assigned to each file and directory by Samba reflect the user and group permissions of the connecting client.

This may be advisable in some cases; however, at other times, it can nullify the very purpose of a public file area. In case you'd like to change this default behaviour, you can force Samba to assign every file in this share a particular set of permissions - those that allow full access to all users - so that users can view and delete each other's files. The following configuration directives demonstrate:
comment = Temporary file area
path = /tmp
read only = no
guest ok = yes
force create mode = 0777
force directory mode = 0777
force user = nobody
force group = nobody
Restart the Samba daemons,
$ killall smbd
$ killall nmbd
$ /usr/local/samba/bin/smbd -D
$ /usr/local/samba/bin/nmbd -D
and try creating a file in this temporary area - you'll see that the file is created with world-writeable permissions, and with user and group both set to "nobody", the least privileged user on most UNIX systems. This allows every user to view and delete every other user's files in the temporary area, making it truly "public".

You can simplify the process of starting and stopping Samba by creating a few simple shell scripts to do the job for you. Here are the scripts I'm using:
# stop.sh - stop the Samba daemons
killall smbd
killall nmbd
# start.sh - start the Samba daemons
/usr/local/samba/bin/smbd -D
/usr/local/samba/bin/nmbd -D

>>> More Site Administration Articles          >>> More By icarus, (c) Melonfire

blog comments powered by Disqus
escort Bursa Bursa escort Antalya eskort


- Coding: Not Just for Developers
- To Support or Not Support IE?
- Administration: Networking OSX and Win 7
- DotNetNuke Gets Social
- Integrating MailChimp with Joomla: Creating ...
- Integrating MailChimp with Joomla: List Mana...
- Integrating MailChimp with Joomla: Building ...
- Integrating MailChimp with Joomla
- More Top WordPress Plugins for Social Media
- Optimizing Security: SSH Public Key Authenti...
- Patches and Rejects in Software Configuratio...
- Configuring a CVS Server
- Managing Code and Teams for Cross-Platform S...
- Software Configuration Management
- Back Up a Joomla Site with Akeeba Backup

Developer Shed Affiliates


Dev Shed Tutorial Topics: