Operating System - Linux
1827810 Members
1810 Online
109969 Solutions
New Discussion

setting up a server - recomendations

 
SOLVED
Go to solution
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Well its up and running with RH 9. All seems ok but there is still a lot to set up - but at least Im on my way.
(This is sent using RH9 on server)

Antony
John Collier
Esteemed Contributor

Re: setting up a server - recomendations

Antony,

I remember how happy I was when I was able to send my first post to a forum with my first newly-installed Linux system. Just thinking back on it gives me a smile still yet.

I wish I could assign points to YOU for this achievement, but this is your thread so you will have to settle for a big

CONGRATULATIONS!!!

It really wasn't as hard as you were afraid it would be, was it? Now you see why I personally suggest RH/FC when someone asks.

Now that we have the celebration out of the way, off to the more mundane configuration stuff...
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Thank you.
Its funny you should say that....

about 2 minutes before I received your message I managed to make my first foray into the land of samba and fouled it up - now I cant get access back into the samba window.
I guess I was trying to put the right (or wrong) info into the wrong place. I hope my understanding is correct localhost = name of computer localdomain = name of the network so for example - if I am using roger for name of computer and rabbit for name of network then localhost.localdomain would be roger.rabbit - and thats where things went wrong. I guess linux doesnt know yet that that is what I want to set it up as. So how do I get samba back? and how do I tell linux what the computer name is and how do I tell it the name of the network I want to connect it to?

Thanks again to all who are helping out - its good to know Im not alone :)
Antony
Yogeeraj_1
Honored Contributor

Re: setting up a server - recomendations

hi antony!
congratulations on your new linux server.

to set the hostname on the fly, you can try:
echo roger.rabbit.com > /proc/sys/kernel/hostname



hope this helps!

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Yogeeraj_1
Honored Contributor

Re: setting up a server - recomendations

hi again,
Concerning samba, it is configured in one single file, the smb.conf file. This file, located at /etc/samba/smb.conf, allows you to specify which resources on the linux machine you wish to share and who they can be accessed by.

A fresh installation of samba normally includes a sample smb.conf file. This file is completely commented, pointing out all of your available options, and how you can change them. However, samba is an extremely powerful tool, and most casual users have no need for 3/4 of the contents of this sample file.

Below a sample smb.conf file. If you wish to just share a few folders across a small home LAN, you might be better off basing your own smb.conf file, as opposed to the long-winded sample file.

[global]
workgroup = PUTIEVILLE
server string = My Lil Linux Box
hosts allow = 192.168. 127.
log file = /var/log/samba/%m.log
security = user
encrypt passwords = yes
smb passwd file = /etc/samba/smbpasswd
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

[Downloads]
comment = Downloads
path = /home/windisk/Downloads
browseable = yes
writable = yes
public = yes
read only = no

[homes]
comment = My Home Directory
browseable = yes
writable = yes
public = yes
read only = no

[printers]
path = /var/spool/samba
public = yes
guest ok = yes
printable = yes
browseable = yes
writable = yes
read only = no

hope this helps too!

kind regards,
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Alan_152
Honored Contributor

Re: setting up a server - recomendations

I'd like to recommend a few good books:

Linux for Dummies

Linux Administration for Dummies

Linux System Administration Handbook, by Nemeth et al

Unix System Administration Handbook, by Nemeth, et al

Samba for Dummies

Apache for Dummies (you can see I like Dummies books)

any of the numerous unix or linux college-level textbooks by Mark Sobell (I've read so many of his books that I've lost track).
John Collier
Esteemed Contributor

Re: setting up a server - recomendations

Antony,

I see that you and I have much in common. When I first got my Linux system up and running, I went straight to the graphical tools and thought that I would attack everything from there and the world would be a happy place.

I have learned much since then (although it is nothing compared to the amount of knowledge that most of the others here have FORGOTTEN about Linux) and it has become very obvious to me that there is nothing quite like getting directly into the command line and the particular configuration files for each thing you wish to accomplish.

You will soon notice that most of the information that you get here will be on how to manually change the config files, not how to use a graphical tool. I dare say that most of the Gurus here have probably never even seen the GUI tools for a large number of these processes and/or programs (although I could be mistaken).

I can't help but notice that you seem rather comfortable with the M$ OS. Keeping that in mind and knowing that you have now settled in on a RH based release, I might go out on a limb and suggest a book to you.

Linux Administration
A Beginner's Guide

Authors: Seven Graham
Steve Shah

http://books.mcgraw-hill.com/getbook.php?isbn=0072225629&template=osborne

I reference this one because it works from the assumption that the reader is already good with M$ and wants to know how to do many of the same things in Linux. It is a little out of date on the Linux versions, but it does focus primarily on Red Hat based systems.

I started off much the same way you did and I found this to be a very useful tool. Honestly, I still find myself turning back to it at times when I seem to have one of those world-class brain-farts and cannot seem to remember something simple..

