1. Computing & Technology

Introduction to Linux

From Machtelt Garrels

 .forward
 mike@pandora.be
 

Using mail forwarding is also useful to prevent yourself from having to check several different mailboxes. You can make every address point to a central and easily accessible account.

You can ask your system administrator to define a forward for you in the local mail aliases file, like when an account is being closed but E-mail remains active for a while.

7.1.2.4. Save space with a link

When several users need access to the same file or program, when the original file name is too long or too difficult to remember, use a symbolic link instead of a separate copy for each user or purpose.

Multiple symbolic links may have different names, e.g. a link may be called monfichier in one user's directory, and mylink in another's. Multiple links (different names) to the same file may also occur in the same directory. This is often done in the /lib directory: when issuing the command

ls -l /lib

you will see that this directory is plenty of links pointing to the same files. These are created so that programs searching for one name would not get stuck, so they are pointed to the correct/current name of the libraries they need.

7.1.2.5. Limit file sizes

The shell contains a built-in command to limit file sizes, ulimit , which can also be used to display limitations on system resources:


   

 
cindy:~> ulimit -a
 core file size (blocks) 0
 data seg size (kbytes) unlimited
 file size (blocks) unlimited
 max locked memory (kbytes) unlimited
 max memory size (kbytes) unlimited
 open files 1024
 pipe size (512 bytes) 8
 stack size (kbytes) 8192
 cpu time (seconds) unlimited
 max user processes 512
 virtual memory (kbytes) unlimited
 

Cindy is not a developer and doesn't care about core dumps, which contain debugging information on a program. If you do want core dumps, you can set their size using the ulimit command. Read the Info pages on bash for a detailed explanation.

7.1.2.6. Compressed files

Compressed files are useful because they take less space on your hard disk. Another advantage is that it takes less bandwidth to send a compressed file over your network. A lot of files, such as the man pages, are stored in a compressed format on your system. Yet unpacking these to get a little bit of information and then having to compress them again is rather time-consuming. You don't want to unpack a man page, for instance, read about an option to a command and then compress the man page again. Most people will probably forget to clean up after they found the information they needed.

So we have tools that work on compressed files, by uncompressing them only in memory. The actual compressed file stays on your disk as it is. Most systems support zgrep , zcat , bzless and such to prevent unnecessary decompressing/compressing actions. See your system's binary directory and the Info pages.

See Chapter 9 for more on the actual compressing of files and examples on making archives.


   Prev    Home    Next
   Home sweet /home    Up    Your text environment

©2012 About.com. All rights reserved.

A part of The New York Times Company.