Helpful Hints

If you would like to see something added to this page, please contact yergeau@gloworm.

If your question isn't answered by this page, check out the extensive collection of FAQs (frequently asked/answered questions) in /afs/ir/users/c/o/consult/pub/faq/ or at http://www.faqs.org/.

More resources are available on Solaris via the AnswerBook. If you are on an X server with Display PostScript (e.g. a Sun running CDE or OpenWindows), run answerbook.

Quick jump to

Misc.

WWW

Dangerous environment variables

The following environment variables should NEVER be set globally in a startup script (.cshrc or .login): Setting any of these environmental variables globally will likely break some other functioning application. Please note that both the /projects/cad/etc/DOT.cshrc and the /cad/local/tgroup.cshrc set one or more of the variables. If you source either/both of these files, you will eventually get screwed (and, if you moan to the gloworm cluster sysadmin about anything that breaks as a result, don't expect much sympathy).

If you have an application that needs any of these environment variables set, write a wrapper script to launch the application. If you don't know what a wrapper script is, ask action@gloworm.

FORTRAN Resources

Getting the best performance

Debugging

Programming with X

TeX/LaTeX/dvips

(Encapsulated) PostScript and other graphics formats

PDF

Most PostScript can be converted to PDF. There may be some quality issues and browseability issues. Tools to convert PostScript to PDF include If you are using PostScript from TeX/LaTeX/dvips, generate the PostScript using the Type1 (outline) fonts. Quality will be better and the size may be smaller.
          dvips -Ppdf file.dvi -o
      

Both Acrobat Reader (acroread) and gv can be used to view PDF. Acrobat reader tends to leave droppings in /var/tmp, so you may want to periodically clean up if you are a heavy Acrobat user.

When you print a PDF document, please print to PostScript first and check the size of the file. I've seen 500K PDF files grow to 50MB PostScript which clogs the printer queues. If the PostScript file is too large, only print a few pages at a time.

Who's using licensed software?

Useful obscure commands

Apologies in advance for any guru-speak in the following. You are encouraged to peruse the manpages for additional information.
top -- monitor top cpu usage
This command is useful for monitoring memory and CPU usage to help track down performance problems and runaway processes.
find -- search for files in a directory hierarchy
The syntax is find directory <list of predicates>. If a predicate succeeds, find tries the next predicate. A useful form is
           find . -name ,\* -print -exec /bin/rm {} \;
      
Note the use of the backslash to prevent the shell from expanding wildcard characters. For a full list of predicates, see the manpage.
ps -- process status
This command prints a list of processes running on the system. The most useful form is
           ps -ef | grep something
      
truss -- trace the system calls in a command
This is an essential command to figuring out why programs misbehave when you don't have the source code. It lets you see any external interaction for a running process. The drawback is that it generates lots of mostly useless output, but that can be skipped over with any search utility. The most useful form is
           truss -f -o /tmp/myprogram.truss myprogram arg1 arg2 ...
      
Then, have a look at /tmp/myprogram.truss. If you are using it to diagnose a crash, jump to the end and look backward for failed system calls (e.g. failure to open a file).

Stability

Although Unix has a much better uptime than other operating systems (e.g. Windows), some applications are not very robust. Applications that should be restarted regularly (daily or weekly) include: