Gizmos Freeware Reviews  

Go Back   Gizmo's Freeware Forum > Freeware Forum > Linux

Reply
 
Thread Tools Display Modes
Old 30. Jun 2009, 04:46 AM   #1 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default Linux as a File Server

Many homes now have multiple computers connected together
via router/switch combinations creating small home networks.
These networks will almost always have at least one
MS Windows machine on it
(In my case 2, both of my daughters have laptops,
one w/ Vista and one w/ XP)
NOTE: my one daughter does VNC into the
Linuxbox to run Linux sessions quite often.

We also have 2 desktop machines running Linux,
one is used as the main desktop and the other
is used as a central file server among other things.

This allows me to easily manage storage, access permissions
and back-ups while allowing everyone to share files, pictures, videos, etc...

In order for the Linux server to communicate with the
Windows machines, it has to support the smb (Server Message Block)
protocol. Linux implements this by running the smb.d daemon
commonly known as a Samba server.

In my next post, I will demonstrate the installation and configuration
of the Samba Server (which comes with most every distro) as well as
setting it to automatically run on startup.

Got an older PC lying around, too slow for Vista,
install Linux and make it a file server.
__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 30. Jun 2009, 04:58 AM   #2 (permalink)
Senior Member
 
wdhpr's Avatar
 
Join Date: Sep 2008
Location: The north Coast
Posts: 1,513
Default I'm looking forward to this

If i dual boot to linux than this could be helpful.

What can be done that windows based network software can not? More specifically what does linux do out of the box...that shareware can do?

Cheers

Wdhpr
wdhpr is offline   Reply With Quote
Old 30. Jun 2009, 05:00 AM   #3 (permalink)
Senior Member
 
peter's Avatar
 
Join Date: Apr 2008
Location: Denmark
Posts: 478
Default

What's the advantage in doing this in Linux, rather than using Windows and eg. WinServer?
__________________
lets the music play the band ...
peter is offline   Reply With Quote
Old 30. Jun 2009, 05:47 PM   #4 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

The same function is obviously available using Windows shares,
in fact, by using Samba I'm actually emulating a Windows machine.

This is not a Linux vs. Windows debate, it's more like a "how to"
by using Linux.

This is the first in a series of post where I use a simple
Linux machine to accomplish various server tasks.
I plan to demonstrate a File Server,
Web / FTP Server,
Database Server,
Telnet / SSH Server,
VNC (virtual networking computing) server,
etc..., etc...
maybe even a streaming media server.

If you have additional suggestions, let me know.

I'll be posting the Samba details in the next couple of days.
__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 03. Jul 2009, 11:06 PM   #5 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default Samba

Here is a simple use of Samba on a Linuxbox (laptop in this case).

Hardware: Acer Aspire 5315
OS: openSUSE 11.1

In the following posts, I will configure Samba 2 different ways,
but in addition to these, you could always just manually edit the
/etc/samba/smb.conf file.

If Samba isn't already installed you have to install it via
package manager, source, etc... (I'm using Yast)



As you can see, I also installed the client utilities.
Now I'll configure using the Samba Server link in Network Services section shown.


Simple graphical setup


You would normally set up your Samba Server as the primary domain controller,
but in my case, I already have one (my existing Linux Server).

You will want this server to start-up during boot and you will also
need to poke a hole in your firewall.
__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 03. Jul 2009, 11:29 PM   #6 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

You will have to select a directory to share out.
I normally create a directory put it right under the /home

When an unknown user accesses this directory they
are mapped to a user called nobody, I personally
transfer ownership of the dir. to nobody (see permissions),
but that's not necessary. Keep in mind that the user nobody
has to have read/write rights.


Now we will use this share in configuration.


Your workgroup and domain controller settings will differ from mine.
The workgroup should match the name of your Windows Workgroup
and in your case is will most certainly be a domain controller.
I may even have to come back and adjust.
__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 03. Jul 2009, 11:54 PM   #7 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

Now we configure the Global Settings,
if you look at the samba config file, you will see this is the first section.
more /etc/samba/smb.conf

The first thing I change is security...
By default (and rightly so) access is granted based on the user
(this would be a Linux user account), you can duplicate accounts,
map users or just require Linux account logins, but I use this server
for central storage, it's behind a firewall and my router (NAT) so
I don't require a login. Each computer in the home network has a
permanent mapping to the storage. (we trust each other implicitly)

This allows me to set the security to SHARE. Users accessing the
storage are unknown which in turn are mapped to the user nobody and
carry the same rights as the user nobody and the user nobody has full rights
to the directory. (user security is better, but it depends on how your using it)




NOTE:
By using this client, I discovered that you couldn't see the Samba Share
by opening and scanning the network from the Windows side, so I added
browseable = Yes
to the bottom of the /etc/samba/smb.conf in the share section (see below).
__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 04. Jul 2009, 12:00 AM   #8 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

Now lets have a look...

__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 04. Jul 2009, 12:07 AM   #9 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

Now for the second, more universal way of setting up Samba.
We use SWAT, it's a web based configuration utility for Samba
which isn't tied to any particular Linux distribution.

We install Samba just the same, but we also install Apache and
of course mod-perl and mod-php5 while were at it









__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Old 04. Jul 2009, 12:18 AM   #10 (permalink)
Senior Member
 
debtboy's Avatar
 
Join Date: May 2009
Location: ~/
Posts: 128
Default

Now we want to start a few of these services we just installed.
I run chkconfig to see what's running (your distro command may differ).



Then I start up what I need:
Apache2
swat
and xinetd (xinetd should automatically turn on, but why take the chance).



Now I check to see if Apache is running, of course I needed to create a page
for testing.
Your local directory for webpages should be here by default:
/var/www/htdocs/index.html

__________________
[I][B]Linux, the choice of a GNU generation[/B][/I]
debtboy is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT +1. The time now is 09:00 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.