As you get more proficient with Linux, there are many other books out there that you can graduate to, but I really think you would find this one to be a big help at this stage.

Just a thought.
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Thanks to both Alan and John. Its been a while since I had my head in any good books (non-fiction that is). Your both quite right of course its time to get some new books and as you both recomend one in particular thats a good place to start.

Oh By the way, I did get my server to see and be seen by 2 of my other pcs but I guess I did something daft again. The fun will be getting it back again.

I doubt I would have gotten this far without the support of everyone here so if Im quite for a while its because my head is in a book :) Thanks to everyone - but there will be many more questions Im sure.

Antony
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Hi,
well Ive ordered the book you recomended but I have a question or 2.
My web browser tells me I need to update mozila. Ive downloaded the appropriate file but I need to uninstall the present version first. How do I do this? And where do I find the files?
second When I reinstall it how do I ensure it goes back into the same place wher it originaly was?
Thanks
Antony
Yogeeraj_1
Honored Contributor

Re: setting up a server - recomendations

hi antony,

to uninstall Mozilla, you just have to:

a. Remove the mozilla1.0 directory where you installed Mozilla
b. Remove the ~/.mozilla directory, which contains profile information

and to install, you must proceed as follows:


a. Create a directory named mozilla1.x (mkdir mozilla1.x) and change to that directory (cd mozilla1.x).

and copy the installer package called mozilla-i686-pc-linux-gnu-1.x-installer.tar.gz) to the mozilla1.x directory

b. Change to where you downloaded the package (cd mozilla1.x) and decompress the archive file with the following command:

gunzip -dc moz*.tar.gz | tar -xvf -
(This places the installer in a sub-directory named mozilla-installer.)

c. Change to the mozilla-installer directory (cd mozilla-installer) and run the installer with the ./mozilla-installer command.

d. Follow the instructions in the install wizard for installing Mozilla

hope this helps too!

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Alan_152
Honored Contributor

Re: setting up a server - recomendations

You're using Red Hat, right? I would think that all you'd need to do is download the latest rpm for mozilla, and do an "rpm -Uvh " and that will do the uninstall via via upgrade for you. Otherwise, you'd have to find the original rpm, do an rpm uninstall, then do an rpm -Ivh on the new rpm for a full install of the new package.
John Collier
Esteemed Contributor

Re: setting up a server - recomendations

Antony,

I guess I have gotten soft these days. I know there are many ways to do things on these systems. Some easy, some hard, results usually pretty much the same.

One of the things I have learned to love about the RH distro is the RPM packages that go with it. The flexibility is very nice. If you wish to do it all manually then you are, of course, welcome to do so.

Personally, I have gotten to the point where I use an application called 'yum' to do most of my installs, updates, and even package removal. It requires some initial setup to make it work right, but once it is done your entire system can be brought up to the latest and greatest with a command as simple as:

yum -y update

If you are really set on using some kind of GUI to do things like this, there has been a package put out lately that works as a graphical front end to yum. Just do a quick I-net search on yumex and you should be able to find it fairly easily.

Prior to using yum, I even used Red Hat's very own up2date to keep the system, well, up to date. The nice thing about up2date is that it will install the needed public keys for you and you need to know little to get rolling with it. The drawback is that it seems a bit limited in what you can do.

I'm sure that this will not be the most popular answer you will get, but I still like the "work smarter not harder" approach.
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Hi all again
A couple of problems this morning.

1) First off I seem to have lost internet connection - when I put in the web address I get a message saying - the connection was refused when attempting to contact www....

2) Yesterday from the server - I could see all the workstations and the server public area I had set up. This morning I can only see the workstations (and access the data on them).

I am presuming these 2 items are connected - possibily along with the next item.

3) Yesterday I could see the server from the winxp workstation I was testing it with - but I could not access it. Though I can no longer see it this morning.

My presumption is that the server has a firewall running but I dont know how to find out or how to correct the problem. I have given both root and the user on the server access using smbpasswd. I have tried adding in a user in hosts for the address which is allocated to the workstation I am testing with but still no access.

4) when I could see the server on the network it had a weird name something like Unkown5a907 how do I change this into something more useful.

5) and last but not least is to do with the physical location of hardware. At present it goes as follows:
modem/router - directly to server and workstations.
Eventually I want the server to control the access of the workstations to the internet so am I correct in assuming it should be altered to:
modem/router - server - hub - workstations

I know its a long list but I am trying to solve as much as I can on my own. But I am very grateful to everyone here for your continous support. Hopefully that book will arrive on Monday.
Regards
Antony
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

I meant to mention - when Im on the server as a user - besides the home directory I can still see the public folders that I have set up even if I cant see the server on the network. Dont know if that helps or not.

Antony
Vitaly Karasik_1
Honored Contributor

Re: setting up a server - recomendations

