Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ionice on windows #328

Closed
giampaolo opened this issue May 23, 2014 · 8 comments
Closed

ionice on windows #328

giampaolo opened this issue May 23, 2014 · 8 comments

Comments

@giampaolo
Copy link
Owner

From [email protected] on September 19, 2012 10:45:54

Proposal  
port get_ionice() set_ionice() to windows 7/vista 

Proposed API  
map calls to IoGetIoPriorityHint and IoSetIoPriorityHint 

Are there existent implementations we can use as an example?  
process lasso made me think of that. psutil based opensource multiplatform 
process lasso clone maybe? https://rubygems.org/gems/windows_ionice i found 
this on sf http://sourceforge.net/projects/iopriority/ 

Please provide any additional information below.  
http://msdn.microsoft.com/en-us/library/ff549710.aspx 
http://stackoverflow.com/questions/301290/how-can-i-o-priority-of-a-process-be-increased

Original issue: http://code.google.com/p/psutil/issues/detail?id=328

@giampaolo
Copy link
Owner Author

From g.rodola on September 19, 2012 16:58:08

Hi.
I'm not in Italy right now.
Are you willing to provide a patch?

Status: WaitingForReview
Labels: OpSys-Windows

@giampaolo
Copy link
Owner Author

From g.rodola on December 12, 2012 09:50:33

Ok, today I tried to spend some time on this and here's what I came up with.
It seems I'm able to get IO priority of a process but not to set it.
Not sure what's wrong with it.
Just attaching the patch for now.

Status: Started
Cc: [email protected]

Attachment: win_io_prio.patch

@giampaolo
Copy link
Owner Author

From [email protected] on December 12, 2012 18:20:36

In set_process_io_priority, instead of using handle_from_pid you need to use 
handle_from_pid_waccess with PROCESS_SET_INFORMATION.

@giampaolo
Copy link
Owner Author

From g.rodola on December 13, 2012 06:41:28

Thanks, it worked (although I had to use PROCESS_ALL_ACCESS).
Committed in r1555 .

Side note: I was able to set 2 (normal), 1 (low) and 0 (very low) but I wasn't 
able to use any other value. I noticed PH also provides an "high" value. What 
number is that mapped to?

Status: FixedInSVN
Labels: Milestone-0.6.2

@giampaolo
Copy link
Owner Author

From g.rodola on March 02, 2013 04:13:10

Updated csets after the SVN -> Mercurial migration: r1555 == revision 
c64779adec4f

@giampaolo
Copy link
Owner Author

From g.rodola on April 07, 2013 18:21:49

Status: FixedInHG

@giampaolo
Copy link
Owner Author

From g.rodola on April 11, 2013 02:17:39

Labels: -Milestone-0.6.2 Milestone-0.7.0

@giampaolo
Copy link
Owner Author

From g.rodola on April 12, 2013 11:21:26

Status: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant