Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8446453
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T09:56:18+00:00 2026-06-10T09:56:18+00:00

I have linux server with 4 CPUs . I have mysql installed and i

  • 0

I have linux server with 4 CPUs. I have mysql installed and i have CPU-heavy tasks that run 24/7 in background. I there any advantages to use CPU affinity for every processes ? For example:

1 CPU = background task/daemon
2 CPU = background task/daemon
3 CPU = background task/daemon
4 CPU = mysql

Each background task eating up to 80% of CPU at any given time.

UPDATE:
My tasks are lxml parsers (python).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T09:56:19+00:00Added an answer on June 10, 2026 at 9:56 am

    I would take a look at what your processes are doing. If the scheduler keeps switching the tasks around onto different cores/CPUs, then you could see a performace gain by locking them to a particular core/CPU. The benefit comes from not having to do an expensive context switch between the two cores/CPUs each time.

    If you aren’t seeing this happening, then I don’t see the need to lock them to particular cores when the scheduler may see a need to shuffle them around.

    If you are looking for a more specific answer, it would behoove you to research what scheduler your Linux kernel is using and how it schedules processes. Once you understand how it schedules them, it may be beneficial to play with configurations/flags so that it plays nicely with all your background heavy tasks. Keep in mind though, if you do anything too extreme you face huge risks of starving processes/threads, extremely long run times, or just poor performance in general.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have installed native apache and mysql,php in my linux server. I tried a
We have a Linux server that has been running our MySQL 5.1 server. For
I have a server that is running Ubuntu Linux Server Edition. I once had
I have setup a git repository in a linux server, and installed the latest
I have mysql DB on cloud linux server. I am able to connect db
I have a linux server, where I just installed postfix. I have done nothing
I have a linux server running ubuntu 10.10 maverick with apache and php installed,
I have Linux server on which I run tomcat with my axis2 webservice. I
I have a Linux server with Perl libraries that I need to expose to
I have created a linux server using epoll. And I realized that the clients

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.