Linux

The ‘logname’ Command In Linux



Become A Channel Member:

[ad_2]

source

Related Articles

36 Comments

  1. I like your channel. I am learning commands I never have used because it rarely gets mentioned in books and online articles. I have always used whoami, who and w.

  2. Urgent PSA for all Script-Kittys: First, be aware that Command Substitution $( ) will spawn a new process that cannot see Global Variables !!! …Second, using the for-loop on a subset of files can be tricky because your argument cannot contain spaces: If you execute this on the command line with tab completion, then it'll become clear that you have to escape each space with backslash !!!

  3. The cmp command is my favorite Linux command: I use the cmp command to detect any incompatibility between different patches: cmp -l base hack1 | while IFS= read -r line; do set $line; cmp -l base hack2 | grep "$1" ; done

  4. The xxd command is my favorite Linux command: I use the xxd command to create & inspect binary files, as well as redirect its output to the diff & colordiff commands. You can also use xxd to remove the 16-byte iNes headers on NES ROMs.

  5. Is the 'log' in logname for logging or is it for logins?
    It would be useful to know which user invoked the command that deleted the database, even when the command is ran with sudo.

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button