Questions tagged [scheduling]
A technique for scheduling tasks to be run at a specific time or on a specific event.
420
questions
1
vote
1
answer
572
views
Why Write looks to be prioritized over Read in file system? (or vice versa)
I am checking whether the linux file system i/o scheduler prioritizes the write operation over the read operation. The linux version is 3.10.0-327.el7.x86_64
I performed the following experiments ...
1
vote
1
answer
284
views
Does a VM guest system runs only when the VM's process is scheduled on the host?
I'm working on preparing an enterprise software package for running on the cloud, but I'm facing the issue that the software package runs as a real-time process on our current deployments. No one is ...
1
vote
0
answers
278
views
Using cgroups to write a job scheduler
One problem with cron is that if there are more jobs that can reasonably be run at a certain time, cron doesn't care: it will happily spawn the jobs anyway resulting in poor performance for all of ...
1
vote
1
answer
417
views
Can the 0th physical core used asymmetrically on linux?
In an SMP and with a fair scheduling algorithm I'd expect all physical cores of a machine to get used evenly by linux. In theory I believe this is the case, but in practice I suspect not.
Does ...
2
votes
2
answers
2k
views
linux: Is there a way to dump the task run queue?
I'm facing a strange extreme load issue on idle conditions.
Is there a way to directly dump the linux process scheduler run queue?
E.g. when sar -q outputs 400 as runq-sz, to get those 400 PIDs?
ps,...
1
vote
0
answers
926
views
Set GRUB `elevator=deadline` scheduling to a single device
I'd like to set my secondary drive to deadline. Is it possible to do it via GRUB, but leaving the primary drive as cfq?
A script after booting would suffice in my case, but I'm interested in the GRUB ...
1
vote
2
answers
1k
views
What the heck is going on with my cron scheduler? (rsnapshot)
CRONTABS
I'm using rsnapshot with cron. Here's what sudo crontab -l shows me.
0 */4 * * * /usr/bin/rsnapshot hourly
30 3 * * * /usr/bin/rsnapshot daily
0 3 * * 1 ...
1
vote
0
answers
1k
views
Round Robin vs FIFO
recently I had to do some reports about scheduling processes in Linux, and to do so, we were asked to turn off all cpu except 0 to show how processes are running for cpu. But there is one thing which ...
6
votes
1
answer
75
views
Does linux stops processing related to GUI when we remove the desktop screen from connection from cabinet(CPU box)?
When there is big non interactive software running and if I required more processing power then, after removing the desktop screen does kernel stops processing related to GUI(graphical user interface) ...
1
vote
2
answers
118
views
Can making CPU-intensive processes lowest priority (19) have adverse effects?
When I make a CPU-intensive process lowest priority (niceness of 19), it seems the amount of real memory consumption goes up. Perhaps this has other causes.
But, can making CPU-intensive processes ...
4
votes
1
answer
889
views
Why is nice-level ignored? (Between different login sessions -- honoured if started from same session.)
When I start two CPU-eating processes with different nice-level, e.g.
Process 1:
nice -19 sh -c 'while true; do :; done'
Process 2:
sh -c 'while :; do true; done'
(I changed the order of : and ...
4
votes
1
answer
215
views
Process running in only one processor
I have a 40 v core machine in which a java process running. I can see that this process is running in cpu6 all the time.
$watch ps -o pid,psr,comm -p 4076
Every 2.0s: ps -o pid,psr,comm -p 4076 ...
0
votes
1
answer
1k
views
`cpulimit` and `nice` not effective in limiting the cpu usage of a python program that contains heavvy computations using theano
I am running a program written in python that makes heavy computations using theano.
As it is a very CPU-intensive program, it is disrupting all my other activies on my laptop.
For this reason I ...
-3
votes
1
answer
1k
views
Informatica job scheduling scripting in unix
There are 4 shell scripts:
Migrate a file from path-A to path-B (unix).
This script triggers one powercenter work flow.
This script triggers one IDQ job.
This script deletes the file from path-B (...
8
votes
3
answers
10k
views
How does Linux kernel find out which process to wake up during interrupt handling?
I was reading the book Linux Kernel Development on Chapter Process Scheduling. On Page 61, section Waking Up, the first paragraph reads:
Waking is handled via wake_up(), which wakes up all the ...
32
votes
3
answers
33k
views
Start/stop a systemd.service at specific times
I want to start and stop a systemd.service at specific times. Presumably I will use a .timer unit to start the job, but is there a built in way to stop the job after a specific duration, or at a ...
2
votes
2
answers
2k
views
How to setup an invisible cron job?
Is there a way to schedule a task using crontab by root user but should not be visible using crontab command i.e, crontab -l either for root user or normal users?
3
votes
3
answers
1k
views
Process scheduling data on linux
I am doing a project on OS and require the process scheduling data for an operating system. The data has to include the list of all processes in short-term-scheduler and long-term-scheduler along with ...
5
votes
2
answers
2k
views
Job queueing on a single machine
I have a shiny new server for running simulations on, with a pair of Tesla GPUs and 32 cores, running CentOS 7.2. I'd like for multiple users to be able to submit jobs to the server that get queued up ...
5
votes
1
answer
8k
views
Understanding Linux Perf sched-switch and context-switches
I've been trying to enable context switch events on perf and use perf script's dump from perf.data to investigate thread blocked time.
So far the only two recording options that seem to be helpful ...
2
votes
1
answer
3k
views
Cron Job Hourly Except Certain Time Frame on Friday
I want my cron job to run every hour, every day except Friday when I don't want it to run at all between the hours of 2am-9am (but hourly outside of this timeframe). Ideally, I'd like to have this in ...
0
votes
1
answer
194
views
nice command behavior when only 1 function running
I just learned the existence of nice (and ionice) which seems to be really interesting.
I just want to launch a process 'p_low' with less priority than my ususal one 'p_normal'.
What I was able to ...
0
votes
1
answer
535
views
Get PID of scheduled job (using at)?
Say I want to schedule this job to be run at later time
MYPROGRAM > output.out 2> error.err | at 02:00 PM Mon
How can I attain its PID? Surely using:
echo $!
will not work?
0
votes
1
answer
2k
views
Schedule a job to run in the background ( one time task scheduling using at )
Is it possible to request for a job to be run at a later specifed time in the background?
This is what I have so far,
nohup nice MY_PROGRAM > foo.out 2> foo.err < /dev/null | at 05:23 PM ...
3
votes
0
answers
631
views
System time in Minix with best precision
I'm working on a project to modify the scheduler in MINIX 3. So to test it I need to analyse the wait time and turnaround time. To calculate the wait time I'm storing the system time when the process ...
4
votes
2
answers
2k
views
How does the Linux scheduler determine if a process is I/O bound or CPU bound
Adding to this question, how does the scheduler determine if a process is I/O bound or CPU bound?
Mr. Love in this article, says
"schedulers often employ complex algorithms to determine the most ...
1
vote
0
answers
518
views
Process scheduling and core allocation on big.LITTLE CPUs
Recent ARM chips, like the Qualcomm Snapdragon 810, seem to be using a hybrid architecture called "big.LITTLE" with cores of different architectures and speeds combined into one CPU.
On a Linux (or ...
2
votes
1
answer
101
views
How to schedule task to run everyday, if I don't know when the pc will be turned on?
So, I could use the crontab command, with:
23 0 * ...
but at 23:00 my laptop can be turned off, or hibernated. In that case I want a command to be executed as soon as it will be possible. How can ...
-1
votes
1
answer
8k
views
Cron task scheduling and stopping after certain interval [closed]
I am managing a server which has multiple cron tasks, one of the crontab entry is like below:
51 */2 * * * /root/backup.sh
can anyone explain me what is happening here, at what time the script is ...
4
votes
1
answer
1k
views
Is "top" accounting for Kernel Interrupts?
I have a simple interrupt that is triggered by a GPIO-input. The IRQ only increments a variable and returns. When I turn the frequency of the interrupts up to somewhere around 10-20 kHz, the system ...
2
votes
1
answer
1k
views
Tuning Linux I/O Scheduler
I need a little help with properly tuning the Linux I/O Scheduler for spinning drives.
I have a process that writes data to a huge (4-16TB) memory mapped file and is using SHED_FIFO. The kernel then ...
4
votes
1
answer
3k
views
iotop and ionice -p show a different class/priority for the same process
After running
ionice -c2 -n7 <PID> on an I/O-intensive process (VirtualBox VM) and checking the result with ionice -p <PID> it shows best-effort: prio 7 which is expected.
But when ...
1
vote
3
answers
17k
views
Excluding specific date and time in cronjob
I am trying to schedule a cron job where the requirement is the job has to run every day, every month and every min and every hour EXCEPT 2nd and 4th sunday of every month from 1 to 3 AM.
Is there a ...
5
votes
1
answer
5k
views
cronjob at resume from suspend
using linux. I know you can do an @reboot cronjob. I want to do an equivalent thing but instead of running at reboot, running after my computer awakens from suspend. Is that possible?
4
votes
2
answers
2k
views
Run program x minutes after finishing
My question is kinda related to a cron job I think, but I'm not entirely sure.
Say I have a script (/home/me/myscript.sh) that does something, that can take an indeterminate amount of time to finish, ...
28
votes
2
answers
4k
views
Why does niceness range from -20 to 19?
The nice command allows you to adjust the scheduling priority ("niceness") of a program. On all Unix-like systems I've used, niceness is specified by a range of integers, where -20 is the most ...
1
vote
1
answer
1k
views
Python script works from terminal, but fails in scheduler, to write to external drive
I am trying to use a Python script to read/write from an external disk in linux, which works fine. The problem comes when I use a job scheduler to execute the Python program.
I am running all this on ...
0
votes
1
answer
981
views
Are blocked and blocked/suspend processes put into the same queue?
In a 7-state process model (new, ready, blocked, running, blocked/suspend, blocked/ready, exit), are processes in the blocked and blocked/suspend states for each event that processes are blocked on ...
6
votes
3
answers
3k
views
How can I verify `nice` is working?
Looking at different jobs running on a system with shared resources, it seems the nice values are being ignored. Many jobs with nice set at 19 are running at 100% cpu load while other many other jobs ...
1
vote
0
answers
972
views
How to set a process’s sched method to fifo and priority when cgroup are on?
I’m using CentOS 6.6, I want to set the sched method of my kvm VM to FIFO with priority 1.
First, I use chrt and get error:
chrt(): "failed to set pid XXX's policy"
I find here:
chrt(): "...
3
votes
1
answer
930
views
Why does Linux scheduler have locks for run queues?
Why does Linux Kernel Scheduler code have locks for run queues? Does the scheduler spawn kernel threads, and locks are to prevent two of such threads to avoid modifying run queues at the same time?
1
vote
1
answer
626
views
Why doesn't the Linux kernel prioritize interactive programs?
I've noticed that when running at 100%, things like GNOME become less responsive until I kill background tasks that are expected to take a long time, like compilation or downloading email. Why doesn'...
1
vote
1
answer
330
views
Why have the notion of 'nice'?
I know what 'nice' is and how it maps to priority, this is not the question.
Linux priorities range from 0-139. 0-99 is real time, 100-139 is user space.
Nice maps onto priority:
-20 → 100
0 → 120
...
0
votes
1
answer
256
views
Midi and Scheduler on Linux / Raspberry Pi
I'm fairly new to MIDI and Linux. I have an Akai MPX8 with a bunch of individual WAV files loaded onto it. The WAV files play well over the existing audio system. The audio files are launched by ...
0
votes
0
answers
266
views
CPU Scheduling incredibly slow with large difference between total execution time and actual CPU time - Ubuntu Full-Disk Encryption enabled
Admittedly, I am running on a build that is no younger than five years old at this point and the system is not going to be incredibly fast. However, at the same time, the run-times I am observing are ...
6
votes
1
answer
18k
views
How to schedule shutdown every day?
We have a server that is used for Linux thin clients in a class. The server is started when required and I want to schedule it to power off at 22:00 every day to avoid power wasting.
I thought of ...
5
votes
2
answers
9k
views
Why sudo user can use sched_setscheduler SCHED_RR while root can not?
I am running Arch Linux on a Raspberry Pi 2.
I have a user-space program that uses Gordon's wiringPi library and, in particular, the piHiPri() function that attempts to set the highest priority for ...
2
votes
3
answers
6k
views
how to tell crontab to execute the command from now instantly
I have a command in "/etc/crontab" which runs a database program every 7 days. Now, I see that this command has been commented by another user for 2 weeks. I immediately uncommented the line, and ...
0
votes
1
answer
318
views
How to skip email notification for at command in AIX?
(AIX 6.1 ) man page for at says -m option could send an email to the user. But this is the default behavior, even without specifying the -m option. Is there a way to turn this off, I do not want mails ...
4
votes
1
answer
3k
views
Relationship between IO scheduler and cpu/process scheduler?
The concepts of IO scheduler and CPU scheduler confuse me. Below are my understanding:
Linux uses CFS scheduler + nice values by default to schedule processes.
Each process has an IO queue.
There ...