- Computers & Software»
- Computer How-Tos & Tutorials
LAMP server: Easy setup in a 5 minutes
What is DNS?
Dynamic Name Server is considered as name resolver. What it does is converting I.P address to more easy to remember address that is today commonly used in World Wide Web format.
(in example: instead of typing IP address of server:126.96.36.199, DNS server will convert to www.example.com).
Did you know?
DHCP server is assigning I.P addresses to the servers, and computers in internal servers as well as on Internet. Dynamic Host Configuration Protocol or DHCP shorten, is an scope of protocols allowing computers to "ask" and "get" unique I.P's for every PC on network from the DHCP server.
- So what it does is gaining automatically offered I.P address, and "find out" other crucial data such as router I.P, DNS Gateway, Sub-net Mask I.P, and so forth...
DHCP started to be used as protocol in 1993. It was more functional than it's previous "brother" called BOOTP.
DHCPv6, still not standardized, was introduced in July 2003. It's predicted that DHCP(v4) will be overloaded due huge increase of need for it; and DHCPv6 will be - then - standardized and widely used. Just as IPv4 and IPv6.
How does DHCP works?
Linux operating system as a platform for a server
Linux comes in various versions. Some of the most common ones are: Ubuntu, Red Hat, CentOS... This hub will teach you how to setup LAMP server on your own, without hiring IT specialist, engineers, or hiring freelancers to do it - without proper knowledge, experience or certifications...
- As Certificated System Administrator for IT Network Infrastructure; I feel that my experience of working on similar projects can highly contribute to many people that want to have their own internal or external server.
Internal server: this type of server would be server dedicated for employees in your company; having no gateway out to Internet. This type of server is really handy as it can host internal web-site, can do file exchange role, can be really handy when it comes to the point of share where System Administrators can manage what (and who, and even when) can make some document; or if server has Internet gateway (Hybrid server) then System Administrator(s) can even limit download speed, upload speed, put quotas on disk space usage, and many other useful things to audit what employees are working in your environment.
External server: this type of server is the most commonly one used, but without proper security it is the most common target of hackers and D(D)oS (Denial of Service) attacks.
LAMP external server could be accessed with via I.P address of server and/or trough registered domain connected trough DNS/ FqDNS sever role. Security is very important to the servers that are allowed to be accessed from Internet, that is: from outside of internal network.
For making your own server you need to know Computer Networking basics, at least, such as what are things like: Name Server (NS), Dynamic Name Server (DNS), Dynamic Host Configuration Protocol (DHCP), I.P (Internet Protocol), TCP/IP (Transimission Control Protocol over I.P) Multicast (traffic that transfers data in packages (with headers where destination I.P and the way the data should be transferred) and CRC (Cyclic Redundancy Check) on the end that checks if all data transferred is collected and put on "right place"( imagine puzzle and every piece of puzzle is one bit. CRC checks if all transferred bit's are on right place) while Broadcast data traffic used in audio or video streaming (commonly uses UDP protocol) do not check way of data collected and that's why you might see in Skype video conferences errors and mixed pixels on picture - for example.
Did you know?
Tapping DEL/Fn+F2 button will open up the BIOS (the "thing", combination of keys, that appears on splash screen at the start-up of your PC/Laptop saying:" Press ____ key to enter setup ". That key, or that combination of keys at that sentence, or similar one, is the one that leads you into BIOS (Basic Input Output System).
On bottom of the screen, every BIOS will give you additional info on "How to Use" and what to press for which function. For instance, on bottom of screen, you will even found keys for navigation trough BIOS and changing "values".
Installation on physical or dedicated (remote) server
Installation of Linux OS on server should be hard if you have done installation of Windows. It's practically the same thing, except the fact that with Servers it's more recommended to install CLI version of server. CLI or Command Line Interface type of server is more scalable, and more secured type of server, leaving less "wholes" for potential hack-attacks.
To install Linux on your computer, you will need .ISO / virtual image / CD of the Linux version you're about to install. Let's say, you want install "Ubuntu" version of Linux.
Scenario 1: Installing Linux from CD
To install Linux Ubuntu from CD, you have to have a boot-able version of CD that contains setup. After getting it, you have to make some changes in BIOS. Depending on the version of BIOS, "boot" or "boot sequence" option is under different menu. But, in any case, by continuesly pressing (commonly) "DEL" button immediatelly after power-up/ reboot/ restart or on some laptops you need to press "Fn" (function key) and F2 button continuesly.
* See "Did you know" *
Now, when you are in BIOS go to "BOOT" options. Under "Boot Sequence" find first boot device. By default it's Hard-Disk (Primary). You will see, for example if your Hard-Drive manufacturer is "Western DigitalTM", you will see something like:
" 1. WD ModelAndEditionOfHD HD " <-- This is your HD
Below it, most commonly, you will see next thing in case that your CD/DVD drive is PhilipsTM:
" 2. Philips DVD/RW ModelAndEdition ... "
What you need to do is to switch 2nd with 1st. So that your primary (1.) boot device be the CD/DVD drive and secondary boot device (2.) is now primary. So, basically you just switch places, most commonly using keyboard, and most commonly "PageUp" (PgUp) or "U" key. (on some newer machines)
After doing this, put the CD/DVD in and press F10 (Save and Exit) and confirm. Press "Enter" on your keyboard on "O.K" or "Yes".
* See BIOS: Navigation (on right side) *
Now, after doing this, your PC will reboot/ restart. It will show splash screen: do nothing. When "Press any key to boot from CD ... " press ... Guess what? - Any key on keyboard.
NOW YOUR LINUX INSTALLATION IS STARTING. Just follow simple steps in Wizard and choose the right settings. Be aware that Linux demands totally different type of partition, so make an partition before starting installation... Or you can format your H.D partition (C:\ will be HD(0) D:\ will be HD(1) ...etc... ) you are AWARE OF THAT ALL DATA ON IT WILL BE ERASED!
OK... So you installed your Linux Ubuntu for very first time. Press CTRL+ALT+T to open the "Terminal".
At the terminal type:
[user@host#: su root
Press ENTER, and enter the ROOT password ( the one that you've been asked during the install of Linux)
After that you should see that your Security User (SU) is changed to: ROOT
Once there type:
[root@host$:sudo apt-get install lamp-server^]
Go smoothly over installation and whenever asked for password type the ROOT pass.
Scenario 2: Making LAMP server on dedicated
This is the most common scenario when it comes to companies and firms. So, what you get with renting dedicated Linux server is CLI interface on it, without anything. One of good sites to rent dedicated servers is www.server4you.net/ .
Now, once you're there, you have to log in. ROOT user is the user with the most privileges. Program to access your dedicated/ remote server/ for Linux - what I recommend is PuTTY.
Normally, you just type in I.P of the server and port 25... And whola! You're there. Type in root password, and you're there and ready to setup your very first LAMP server.
Watch my tutorial below and see how to do it yourself.