Linux Process Tuning Made Easy: Understanding nice and renice
Vložit
- čas přidán 19. 06. 2024
- The Linux Crash Course series here on Learn Linux TV teaches you a valuable Linux-related skill in each and every video. You can watch most episodes in any order, and with over 60 entries in this series (and counting) there's no shortage of Linux Learning! In this episode, Jay will teach you some of the basics of tuning Linux processes with the nice and renice commands.
Thanks to Akamai for sponsoring this video!
Support Learn Linux TV by spinning up your own Linux server on their cloud platform ➜ learnlinux.link/akamai
Brand LPI Linux Essentials Course Available
Check out the new course on Udemy! ➜ learnlinux.link/lpi-course
➜ learnlinux.link/lpi-course
Check out the Linux Shop
In the official shop, you'll find Shirts, hats, stickers, bags and more!
➜ merch.learnlinux.tv
5% discount on LPI exam vouchers
After you finish Jay's new course, get 5% off an LPI exam voucher here:
➜ learnlinux.link/lpi-voucher
Become a Patron
Show your support for Learn Linux TV on Patreon and get access to exclusive perks!
➜ learnlinux.link/patron
Become a Channel Member
Show your support for Learn Linux TV here on CZcams and get access to exclusive perks!
➜ learnlinux.link/member
Mastering Ubuntu Server: 4th Edition
Jay's latest book covers everything you need to know in order to master Ubuntu Server. It's available here:
➜ ubuntuserverbook.com
Linux Gear and Kits
Check out Jay's choice of hardware products, audio/video equipment, and more.
➜ learnlinux.link/amazon
Grab an awesome Pi-powered KVM
Support Learn Linux TV and grab yourself a TinyPilot KVM here:
➜ learnlinux.link/tinypilot
Note: Royalties and/or commission is earned from each of the above links
Time Codes
00:00 - Intro
01:16 - Set up your own Linux server with Akamai! (Sponsor)
02:38 - Quick refresher on the ps command
03:42 - Understanding the output of the ps command
04:50 - Making sense of "niceness" values
07:13 - Example of changing the priority of a process in Linux
10:49 - Further exploring the renice command
12:22 - Setting process priority with the nice command
13:59 - Another key difference between the nice and renice commands
Full Courses from Learn Linux TV
• Linux Crash Course series ➜ linux.video/cc
• Learn how to exit use tmux ➜ linux.video/tmux
• Learn how to use vim ➜ linux.video/vim
• Bash Scripting Series ➜ linux.video/bash
• Proxmox VE Cluster Full Course ➜ linux.video/pve
• Learn Ansible ➜ linux.video/ansible
Linux-related Podcasts
• Enterprise Linux Security ➜ enterpriselinuxsecurity.show
• The Homelab Show ➜ thehomelab.show
Learn Linux TV on the Web
• Main site ➜ www.learnlinux.tv
• Community ➜ community.learnlinux.tv
• Enterprise Linux Security Podcast ➜ enterpriselinuxsecurity.show
• The Homelab Show Podcast ➜ thehomelab.show
• Content Ethics ➜ www.learnlinux.tv/content-ethics
• Request Assistance ➜ www.learnlinux.tv/request-ass...
Disclaimer
Learn Linux TV provides technical content that will hopefully be helpful to you and teach you something new. However, this content is provided without any warranty (expressed or implied). Learn Linux TV is not responsible for any damages that may arise from any use of this content. The person viewing Learn Linux TV's content is expected to follow their best judgement and to make their best decisions while working with any related technology. Always make sure you have written permission before working with any infrastructure. Also, be sure that you're compliant with all company rules, change control procedures, and local laws.
#CloudComputing #DevOps #Linux - Věda a technologie
Seriously this channel is the best. The amount of free knowledge available is wild.
Thanks Jay!!!
I'm a huge admirer of Jay; I've been watching his videos since I began learning Linux. Thank you!
Great video! I would’ve loved a quick explanation on what process priority means in practice, and what its “niceness” means, though, before going into the “hows”.
I appreciate the video. However, as beginners we need practical examples on when to do this, lower or higher.
thanks Jay, great video :)
Great vid really helpful
Thanks a lot. Your videos are very interesting and easy to learn. Request you to add more videos on BASH scripts and LXD.
....and a happy new year!
Jay, can you make a video on why and how to track different logs files to diagnose different things? Thank you.
you are the best in linux OS administration
Outstanding video and great description of nice and renice. It's very confusing the way nice and priority values are counter-intuitive, but you presented it well so even I can understand.
Question - if I change the nice/priority of a process with sub-processes, will this change automatically for the sub-processes as well? Eg: I'm running Kdenlive and the rendering engine uses the process named "melt" with dozens of sub-process. Do I have to renice them all, or the the top one?
Very (re)nice!
Hi, i think it will be good to cover FRR (free range routing) as a topic for your channel.
Best regards
happy new year sir 🤍 from India
It would be nice to be able to adjust the priority of a vm (instead of a process) in proxmox..
Pretty sure nice doesn't go to to 20. You said that several times. -20 to +19. Those plots the zero in the middle make a nice round 40 levels.
Hi, what is the name of the terminal font in the video?
👍👍👍
❤❤❤❤
Nice shirt!!!
I take it that you missed my previous question, mate?
🎯 Key Takeaways for quick navigation:
00:01 🚀 *Introduction to Linux Crash Course Series*
- Introduction to the Linux Crash Course series on Learn Linux TV.
- Each video covers an important Linux-related concept.
- Emphasis on standalone videos for flexible learning.
02:29 💻 *Sponsor Message: Aami Connected Cloud*
- Aami Connected Cloud as an affordable, flexible, and reliable cloud provider.
- Quick setup of Linux servers with a variety of features.
- Marketplace with over 100 applications for easy deployment.
03:37 🔄 *Understanding Process Priority*
- Using the PS command to determine current process priorities.
- Explaining the priority and niess columns in the PS command output.
- Introduction to the concepts of niess values and process priority.
08:20 ⬆️ *Increasing Process Priority with "renice"*
- Using the "renice" command to increase the priority of a running process.
- Demonstrating how to change priority values and their impact.
- Highlighting the need for sudo when increasing process priority.
09:56 ⬇️ *Decreasing Process Priority with "renice"*
- Using the "renice" command to decrease the priority of a running process.
- Showing the impact of lowering the priority on process execution.
- Noting the absence of sudo when decreasing process priority.
11:49 🔄 *Alternative Syntax for "renice"*
- Highlighting differences in syntax between "nice" and "renice" commands.
- Demonstrating an example of setting process priority without using "-n."
- Emphasizing the need for consistency in command syntax.
13:10 ➕ *Setting Priority for New Processes with "nice"*
- Using the "nice" command to set priority for a new process.
- Launching Vim with a specified priority and examining the process.
- Contrasting the syntax of "nice" with "renice" for new processes.
14:34 🔄 *Syntax Variation: "nice" vs. "renice"*
- Discussing syntax differences between "nice" and "renice" commands.
- Demonstrating an example of using "nice" for launching a new process.
- Emphasizing the importance of using "-n" with "nice" for setting priority.
15:31 🎓 *Conclusion and Call to Action*
- Recap of the basics of setting process priority in Linux.
- Expressing gratitude for watching the Linux Crash Course series.
- Encouraging viewers to like, subscribe, and stay tuned for more content.
-
What are *some practical scenarios where adjusting process priority in Linux would be beneficial?*
How does *the concept of process priority discussed in the video relate to system performance optimization?*
Can you *provide examples of other Linux commands that are used for managing processes and system resources?*
Made with HARPA AI