• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

Help me build an email/web server

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.

Krusty

Insane Overclocking Clown
Joined
Sep 17, 2001
Location
Orange County
I just realized recently that I'm a computer science major and have yet to dig into linux. So it's about time for me and I need your help.

My plan is to convert my old computer into a web server and email server. It's a pentium2 233Mhz with, I believe, an Intel 440BX motherboard, savage4 32MB graphics card, sound blaster AWE32, 1 2 gig drive, 1 8 gig drive, and 112MB of mixed ram.

I've already got my router set up so that I can host a web site and will shortly set it up so I can host an email server (and perhaps an ftp server --ooh, free web storage).

What I need from you guys is the optimal operating system to use. I'm 22 years old and have been pretty deep into computers for 14 years (yeah, since 8), so I'm not afraid of a command prompt. I just need very stable, very customizable,very secure, and very compatible. This server will be behind a router on a home network consisting of a couple windows 2000 computers and several windows XP computers so I would like to not have any real compatibility issues there. I have been told I need something called Samba to do that.

So, first of all, which OS should I use? Mandrake, RedHat, Lycoris, Lindows, old fashioned UNIX, a version of windows, or something else? Once I get a good common answer there, I'll download the proper OS and attempt to get started. Any tips for the installation process is welcome as well, but I will attempt to do a little searching for installation tips.
 
Well an easy distro to start out with that's pretty powerful is RedHat. I have one at work hosting a DNS/web server now. If you later want to get more hardcore go with Debian. Very customizable.

-DarkArctic
 
I would say to use redhat since it's easy and it makes a much better server than mandrake. I prefer debian, but as mentioned above you need to know what you're doing to accomplish anything.

The default smtp daemon on redhat is sendmail, which I find to be a nightmare to customize. I would recommend the first thing you do is replace it with Exim. The rest of the stuff (www/pop3/imap/etc) the redhat defaults work well. i like proftpd more than the default wuftpd, but wuftpd has gui tools in redhat so you might not want to switch.

I never put a gui on servers, especially ones that are lacking in power, but you will probably need one to use the config tools.

You might want to install the gui but not have it boot at start to save cpu/mem. Then when you need to configure something start it after you've logged in.
 
D'oh, I knew you guys were going to recommend red hat because my roommate just downloaded the *.isos for mandrake.

I just realised that my old computer has no ethernet card in it at the moment, so I'll need to make a run to my parents house to pick up my extra card. After that, I'll come back with tons of questions for you all.
 
I ran an Apache web server and it was pretty nice. I had IBM websphere but didn't like it. It's more for huge corp website rather than my JSPs and javabeans.

You can't go wrong with Apache. Simple to setup and configure.
 
I don't know what the install is like for mandrake, but I've used it and like it. Slackware is supposed to be pretty good from what I've heard. I use mostly RedHat though. Apache is great for a webserver, and I've been using PostFix for my mail server. It installed fairly easily and is simple enough if you don't care about pop-before-smtp or using smtp-auth modultes. Those take a bit of time and effort to configure.

You might want to check out webmin (www.webmin.com). it's a great web based GUI for administrating your server. Works on most flavors.
 
I have an old machine of similar power as yours, which I'm using as a Samba and FTP server. Its running a text only console of Slackware 8.1. However, Slackware does take some knowlegde for granted, so its usually best to stick with something a bit easier until you know more. I use Red Hat on the system in my sig, and it was my first linux distro. Its a good platform for learning the basics of linux without having to deal with too many configuration problems. I suggest you start with Red Hat or Mandrake, then once you know the ropes, switch over to Debian or Slackware. Considering you want a server, and the available hardware, I would not suggest installing a GUI once you're experienced.
 
Oops, one more thing I forgot. This server will be sitting next to my current computer and I thought it would greatly benefit me if I could also do some web browsing there to conserve monitor space on my main rig. I'm guessing a non-gui OS will not be able to do this, yes? How terrible will the system run if it has a gui? I'm only using this for at most 10 email addresses and my own miniature image hosting mostly.

Downloading redhat now. 6 hours to go. Wish me luck. I'll just be sittin here all night fixing up my area to accomodate a second computer.
 