3) iptables -L
will show firewall configuration
4) you can set server name in Samba using
netbios name = xxxxxx
in smbd.conf
5) yes, linux can be a gateway for your home network
see for example http://www.linuxhomenetworking.com/
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Hi folk,
Back again :) Well the server is now up and partially active on the network. Im hoping that someone can tell me the answer to make it fully active. Let me explain. First off i have switched to Fedora core 4 as this is the version that the book (that was recomended by John), uses. Ive steadily got used to the idea that for me at the moment a combination of using gui and terminal works ok. Anyway on to the problem.
From the server I can now see all my win boxes and access them without problem. The problem lies with seeing the server. I can see the icon for the server but I can not gain access to it - I believe its a permissions thing but cant see where or why. When I click on the icon I get the following message:
The folder contents could not be displayed. Sorry couldnt display all the contents of "Windows Network: server1". (where server1 is the name I gave to the server).
From my own xp box I can see all the network and I can access the server to see the shared folders. But here I also have a problem. When I try to open the folders I get the following message (its the same for each folder):
\\server1\server1 is not accessible. You might not have permission to access this network resource. Contact the administrator of this server to find out if you have access permissions. The network path was not found.

The message is the same for each of the 3 folders. I am logging into the server using a user account which I set up on the server.
Any thoughts? Ive checked the permissions and it tells me they are all read/write access for everyone. I am presuming that the problem is the same for both linux and xp since I cnat access from either.

Regards
antony
Vitaly Karasik_1
Honored Contributor

Re: setting up a server - recomendations

which "security level" did you configure for Samba? Is it "user"? "domain"?
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Hi,
security is set to user.
Thanks
Antony
Vitaly Karasik_1
Honored Contributor

Re: setting up a server - recomendations

I afraid, that for now all your users from MS Windows login as "guest" and this is a reason for access problem.
Can you send us your smb.conf file? (I'm very sorry if you already sent it and I just missed it - this is pretty long thread :-)

As quick&dirty workaround I suggest you to change "password encrypted" to "no" - with this setting your users will be able to access samba shares using their UNIX passwords.
as second step I suggest you to use "domain" as "security level" and join your samba linux box to MS Windows domain.
With "security level=user" and "password encryption = yes" we should create smbpassword file with samba passwords for *all* relevanty users. IMHO, it's not so smart way.
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Thanks Vitaly, this is indeed a steep learning curve, but progress is being made. Anyway here is the smb.conf

Antony


# Samba config file created using SWAT
# from 127.0.0.1 (127.0.0.1)
# Date: 2006/03/18 20:45:27

# Global parameters
[global]
workgroup = STARTREK
server string = Samba Server
username map = /etc/samba/smbusers
log file = /var/log/samba/%m.log
max log size = 50
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
printcap name = /etc/printcap
dns proxy = No
idmap uid = 16777216-33554431
idmap gid = 16777216-33554431
cups options = raw

[homes]
comment = Home Directories
read only = No
guest ok = Yes

[printers]
path = /var/spool/samba
read only = No
guest ok = Yes
printable = Yes
browseable = No

[Antony]
comment = test folder
path = /home/homes
read only = No
guest ok = Yes

[server1]
comment = test
path = /home/server1
read only = No
guest ok = Yes


Vitaly Karasik_1
Honored Contributor

Re: setting up a server - recomendations

so as first step I suggest you to add "encrypted password = no", restart sabma and try to connect using so UNIX user userrname/password.
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Tried that - no luck. I only have one user setup on the server at the moment besides root. Ive also set up same username on xp box with same password and cant access it from there either.
Antony
Vitaly Karasik_1
Honored Contributor

Re: setting up a server - recomendations

Oops! I forgot to say that for using "non-encrypted" Samba you should allow plain-text passwords in your MS Win clients (http://www.cs.unc.edu/help/network/problems/samba_passwords.html).
Of course, you understand, that this solution is not very elegant. The best way is join you Samba server to MS Windows domain - http://samba.org/samba/docs/man/Samba-HOWTO-Collection/domain-member.html#id2538850 or http://linuxgazette.net/105/price.html.

This is collection of Samba books/mans:
http://samba.org/samba/docs/
John Collier
Esteemed Contributor

Re: setting up a server - recomendations

Anthony,

Sorry to drag up an old thread, but I couldn't help but be a bit curious about the status of your project/experiment.

I notice that there have been no further questions from you on this for several months now. Does this mean that you have gotten your Linux box up and doing all the things you wanted it to do?

You are welcome to assign 0 (zero) points to this posting from me. I was just looking for a bit of closure on the issue if you don't mind.

Should I enjoy a cold adult beverage on your behalf in celebration?
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Antony Wright
Frequent Advisor

Re: setting up a server - recomendations

Hi John
Sorry about the delay in responding to you. Yes I did get linux up and running. It ran ok till quite recently when for no apparent reason it stopped connumicating with the rest of the network. I was unable to find a resolution to it as I had been through everything I could think of on both the server and the win xp boxes.
However Ive not given up experimenting. Just taken a different look at the problem for now.

Antony