Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Imagine the following: A corporate executive contacts you, the systems administr

ID: 3810450 • Letter: I

Question

Imagine the following:

A corporate executive contacts you, the systems administrator, to ask how your company performs file management and backups. Your response will be a description of how to manage the operating system's file system on your company's computers.

Write a 3–4 page description in which you detail the following:

Explain how to manage files and directories using operating system tools.

Explain the two approaches to managing files and folders. These ways include command line and Windows.

Describe how to configure file permissions. Discuss the different types of file permissions and how to change permissions via both command line and Windows.

Describe how to perform basic system operating system backup tasks. In your description, discuss two or more different ways to back up this company's computer syste

Explanation / Answer

UNIX is one of the mostly used operating system for servers and data backups by system administrators.

Virus, Trojans, malware enters the windows OS pretty easily which is not the case in unix(linux), which makes it one of the mostly used operating system for development purposes.

System administrators are entitled with precious task of backing up and managing files and directories on the system and backup from time to time so that it could be used in future.

Some of the best practices and tools used by the administrators are:

1.Tar utility

One of the most widely used utility to compress files and directories so as to reduce size and prevent from accidental deletion of data.

This is a very simple command line utility which backup files using below commands:

tar –cvpzf /backupdirectory/file.tar.gz /data/directory/path

used options could be summarized as below:

tar = Tape archive

c = Create

v = Verbose

p = Preserving files and directory permissions.

z = further to reduce the size of tar file.

f = It allows tar to get file name.

We could automate the script of tar using some bash script and run it whenever needed.

2.cron utility

To automate the whole task further, we could add cron utility to execute the backup process at pre-defined time without any human intervention for the backup process and log everything in file to check the success or failure of the activity.

We can use below commands to use the utility

# crontab –e

Example of sample command that could be used:

# M H DOM M DOW CMND

0113 * * 1,6 /bin/bash /backup.sh

      The above cron job will execute our backup script at 01:01:00 at every Monday and Saturday.

[Minutes     Hours Day of Month    Month                Day of Week      Command

0 to 59           0 to 23 1 to 31                    1 to 12 0 to 6                     Shell Command]

System administrator backups the data from server to another backup server in case of any mishaps like hard disk malfunction or any other natural hazard. For this, a backup is done on remote machine places at some other location to secure the data.

Administrator uses crontab utility to securely login and copy the data on remote machine using ssh utility.

Example: A script backup_remote.sh could be created with following commands to be executed by crontab:

!/bin/bash

HOST=10.10.10.10

USER=admin

PASSWORD=redhat

ftp -inv $HOST <<EOF

user $USER $PASSWORD

lcd /mybackupfolder

mput *.tar.gz

EOF

Linux operating systems are multiuser and to enable this, it has users and groups to make separation among types of users and permissions assigned to them. Unlike other operating systems, Linux allows multiple users to login in at a time. Permissions are primarily the “rights” to act on a file or directory.

The basic rights are read, write and execute.

We can view the permissions on a file by using “ls” utility

Example:

-rw -r- r-- 1 root root 1248 Jan 15 02:44 /etc/hosts

The first ten characters show the access permissions of a file.

The first dash (-) indicates the type of file (d for directory, s for special file, and - for a regular file).

The next three characters (rw-) define the owner’s permission to the file then next three for group and then three for other users logged into the system.

Administrator uses chmod command to allow permissions to specific users on files and directories.

Example: chmod 777 file1.sh -> this command will give all permission to this file. s (1+2+4)

Moreover, file ownership could be managed by “chwon” command utility.

“-R” command option could be used to recursively change ownership of subdirectories.

Ex: chown –R robin:hotel /data/smb1/

The best practices that every administrator follows are to give each user their own login to the system which protects unauthorized access other users files and folders.

Adding some users to particular group give them options to share some file among particular group of users like Human Resource department would like to share payroll related documents to Human Resource group users rather than to other external users.

There are various GUI user friendly tools that administrator uses for managing and controlling permissions to users.

Example: Eicel

This is free GNOME utility which gives administrator simple user interface to control the user permissions of files and folders and manage things effectively without worrying about long shell commands.

To individually change permission on a file, one could simply right click on the file and open as administrator. It will ask for password and then you could simply change the permissions as required.