subject

Write a script that checks each minute and reports on who logs in and who logs out. you can follow the steps below (not the only way): 1. using the commands who and cut, extract the list of usernames currently logged in the system 2. to check after a minute, the sleep command can be used: sleep 60 3. get the new list of users logged in after a minute 4. for each user in the first list, check if he is in the second list using if and grep. you can dump the output of grep to /dev/null when using it in the as a test for the if statement if the user is not in the second list, print that the user has logged out a. b. 5. for each user in the second list, a. if he is in the first list, print that the user has logged in 6. 7. rename the second list as the first list repeat the process from step 2)

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 21:30
Felicia wants to become a head surgeon by december 2013. she designs the career milestones that she would need to complete her goal. by june 2013, she was not licensed. which best describes what she should do?
Answers: 2
question
Computers and Technology, 22.06.2019 15:20
The north and south regions had very diferent economies in the 1800s.
Answers: 1
question
Computers and Technology, 22.06.2019 18:00
What is the first view you place in your drawing?
Answers: 1
question
Computers and Technology, 22.06.2019 19:10
What a backup plan that you have created in a event you encounter a situation
Answers: 2
You know the right answer?
Write a script that checks each minute and reports on who logs in and who logs out. you can follow t...
Questions
question
Mathematics, 15.04.2021 14:00
question
English, 15.04.2021 14:00
question
Health, 15.04.2021 14:00
question
Social Studies, 15.04.2021 14:00
question
Mathematics, 15.04.2021 14:00
question
Chemistry, 15.04.2021 14:00