MICROSOFT WINDOWS SERVER 2008:
Changing TCP/IP Settings:
- Control Panel -> Network and Sharing -> Manage network connections
- Properties -> IP Protocol Version 4
- Should only need the General tab, for IP, subnet mask, gateway, and DNS
server
Adding Roles:
- Go to Server Manager
- Click Add Role, and follow the wizard
Configuring DNS:
- Administrative Tools -> DNS
- Right click on your server and go through configuration wizard, supplying your domain name and subnet
info (don't do Active Directory integrated)
- Don't forget your forwarder!
Configuring IIS:
- Optionally rename Default Site, configure named servers if desired,
alter Document Root if necessary
- Default document root is C:\Inetpub\wwwroot\
Adding virtual hosts in IIS
- Right click Web Sites and add new website
- Follow the prompts, and define a Host header value for the web hostname
you want
- Don't forget you'd also need DNS entries
Using SSL
- In IIS Manager, go to your server then go to Server Certificates
- Click Create Self-Signed Certificate and fill in hostname
- Now go to the site you just made a certificate for and go to Bindings,
and add your SSL port with certificate
Configuring Basic Authentication
- Go to Server Manager, Roles, Web Server
- Add Role Services, and select Basic Authentication
- Go to IIS Manager, and go to your site
- Scroll down and click on Authentication
- Disabled Anonymous Authentication, and enable Basic Authentication
Your DNS not working?
- Check your TCP/IP settings first
- Make sure your DNS zones are correct, along with your forwarder
- Check something like www.google.com to make sure your DNS server and
forwarder is working
- Made changes but it still won't work? Start->Run->cmd and issue the
following command line: ipconfig /flushdns
UBUNTU LINUX:
Changing TCP/IP Settings:
- Right click on the Networking Icon at the top right of the screen (looks
a pair of power cords)
- Setup your wired connection Auto Eth0 with IP, subnet mask, gateway and
DNS server
For Installing Packages in General:
- Synaptic is your friend. System -> Administration -> Synaptic Package
Manager
- Right click on a package, select Mark for Installation, and let it
figure out the dependencies
- Forget which group a package is in? Just search by name
- Wanna fast track things? Go to Edit->Mark packages by task. From there
you can make your server a DNS and LAMP server and have almost everything
installed right away!
Configuring DNS:
- Go to webmin
- Servers -> BIND DNS server
- Create a forward zone, add a host record to that zone
- Create a reverse zone, add an address record to that zone
- Apply changes and restart DNS
Setting up Apache:
- Install apache2, php packages
- Go to webmin
- Servers -> Apache Webserver for configuration
- Your web pages should go in /var/www/html
Adding virtual hosts to Apache
- Go into Webmin, and go under Servers->Apache Webserver
- Click the Create New Virtual Server tab
- Set it to listen on any address
- Set it to listen on port 80
- Set it to listen for the server name (web hostname)
- Create and Apply changes
Using SSL
- Make a directory to hold your certs (i.e., /etc/apache2/certs)
- Navigate to that location, and make your keys and certificate
- Generate private key: sudo openssl genrsa -out server.key 1024
- Generate cert signing request: sudo openssl req -new -key server.key
-out server.csr
- Generate certificate: sudo openssl x509 -req -days 365 -in server.csr -signkey
server.key -out server.crt
- Now head to Webmin and the Apache config; go to Modules in Global Config
and turn SSL on
- Make a new Virtual Host that listens on any address, port 443, on the
name you want
- Go to that Virtual Host's options, into SSL options, turn on SSL, and
set the certificate and private key
- Apply changes to Apache
Configuring Basic Authentication
- Go into /etc/apache2
- Create a password file: sudo htpasswd -c .htpasswd username
- When prompted, set the password for username
- Go into Webmin, Servers->Apache, and click on the desired Virtual Host
- Scroll down to Per-Directory Options and click on your document root
- Select Basic Authentication for type, enter a Realm Name (make one up)
- Select Restrict access to all valid users
- Select your users text file (/etc/apache2/.htpasswd)
Hints on copying the test files:
- Once you download the zip file, double click to extract
- To copy, you need to open a terminal (under Accessories) and use the cp
command
- Syntax: cp source_file destination_file_with_path
- If you're copying to a location not owned by you (DOCUMENT ROOT HINT
HINT) make sure you use sudo so you have permissions
- Tip: when you first open a terminal, if you type cd Desktop
you'll be in the directory that show what is on your graphical desktop
Installing Webmin
- Go to www.webmin.com and download the Debian installer package
- Double click to install the package
- Open your browser to https://localhost:10000 and add a security
exception for the certificate
- Login with the username and password you use to login to the system