Web file server - In which directory do you want to install

In which directory do you want to install ? If you enter the name of a valid directory, no further prompts are generated; otherwise, you are asked whether the directory should be created: The directory mydir does not exist. Create it (y/n)? [y] Here the default is to create the directory. You can modify the example slightly to provide a default directory as follows: promptRESPONSE “In which directory do you want to install” “$HOME” The prompt changes to look like the following: In which directory do you want to install ? [/home/ranga] Checking Disk Space Shell scripts are commonly used to keep system administrators up to date about the amount of free space available in certain directories. For example, you don’t want the incoming mail directory to fill up. An auxiliary task is to determine how much space a directory uses. For example, you don’t want a single user to hog up all the disk space for extended periods. The information about disk usage is also important to installation scripts because they need to warn a user when an installation is attempted in a directory that does not contain enough space. In this section, I will present two functions that can help you determine disk space usage: l getSpaceFree l getSpaceUsed Determining Free Space To determine the free space in a directory, you use the df -k ( k as in KB) command. Its output looks like the following: $ df -k Filesystem 1024-blocks Used Available Capacity Mounted on /dev/hda1 1190014 664661 463867 59% / /dev/hdd1 4128240 1578837 2335788 40% /internal /dev/hdb1 1521567 682186 760759 47% /store /dev/hda3 320086 72521 231034 24% /tmp When run on a single directory or file, the output looks like the following: $ df -k /home/ranga Filesystem 1024-blocks Used Available Capacity Mounted on
We recommend high quality webhost to host and run your jsp application: christian web host services.

Leave a Reply