Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Coding done with Mu Python DoubleMega, the company that you work for, has three Linux servers: pallas, minerva, and athena. You are asked by the

image text in transcribed

image text in transcribed

image text in transcribed

Coding done with Mu Python DoubleMega, the company that you work for, has three Linux servers: pallas, minerva, and athena. You are asked by the system administrator to help them identify the differences between the servers. They need a program to compare the files on any two systems. Specifically, and given two systems, they are looking for the following differences: 1. What files are on the first system that are not on the second system? 2. What files are on the second system that are not on the first system? 3. What files are on both systems, but are different? 4. (And optionally), What files are on both systems, but have different filenames? To help you with this, the system administrator is providing you with a list of all files in directories that they are interested in (e.g. they did not include /home). They ran all of the files in those directories through a MD5 check-summing program called md5sum., and created one text file for each system with the following format: Each line represents one file on the system Each line is formatted into the following parts: o The MD5 sum o Two spaces The corresponding filename The files may have lines with incorrect Unicode characters, so on the open line, use something similar to: f = open(filename,encoding="utf-8, errors="ignore") For this project, they have requested the program to be written in Python, so that they may modify it later. You program should ask the user for the following three things: 1. The filename that represents the first system 2. The filename that represents the second system 3. A prefix to focus the search in (e.g. if the user types in /etc/init.d only results that start with that string are shown) The system administrators leave the output format up to you. Here is a sample section of one of the files: c258d6d2d8867a64e3165a68a043d51c /bin/plymouth b85108c33acbcb95e155a7d4e8710407 /bin/bzip2recover a 92529508lbleb65f164afeddd1d601a /bintfscmp 4160713df93c8efc0008db09f32c7cld /bin/dd f98f4108104b8976d7f12010245f3cc9 /bintfstruncate c165e7c36662e7bead943a852c59c8c1 /bin/btrfs-zero-log aea2dd251b84ca50adc30039fde 0635f /bin/chacl 28fa697d5642a79fdd8e0b17177395fa /bin/logincti ec76a0cfb97b5370ec9fa499a101323d /bin/btrfs-find-root 05e637245b2684c80cla9c76a 91 9d805 /bin/tailf Here is a sample run: >py -3 testi.py Enter filename for first system: pallas.list Enter filename for second system: athena.list Enter prefix to test: /sbin /sbin/brctl is not on system 2 /sbin/upstart-udev-bridge is not on system 1 /sbin/mount.nilfs2 is not on system 1 /sbin/mountall is not on system 1 /sbin/gdisk is not on system 1 /sbin/mkfs.nilfs2 is not on system 1 /sbin/mntctl is not on system 1 /sbin/upsd is not on system 1 /sbin/upstart-event-bridge is not on system 1 /sbin/mount.udisks2 is not on system 1 /sbin/upsdrvctl is not on system 1 /sbin/upsmon is not on system 1 /sbin/upstart-dbus-bridge is not on system 1 /sbin/upstart-socket-bridge is not on system i /sbin/prime-switch is not on system 1 /sbinilfs_cleanerd is not on system 1 Here is a sample run: >py -3 testi.py Enter filename for first system: pallas. list Enter filename for second system: athena.list Enter prefix to test: /sbin /sbin/brctl is not on system 2 /sbin/upstart-udev-bridge is not on system 1 /sbin/mount.nilfs2 is not on system 1 /sbin/mountall is not on system 1 /sbin/gdisk is not on system 1 /sbin/mkfs.nilfs2 is not on system 1 /sbin/mntctl is not on system 1 /sbin/upsd is not on system 1 /sbin/upstart-event-bridge is not on system i /sbin/umount. udisks2 is not on system 1 /sbin/upsdrvcti is not on system 1 /sbin/upsmon is not on system 1 /sbin/upstart-dbus-bridge is not on system 1 /sbin/upstart-socket-bridge is not on system 1 /sbin/prime-switch is not on system 1 /sbinilfs_cleanerd is not on system 1 /sbin/get-quirk-options is not on system 1 /sbin/umount.nilfs2 is not on system 1 /sbin/wpa_action is not on system 1 /sbin/upstart is not on system 1 /sbin/fixparts is not on system 1 /sbin/wpa_cli is not on system 1 /sbin/create-um-dev-node is not on system i /sbin/upstart-file-bridge is not on system 1 /sbin/prime-offload is not on system 1 /sbin/upstart-local-bridge is not on system 1 /sbin/sgdisk is not on system 1 /sbin/cgdisk is not on system 1 /sbin/wpa_supplicant is not on system 1 /sbin/initctl is not on system 1 /sbin/upssched is not on system 1

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Heikki Topi, Jeffrey A Hoffer, Ramesh Venkataraman

13th Edition

0134773659, 978-0134773650

More Books

Students also viewed these Databases questions

Question

Write Hund's rule?

Answered: 1 week ago

Question

What are the Five Phases of SDLC? Explain each briefly.

Answered: 1 week ago

Question

How can Change Control Procedures manage Project Creep?

Answered: 1 week ago