Ask Question, Ask an Expert

+1-415-315-9853

info@mywordsolution.com

Ask Operating System Expert

Overall requirements:

For this assignment, your task is to prepare a shell script named sysManage, which goes through the home directories in a Unix/Linux System and conducts the following menu operations:

a) List system users

b) List non­system users

c) Report on non­system user disk usage

d) [Testing Function] Generate 5 core files randomly in at least 3 normal users directories.

e) Detect and report core files in non­system user directories

f) Remove core files in non­system user directories

x) Exit

Detail explanation

1. Menu options

The shell script should generate a menu to allow the user to choose each option. After executing options 1­6, the script is expected to loop back to the Menu to allow further actions.

2. a) List system users

b) List non­system users

For above 2 options, your script should automatically look in the /etc/password file for system users and non­system users.

System users and non­system users are defined in /etc/login.defs file. In general, system users are users with UID less than 1000 and non­system users are users with UID between 1000 and 6000. Following is an ex

/etc/login.defs file.
# Min/max values for automatic uid selection in useradd
UID_MIN                  1000
UID_MAX                 60000
# System accounts
#SYS_UID_MIN              100
#SYS_UID_MAX              999

The output of the a) and b) should include {Total number of users, User Names}.

3. c) Report on non­system user disk usage

The output should contain the following information:

{Username, total_no_of_directories, total_number_of_files, total_size}

For this option, the script is expected to traverse through each user home directory specified in /etc/password file and report statistics of disk usage of each non­system user.

4. d) [Help Functions] Generate 5 core files randomly in at least 3 normal users directories.

e) Detect and report core files in non­system user directories

f) Remove core files in non­system user directories core files (program memory dumps) are created when a program terminates involuntarily in UNIX like systems.

The file name is always 'core'. It is preferred to clean out all of the core files in the system as they are waste of storage.

For option d), the script needs to generate 5 empty files with file name core randomly in at least 3 non­system users’ directories. For this option check the shell command touch. This is a help function for testing option e and f.

For option e), the script traverses through non­system users’ directories, locates core files and their absolute path. It needs to generate a report to the console.  The report format can be {non­system user name, core file with full absolute path, core file size, core file timestamp}.

For option f), the script removes the core file and prepare the action into a log.txt file in append mode. The script expects to generate deletion information of the log files and then prepare deletion information into a log.txt file. The format can be {timestamp of deletion, non­system user name, core file name with full absolute path, core file size, core file timestamp}

5.  x) Exit.
The script is expected to quit after user click x.

Operating System, Computer Science

  • Category:- Operating System
  • Reference No.:- M91679

Have any Question? 


Related Questions in Operating System

1 from this book you have learned a little about the

1. From this book, you have learned a little about the different file systems inWindows and Linux. To get a better handle on the differences between them, write a short memo describing three properties of each of these f ...

Foundations of informationsthere are so many operating

Foundations of Informations There are so many operating systems available in the market that it's difficult to decide which one is the best. Search the Internet for information on the following operating systems, and dra ...

One of the most useful tools you will use in your role as

One of the most useful tools you will use in your role as an Information Security professional is a hardening checklist. Essentially, it is a document that serves as a guide to configuring a desktop / system security. Pl ...

Operating systems assignmentprocessor schedulingprocessor

Operating Systems Assignment Processor Scheduling Processor scheduling is aimed to assign processes to be executed by the processor (or processors) in order to achieve certain operating system objectives, such as respons ...

Lab 1 develop system administration procedures for windows

Lab #1: Develop System Administration Procedures for Windows 8.1 Security Configuration Purpose: Develop systems administration procedures to implement systems security configuration guidance and best practices. Objectiv ...

As the system administrator you are always looking for ways

As the system administrator, you are always looking for ways to improve your network. Although there are many different types of operating systems, there are many versions of the operating systems, as well. After much re ...

Questionwhen designing a kernel with rudimentary

Question: When designing a kernel with rudimentary functionality, what are the required services? Justify your answer and provide an example. provide atleast 15 lines. do the best. need reference which is good.

Operating system assignmentpart onetopic- operating system

Operating System Assignment Part One Topic- Operating system support for mobile computing Submission Rquirements Project Proposal 1 page 1- Pages - 8 to 10 2- Power point slides 3-The project description document which e ...

1 the city of boston needs to be about 2 acres of green

1. The City of Boston needs to be about 2 acres of green space per 1,000 persons. You have been hired as the GIS expert by an independent consulting company to determine where the City is meeting this rule of thumb and w ...

Programming assignment lab schedulerdispatcheryou are to

Programming Assignment Lab: Scheduler/Dispatcher You are to implement a Scheduler in C, C++ and submit the source code, which we will compile and run. Both are to be delivered to the TA as source code through NYU Classes ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

WalMart Identification of theory and critical discussion

Drawing on the prescribed text and/or relevant academic literature, produce a paper which discusses the nature of group

Section onea in an atwood machine suppose two objects of

SECTION ONE (a) In an Atwood Machine, suppose two objects of unequal mass are hung vertically over a frictionless

Part 1you work in hr for a company that operates a factory

Part 1: You work in HR for a company that operates a factory manufacturing fiberglass. There are several hundred empl

Details on advanced accounting paperthis paper is intended

DETAILS ON ADVANCED ACCOUNTING PAPER This paper is intended for students to apply the theoretical knowledge around ac

Create a provider database and related reports and queries

Create a provider database and related reports and queries to capture contact information for potential PC component pro