There are non gui web browsers. Lynx and Links are what people typically use. I'm partial to Links myself.
 
I am now typing this on my nifty pentium2 computer running RedHat 7.3 courtesy of Mozilla being installed along with the OS. Soon to come is (hopefully) a pic of my little space here that I can host on my own computer!
 
Alright, having apache troubles now. Guess this is what happens when I don't know a darn thing about linux.

Once apache is functioning, you should be able to get to my puter via http://krusty.homeip.net:8080. Port 80 is currently being used by my roommate.

Anyways, I have found the apache configuration gui program (I'm using gnome) and have done all the setup I can think of on the 4 tabs in that program (main, virtual hosts, server, performance tuning) but apache does not seem to actually be running.

I'm going to start searching through the start-menu type thingie to see if there is an apache running program, but could use some help here. I have no linux books and an counting you guys as one of my primary learning resources.
 
Well, every time I've done a default redhat 7.x install I didn't have to do anything for apache to work, and you should be setting up the virtual host stuff in your dns.

Only thing I see you would need to change is the port it's running on, which can be done by editing /etc/httpd/conf/httpd.conf just look for where it says "port 80" on it's own line. In debian it's on line 274.

I don't like gui tools and I don't know how to use them, so I'm not sure what you set up.
 
Ok, what would be an enormous help is if I can figure out what ip has been assigned to my linux computer. I took what I think is the mac address for this computer and set it up to have a static ip behind the router and I set up the port forwarding for port 8080, but with the number of computers in my place and the weirdness of the router, I can't really be sure if I set up the correct computer with the correct settings.

I either need to find out what ip the linux box is on or I need to find out how to give the comptuer a name on the network. On a windows computer, I could give the computer a name easily enough and could find out my ip through ipconfig. On linux, I have no friggin clue.
 
Type in 'ifconfig' and that will give you the current address. You can also use this command to give your computer an IP address. I always have to look at the man pages to do this. Type in 'man ifconfig' and it will give you all the documentation you need.

-DarkArctic
 
DarkArctic said:
Type in 'ifconfig' and that will give you the current address. You can also use this command to give your computer an IP address. I always have to look at the man pages to do this. Type in 'man ifconfig' and it will give you all the documentation you need.

-DarkArctic

doh! I've tried ipconfig, ipconf, iconfig, iconf, ip, config, and a ton of other commands. WTF do they put an 'f' in there for?

I'll check it out as soon as the puter finishes doing updates.
 
It's IFconfig because it stands for InterFace Config. Mainly because it does more than just IP. It does all interfaces whether they're tcp/ip or not. So calling it IPconfig and you're using a non-ip based interface is pretty stupid.

If you want your computer to show up in your windows network browser you need to enable and configure samba. If you're talking about domain hostname then edit /etc/sysconfig/network
 
I haven't taken a pic of my new workstation setup in my new apartment, but here's an old pic from the "post your workstations" thread.

Let's see if I can show everyone an image off my hard drive;


olddesk.jpg



And now for one more question: how can I add and manipulate data in the /var/www/html/ directory without logging in as root? I had to log in as root to save this image to the proper directory for web hosting stuff.
 
Krusty said:
And now for one more question: how can I add and manipulate data in the /var/www/html/ directory without logging in as root? I had to log in as root to save this image to the proper directory for web hosting stuff.

Nice chair. :)

To quickly log on as root you can type in 'su' and then the root password. Or if you want to be bold you can browse to the directory and type in 'chmod -R 777 /var/www/html'. This will set the permissions so that everyone may read/write to /var/www/html and all it's subdirectories.

-DarkArctic
 
DarkArctic said:

Or if you want to be bold you can browse to the directory and type in 'chmod -R 777 /var/www/html'. This will set the permissions so that everyone may read/write to /var/www/html and all it's subdirectories.

sweet, thanks. Next step comes in PHP, SQL, and running an ftp server --but for now, I'm off to play video games.
 
ummm, Don't do chmod 777.

It's better to just add your user to the group that owns the files. Although I'm noticing that redhat is less secure about that stuff, what you should do is create a group like www-data, do a chown root.www-data to the files and do a chmod g+w <files> then add your user to the www-data group in the /erc/groups file
 
Back