Log Files and their Significance Flashcards

1
Q

Which logfile is the primary system log file which contains a wide variety of information about the system, including kernel messages, system error messages, and the startup messages of various services?

A

/var/log/syslog or /var/log/messages

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Which logfile records authentication logs, including successful and failed login attempts, and other authentication-related events?

A

/var/log/auth.log or /var/log/secure

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Which log file would you analyze to detect unauthorized access attempts or breaches?

A

/var/log/auth.log or /var/log/secure

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Which log file contains messages related to the system boot process and is useful for diagnosing issues related to the boot sequence and ensuring that all necessary services start correctly?

A

/var/log/boot.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Which log file holds messages related to kernel activities, such as hardware device status and driver messages and is valuable for troubleshooting hardware and driver issues?

A

/var/log/dmesg

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Which log file is dedicated to kernel logs and is useful for a deeper dive into kernel-specific messages and issues, separate from general system logs?

A

/var/log/kern.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Which log file records all cron job activities and helps in monitoring and troubleshooting scheduled tasks?

A

/var/log/cron.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Which log file maintains a log of failed login attempts and is useful for security analysis, especially in detecting potential brute-force or other unauthorized login attempts?

A

/var/log/faillog

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Which log file records all requests made to the Apache server?

A

/var/log/apache2/access.log

same with nginx, but the path is /var/log/nginx/access.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Which log file contains error messages, which are essential for troubleshooting web server issues?

A

/var/log/apache2/error.log

same with nginx, but the path is /var/log/nginx/error.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Which directory usually contains log files?

A

/var/log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Which log file would include logs like creation of a new group, a new user, and the addition of the user into different groups?

A

/var/log/auth.log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Which directory includes logs such as webserver, database, or file share server logs?

A

/var/log

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Where are the commands that are run on a Linux host using sudo logged?

A

/var/log/auth.log
<br/ >
~~~
/var/log/auth.log.1:Apr 17 21:04:29 Linux4n6 sudo: tryhackme : user NOT in sudoers ; TTY=pts/0 ; PWD=/home/tryhackme ; USER=root ; COMMAND=/usr/bin/apt-get install apache2
~~~

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Which log file stores logs for opened files in vim?

A

.viminfo in the home directory

command line history, search string history, etc. for the opened files

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What are the 3 log files that can be examined when searching for evidence of execution?

A
  • /var/log/auth.log for sudo commands
  • .bash_history
  • .viminfo
17
Q

What does .bash_history contain?

A

any commands other than the ones run using sudo