On Sun, Jul 29, 2007 at 08:39:35PM -0500, John House wrote: > I have one set up at my home, but I have not actually transferred files > much. Just set it up last week for redundancy as I have old PCs. > > I will try to document by next week, but essentially, you load SAMBA and > create your shares. > > On Sun, 2007-07-29 at 11:58 -0500, Robert Citek wrote: > > Sean, can you describe how you setup Samba? There's no hurry as I > > realize you're packing up and moving to Columbia, just whenever you > > get > > a chance. > > > > Regards, > > - Robert
When I get settled in at the new place, I'll document setting up SAMBA on the wiki. While it was fairly straightforward, I couldn't find anything on the web specific to setting up SAMBA on Ubuntu. So there was some guessing involved. Everything I found on the Internet involved messing with the SAMBA configuration file. But I didn't have to touch that with Ubuntu. Dan and/or Theresa suggested using one of the pre-installed Ubuntu disks we had from the city of Chesterfield (I believe). After installing the Ubuntu hard drive, and because we didn't have a password for the systems on those hard drives, (per Dan's suggestion) I needed to boot into single user mode to change the password. Actually, it's pretty scary how easy that was. While I've always heard you could change the password that way, I've never done it before. Booting into single user mode gives you a root shell. After learning that the default username on this computer was "ubuntu", I issued this command to delete the password (not sure if that was necessary) and then issued a new command to create a new password: passwd --delete ubuntu passwd ubuntu The new password begins with a "j". Everyone should know what it is. But it's written on a label on the computer. After the password was changed. I rebooted and logged in as the "ubuntu" user and updated the computer first. In the Gnome desktop, go to System ==> Administration == Shared Folders. After entering your password, a window popped up saying "Sharing services are not installed." You then have the option of Installing services for NFS or for Windows network SMB (Samba). I chose only Samba and pressed "Install services". Samba installs. The Shared Folders window is made available. There are two hard drives on the file server and we wanted the second 40 gig hard drive (formatted as a fat32 system) to be accessible via Samba. I clicked on the "+ Add" button. In the Path field, I chose the location of the second hard drive and everything else was left as default. This is the info: Shared Folder Path: /media/hdb5 Share through: Windows networks (SMB) Share Properties Name: ubuntu Comment: I left the comment field blank and there was a checkbox option to have this read only. I unchecked that. And pressed okay. After I did this, Samba was running and I went to the XP machine and chose Network Neighborhood and to my surprise, after doing a network scan on the XP machine, the Ubuntu file server appeared. That was so cool. Alas, there was a small hiccup. We couldn't access it. While 99.999% of the information I found on the Web was unnecessary, I remembered reading something which turned out to be rather important. I needed to create a password for Samba that linked to the default user on this machine, which was "ubuntu". I went back to the file server and ran the following command: sudo smbpasswd -a ubuntu I got a prompt to enter a password. I used the "j" password again. Then I restarted samba: /etc/init.d/samba restart After a minute or so, I went back to the XP machine and attempted to gain access to the File Server, which asks for a password if I hadn't mentioned that yet. I entered the "j" password and boom, we're in! Alas, there were a couple other hiccups along the way. I needed to edit the fstab entry on the file server so the second hard drive would automatically mount on reboot. Here's the fstab entry for the second hard drive (actually, this entry below is a guess, I don't have my notes with me, but it's fairly close): /dev/hdb5 /media/file_server vfat rw,user,auto 0 0 I went to the /media directory and created the /media/file_server path: sudo mkdir file_server Made sure permissions and ownership were owned by the "ubuntu" user: sudo chown ubuntu:ubuntu /media/file_server Then I rebooted the file server to confirm the second hard drive automatically mounted and was accessible without having to type "sudo". After this was confirmed, we went back to the XP machine and entered the password and everything was hunky dorey. We were able to read and write to the file server's second hard drive. I think that's everything. Robert showed me how to assign a static IP to the file server, but stupid me didn't take notes, so he'll have to document how we did that. The SAMBA server has been placed under the workbench and the ethernet cable attached to it has been labeled "File Server" with a couple of strips of blue tape. That's so you know not to unplug that cable to use for other purposes. Or so you know to unplug it if you want to take the file server down. sean -- Mon, 30 Jul 2007 08:45:05 -0500
