Not just for DBAs: this is to remind anyone of syntax and options.

1.    Handy Solaris commands     HW config, swap, patches etc.
2.    Real-time performance monitoring     vmstat, iostat, mpstat etc.
3.    Unix Commands     find, awk, sed, grep etc.
4.    vi editor commands     the 22 most useful vi commands
5.    Unix file permissions explained      sounds basic, but you may learn something new here!
6.    The Solaris Name Service explained     how hostname and username lookups work

1. Handy Solaris commands

2. Real-time performance monitoring:

3. Unix Commands

other useful Unix commands for you to check out:

cut, paste , split

diff, sdiff, cmp, dircmp

head, tail, tail -f
id, groups

4. vi commands

The basic vi commands:
i insert before current character a append after current char
I insert at beginning of line A append after end of line
x delete current character X backspace-delete (deletes char to left)
dd delete current line
22dd delete 22 lines u undo the last thing you did
p paste those 22 lines below the current line
12yy copy 12 lines into the ‘clipboard’ for later pasting
<Esc> to get out of editing (insert/append) mode
:wq to save ('write') and quit (:q! to quit without writing)

vi moving-around Timesavers:

using h,j,k,l to move left,down,up and right is quicker than using the arrow keys (once you get used to it!).
w move one word forward b move back a word e go to end of word
Ctl-F move Forward a whole page Ctl-B move Back a page
0 (zero) go to beginning of line $ go to end of line
:242 go to line 242 Ctl-G see what line you are on

vi modifying things:
cw change word 3cw change 3 words C change to end-of-line
dw delete word D delete to end-of-line
cc replace current line with what you type next
r replace one character R endless replace (like over-typing)
o open/add a new line below the current one O open new line above current one
xp swap two characters (e.g. when you make a typo)
/bob search forward for 'bob' n repeat previous search ? search backwards

Probably the handiest vi command:
  .
  (dot) -repeat your last command

useful extra vi commands:
  ~    swap case of current character (capitalize or lower-case)
  Ctl-L    re-draw the screen (e.g when something from a background process writes to your screen and messes up your vi window)
  :set nu    show line numbers (:set nonu to remove line numbers)
  :set list    show hidden characters, line endings etc. (: set nolist)

Global replace:
     :%s/old/new/g  (% means all lines)
or     :g/old/s//new/g
or     :%s/old/new/gc  (c is to confirm each replacement, type ‘y’ to accept)

5. Unix file permissions

You probably already know the basics:
Each user in Unix belongs to at least one group, each file or directory on the system belongs to one user and one group. When you do an ls -l on a file you see what permissions the file owner, group owner and everyone else (‘world’ or ‘others’) have on it
  -rwxr-xr-- 1 robins  devteam 180 Mar 8 13:50 instbb
so on the file instbb there is full access (rwx- read,write,execute) for the owner (robins), read and execute for the group devteam and read-only for everyone else.

What you may not know is that whether someone can delete that file is not determined by the file permissions, but by the permissions of the directory the file is in :
  bash$ ls -al
  total 598
  drwxrwxr-x  3 robins  devteam 512 Mar 8 12:02 .
  drwxr-xr-x 24 root    wheel  1024 Mar 8 12:02 ..
  -rwxr-xr--  1 robins  devteam 180 Mar 8 13:50 instbb
In this case the directory (.) is group writeable, which means anyone in the group devteam can delete the file instbb. Although they can’t modify it, they could copy it to a new file in that directory, modify it, then delete the original and rename the new file as instbb. So the file isn’t as secure as it may appear..

6. Solaris Name services

Solaris provides a mechanism for getting hostnames and usernames etc from several sources (e.g DNS, NIS, or the traditional /etc/hosts file) : the file /etc/nsswitch.conf , which may contain
  hosts: files dns
this means that when you try to access a remote host by name (e.g. ping neptune) it will look for neptune first in /etc/hosts, then do an lookup in DNS (nslookup using the server specified in /etc/resolv.conf)

Similarly for usernames, you may have
  passwd: files nis
So when you run a command which refers to a username (e.g. cd ~oracle ) , it first looks in /etc/passwd then does a lookup in NIS (ypmatch oracle passwd).

However you can look up hosts and users without worrying about where they are stored, using the getent command :
  bash$ getent passwd oracle
  oracle:##oracle:3008:5001:Oracle DBA:/export/home/oracle:/usr/local/bin/bash
  bash$ getent hosts www.inkq.com
  192.168.245.12 www.inkq.com
  bash$ getent hosts 10.0.0.91
  10.0.0.91 plop.inkq.com plop mailhost