Everyday I discover a new linux terminal command to add to my toolbox. This is going to be a living list of linux terminal commands that I find useful on a regular basis that goes beyond the basics of
For adding and removing kernel modules. I used this a lot for enabling and disabling the file storage module on my hacked kindle.
modprobe -r g_file_storage
The file command tells what Linux thinks about the contents of the file. This is very helpful for firmware development and working with ARM processors.
hello_world: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), statically linked, with debug_info, not stripped
grep -i -r
Everyone knows the grep command, but using grep to find text within any file is pretty powerful. For example, say I want to find which file(s) contains “start on” in /etc/upstart
grep -i -r "emit start on" /etc/upstart
/etc/upstart/console.conf:start on started system /etc/upstart/ffsd.conf:start on langpicker_ready /etc/upstart/deviced.conf:start on started powerd /etc/upstart/lipcd.conf:start on started dbus /etc/upstart/scanner.conf:start on framework_rea
This is probably another one everyone knows. But I just want to document this because it has saved me so much time looking for a particular file system wide.
Find a file that contains “hello_world” in its file name:
find /home -name "*hello_world*" -print