OS Linux Shell Practical

Note: If you are using Windows OS and not able to properly use Ubuntu on virtual box or VMware in you computer then alternative softwares are:

    WSL for Windows 10 or higher link
           or
     For older computer use Cygwin link

 

1. General Purpose & File system

        GENERAL-PURPOSE UTILITIES

            1. cal 

            2. date     

            3. echo 

            4. banner 

            5. bc 

            6. script 

            7. passwd

            8. who

            9. uname

            10. tty

            11. stty

            12. exit

            13. clear

        THE FILE SYSTEM

            1. pwd

            2. cd

            3. mkdir

            4. rmdir

            5. ls

2. Handling ordinary files and Process

HANDLING ORDINARY FILES

1. cat

2. cp

3. rm

4. mv

5. more

6. lp

7. file

8. wc

9. od

10. cmp

11. comm

12. Diff

THE PROCESS

1. Ps

2. kill

3. at

4. batch

5. time

              SIMPLE FILTERS

1. pr

2. head

3. tail

4. cut

5. paste

6. sort

7. uniq

8. tr

4. File attributes & FILTERS USING REGULAR EXPRESSION

FILTERS USING REGULAR EXPRESSION- GREP AND SED

1. grep
2. sed

3. egrep

4. fgrep

BASIC FILE ATTRIBUTES

1. chmod

2. chown

3. chgrp

5. Basic programming using shell script

1. Write a script to read four integer numbers from the user and find sum, product and average of these four numbers. link

2. Write a script to implement simple calculator, which can perform basic mathematical operations to implement using menu driven: link1_using_switchlink2_using_if

a. Addition

b. Subtraction

c. Multiplication

d. Division

3. Write a script to calculate gross salary. link

4. Write a script to find factorial of given number. link

5. Write a script to find max and min number from the data passed through command line. link

6. Shell programming based on use of loops

1. Write a script to calculate sum of series. 1+x+x^2+x^3+x^4 link

2. Write a script to find sum of any no. from command line argument. link

3. Write a script to print reverse string. link

4. Write a script to sum of digits of an entered number. link

5. Write a script to perform following string operation: link

a. Find length of string

b. Extract substring

c. Find location of any character

7. Shell programming based on control structure

1. Write a script to check given string is palindrome or not. link

2. Write a script to check whether a number is prime or not. link

3. Write a script to read a character from user. Determine whether it is uppercase letter, lower case letter or digit. link

4. Write a script to sort the given numbers in ascending order. link

5. Write a script to check whether the file is ordinary or not. link

8. Shell programming based on use of files & database 

1. Write shell script to manage(add/update/view/delete) Judge database with Fields: JudgeName, CourtName, City,Cases_ judged,TotalCasses : link

a. Display No of records

b. Find Judge with highest cases judged

c. Calculate total Cases of Court Ahmedabad

d. List All Judge Names

e. Exit

9. Shell programming based on file & database 

1. Write a Script for Simple LIBRARY Management System Operation. Database File Contains link

 Following Fields. AccNo, Title, Author, Edition, Publisher.

a. VIEW RECORD BASED ON QUERY

b. ADD RECORD

c. DELETE RECORD

d. COUNT TOTAL NUMBER OF RECORDS

e. EXIT