articles on

WebTech #1 Introduction to servers

Hello everyone, this post will be a very basic introduction, as a lot of designers are new to the world of servers. In my tutorials, I will use a VPS as my platform, however you can use the same commands for a dedicated server. Also, we assume you know what Linux, Apache, PHP, MySQL, and such names are. Whats a VPS anyways? def: A VPS a method of partitioning a physical server computer into multiple servers such that each has the appearance and capabilities of running on its own dedicated machine. (wikipedia) So basically, a VPS is a ‘division’ of a bigger server, and it fits as a great solution for designers and developers because of the cost involved in such a service. However, a VPS is the next step from entry level-’shared’ hosting and expensive dedicated servers. Accessing your VPS From Windows: Once you have ordered a VPS and your OS is installed, you need to connect to your server. You will have at least 1 IP address for your server, and SSH is enabled by default. SSH is a secure connection system that basically gives you a command line on your server. Firstly, we need to download PuTTY from their website - Once done, double click on the downloaded putty.exe: In the Host Name enter the IP address of your VPS, port 22 is the default port, unless you change it for security - we’ll talk about security later. From Mac or Linux From Mac you need to open your terminal (also in linux). In mac you can find it under Finder -> Application -> Utilities -> Terminal. Once you’re running it is should look like this: Then type at the prompt ssh root@10.10.x.x (replace the 10.10.x.x with you IP & use your password on the prompt) Account Management Ok, you're now connected to your VPS. Let’s begin by setting up a few basics. Once you’re logged in, immediately change your root password. # passwd As you may know, for security reasons it’s not recommended to log in to your VPS using the root account. We only logged in with root this one time to do the initial setup. With that in mind, let’s create a user we will be using instead of root from now on. Choose your own name instead of poweruser. # adduser poweruser Now we must give the poweruser account some administrative rights. Before we can do that though, it may be necessary to install sudo onto your VPS. # apt-get install sudo Sudo stands for super user do and it enables a regular user such as poweruser to run administrative tasks that would typically be available only to root. To enable sudo for the new user, let’s look at the /etc/sudoers file and give our new user super user privileges. # nano /etc/sudoers Add to the end of file: poweruser ALL=(ALL) ALL You should now be able to log in with your new account and use sudo to perform administrative tasks. When you run a command using sudo, you will be asked for the root password. Updating the base system We are now ready to update our VPS. Let’s start by updating the list of packages available to us. # sudo apt-get update Updating works by looking at a list of repositories located in /etc/apt/sources.list. If you plan to install 3rd-party or non-standard software, you may wish to edit your sources.list with your favorite editor (I use nano). # sudo nano /etc/apt/sources.list To install the latest security updates and bug fixes, type the full upgrade commands: # sudo apt-get upgrade # sudo apt-get dist-upgrade After the first command you may be asked to set your timezone. If you are not you may now set it manually for your home location. # sudo ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime This creates a symbolic link from /etc/localtime to a file in /usr/share/zoneinfo corresponding with what zone you are in. Have a look in the directories under /usr/share/zoneinfo to see what timezones are available. Resource Checks Before we finish, we’ll run several system utilities to verify the resources on your VPS. Start by looking at the memory usage. # free –m You should see a table reporting your memory usage. Focus your attention on the second line, starting with -/+ buffers/cache. Under the used column, you will see how much memory applications on your VPS use. Above that you might see a higher number, but this is because it reports memory already used for buffers and cached. A more powerful command, top, shows how much processing power and memory is being used and for which running processes. # top –bn 1 This will run top in batch mode with one iteration, so that you get a nice and clean output of everything running. Keep in mind that running top with the -bn switches is like taking a snapshot, while running it without them would provide you an ongoing look at processor activity in real-time. Next, let’s take a look at disk usage: # df Df simply shows the amount of total and available disk space on a file system. Well, now your system is up to date, you have a new user account that can perform administrative tasks, and you are aware of the resources in your working environment. Whatever your choose to use it for, you should now be aware of how to take your VPS from a barebones system to something with a little more meat on it. At this point, we have covered alot of ground for your first server exploration day! Make sure to keep an eye on Abduzeedo, as we will be releasing the next Article on How to Setup Apache (webserver), PHP and MySQL! so you can start serving your websites.

Abducted by Web Technologies

Hello everyone, my name is Carlos Taborda, I’m an engineer/developer/designer and I’ve been abducted. :) I’m a friend of Fabio, and we thought bringing a little bit of programming/server articles would be helpful to all of you designers who want to learn to install and configure your servers (& VPS) and need to get your sites, blogs and applications up and running. What Subjects will you talk about? Since I have a mixed background, I will try to bring a little bit of everything from the three subjects (Servers, Code & Design). Here’s a list of things I’ve thought about. Servers: We’ll talk about, Getting a server up and running to serve sites and applications, ie, Apache, PHP, MySQL, Zend, Ruby on Rails, Django and Security. Code: I’m a Rails developer, and use it for my work every day, so i’ll be posting some basic Howto’s on how to get your first application going, as well as useful resources I find. Design: I’m not as a gifted designer as Fabio, but I have a good sense of design in applications, so i’ll share some Howto’s on how to create good ‘web-app’ templates, with CSS, Ajax, etc. I’ll also feature good Wordpress, Drupal and Joomla templates I run into. We need ideas! I would like to get ideas from you - our readers! What topics should we add, that would be useful for you in your web-design/developing journey.