The snippet can be used in Bash and other shells that provide an alternative to the read command. This snippet prompts you to provide a pattern that it then uses for finding all active processes. ![]() Find all files created or modified within 30 days find -type f -mtime -30 Obtain disk usage and free space statistics du -ch List listening ports and owning processes netstat -tolpn Display kernel log sudo dmesg List all running processes ps auxw A snippet with a variable echo Enter the process name: & read process_name & ps aux | grep $process_name Instead of constantly searching or referencing a sheet for these things, snippets allow you to store this knowledge and save time in your daily server tasks.īelow are a few example snippets. There are many commands that you may run on a day-to-day basis that are either cumbersome to type (especially on a mobile device) or that are hard to remember. Tap and hold the name of the snippet, tap the top-right icon and then Share.Īlternatively, you can create a shared snippet (see 'Create a snippet'). Note: In the case of Bash, you can use & or to specify more than one command on a new line. For specifying several commands in a snippet, add each one of them on a new line. It will be treated as two separate characters, not an escape sequence. Note: Don't use \n in a snippet as it will not have an effect.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |