W
W
WebDev2016-12-26 11:06:15
ubuntu
WebDev, 2016-12-26 11:06:15

Can I find out who entered what commands in linux?

If I'm rooted, can I see which user commands are being executed? For this I have to look at their .bash_history? Can a user clear their .bash_history file?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Erelecano Oioraen, 2016-12-26
@kirill-93

Linux is the kernel of the OS. Nobody enters any commands into the kernel.
To log commands entered in distributions of operating systems based on the Linux kernel, for example, in Ubuntu GNU / Linux, you can use logger, since the owner can easily edit ~/.bash_history as he pleases.

I
igor travov, 2016-12-26
@estj

in my .bashrc I always put alias hh="history", and I call this mine haha ​​to see the numbered history of my "clicks", and then, using !number, I repeat my clicks or just !number:p to just highlight and maybe . fix the command line (see mana on bash - on editing the command line - this was once introduced in sishel, but then transferred to bashel)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question