Solaris 101

This guide gives you a quick introduction to the OpenSolaris environment, how to connect and work with your account using SSH, and a few basic commands you'll need to use your Zone.

A Bit About Solaris

Solaris is a UNIX operating system developed by Sun Microsystems. Renowned for its ability to scale to mainframe systems, its stability and maturity, and the introduction of a range of revolutionary features, Solaris is a perfect foundation for your website. A brief introduction is available at Wikipedia.

Connecting using SSH

SSH is a system where you can connect to a remote computer in a secure manner. It's effectively the same as if you were to sit down at the server with a keyboard and monitor. However, SSH only offers a text console, so you don't have the ability to use graphical user interfaces.

Despite this limitation, SSH provides a very effective means for connecting to your account, and is widely used for managing UNIX and Linux systems remotely.

Windows SSH

For basic SSH, we recommend the handy little tool PuTTY. Download the file putty.exe, save it somewhere handy, then double-click to open the program. You'll be presented with a screen like the following:

In the “Host name (or IP address)” field, enter the address of your zone. You'll then be prompted for your username and password. Once you've entered these successfully, you'll find yourself at your zone's command prompt!

Mac SSH

Mac users need to open the Terminal application (found at /Applications/Utilities/Terminal.app). You'll be presented with a console window, at which point you can enter the following on the terminal:

ssh username@zoneaddress

Make sure you replace 'username' with your username, and 'zoneaddress' with your zone's address, for example:

ssh jsmith@smithco.austin.net5.com.au

Linux/UNIX SSH

Accessing SSH from a Linux or UNIX is much like for the Mac above. You need to find your computer's terminal application, which, depending on your operating system, you might find under the “System Tools” menu or similar. Once you've found your terminal, enter the following:

ssh username@zoneaddress

Don't forget to replace 'username' and 'zoneaddress' with your correct values.

Navigating Around

Before you go anywhere, let's find out where we are. At the prompt, type

pwd

This tells you which directory you're currently in (the “present working directory”).

To change into a new directory, we use the cd command:

cd /etc

To go to your user's home directory, you can simply type:

cd ~

and you can access subdirectories in your home directory by:

cd ~/ruby

To make a new directory, you type

mkdir images

but be aware that this will create the directory in your current directory. To specify the exact location for the new directory, you can use the following:

mkdir -p /home/jsmith/site/images/icons

By using the ”-p” flag, we instruct the mkdir command to create all directories that don't exist — if the 'site' directory didn't exist and you didn't use ”-p”, you'll get an error message.

To remove an empty directory, use

rm images

but to do so, you need to remove everything from the directory first.

You can remove files by typing

rm image1.png image2.png *.jpg

This will remove image1.png and image2.png, as well as all files ending in .jpg from the current directory.

Common Commands

We're putting together a “cheat sheet” of commonly-used commands for you to use — see them at Solaris Cheat-Sheet.

All Done

Once you're finished with your SSH session, you can logout by typing

exit

or by simply closing your terminal or PuTTY window. Your zone will continue to run happily on our systems, and will be available next time you log in.

zones/solaris101.txt · Last modified: 2011/02/22 17:02 (external edit)
 
 
©2008 Net5 Pty Ltd. All rights reserved. Net5