questo tutorial non è mio ma è stato scritto da vorteX sul
forum di Fedora Faq
Ok, let's do it! Keep in mind, commands are in bold. For simplicity, become root (by issuing su -) now and stay root until otherwise stated.
It helps immensely when we have the software installed. I have tested these simple instructions on samba-3.0.0-15. To check which version of samba you have installed or to simply check whether or not it's even present, issue the rpm -q samba command. If you don't have samba installed or need to upgrade, a simple yum install samba should be sufficient.
Ok the previous task was simple enough. Now let's dig thru some configuration files. I will be editing the file in vi, however you can use what you're most comfortable in. Let's first issue service stop smb to keep from people poking around. Now lets vi /etc/samba/smb.conf. Immediate hit a to throw ourselves into insert mode. Using the arrow keys to move around, edit these variables: (they are in the order of appearence although some scrolling down will be needed)
This is all that needs changing to get us up and browsing through our own home directories/printers. Let's now hit the ESC key, then press SHIFT-Z-Z to save and exit.
This is a boring task. Configuring users. Let's get this over with by issuing cat /etc/passwd | mksmbpasswd.sh > /tmp/smbpass.tmp. This will print out your /etc/passwd file (contains users), pipe it to the mksmbpasswd script, then output an empty user template into /tmp/smbpass.tmp. When that finishes (should be quick), issue vi /tmp/smbpass.tmp. Don't be scared - You just need to be concerned about the usernames on the left hand side. Most of these users are for common services, so you don't want them to be used to access network shares. Scroll down to the line in which the unwanted user lies and hit D twice (DD) (removes line). Get rid of: root, bin, daemon, adm, lp, sync, shutdown, halt, mail, news, uucp, operator, games, gopher, ftp, nobody, rpm, vcsa, nscd, sshd, rpc, rpcuser, nfsnobody, mailnull, smmsp, pcap, mysql, should they exist. After you're left with at least one human user, hit SHIFT-Z-Z to save and exit. Let's now drop this file into it's proper place by issuing mv /tmp/smbpass.tmp /etc/samba/smbpasswd.
Now that we have a valid list of samba users, we need to assign passwords (arghhh boorrringggg). Use the command smbpasswd username (replacing username with a user) to assign passwords. This needs to be done for every samba user, don't try to skip it!
Ok phew, we're done! This is easy - Issue service smb start. You should now see what you saw above, in My Network Places > View Workgroup Computers. You'll need to authenticate as the users we set up above, to browse your home directory!
Further configuration can be done by reading the official Samba FAQ stated at the beginning of this guide.
Have fun!
February 14, 2004 @ 12:21PM // Initial posting.
lib/WikiUser.php:59: Notice[8]: Only variables should be assigned by reference
lib/Template.php:112: Notice[8]: Only variables should be assigned by reference
lib/Template.php:114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'top') (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'top') (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'browse') (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'browse') (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'browse-footer') (In template 'browse') (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'browse-footer') (In template 'browse') (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'actionbar') (In template 'browse-footer') (In template 'browse') (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'actionbar') (In template 'browse-footer') (In template 'browse') (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):112: Notice[8]: Only variables should be assigned by reference
lib/Template.php (In template 'body') (In template 'html'):114: Notice[8]: Only variables should be assigned by reference