Linked by cloud on Sat 27th Oct 2012 01:05 UTC
Linux A new version of the real-time Linux scheduler called SCHED_DEADLINE has been released on the Linux Kernel Mailing List. For people who missed previous submissions, it consists of a new deadline-based CPU scheduler for the Linux kernel with bandwidth isolation (resource reservation) capabilities. It supports global/clustered multiprocessor scheduling through dynamic task migrations. This new version takes into account previous comments/suggestions and is aligned to the latest mainline kernel. A video about SCHED_DEADLINE is also available on YouTube.
Permalink for comment 540268
To read all comments associated with this story, please click here.
RE[2]: lie-nux at it again.
by Alfman on Sat 27th Oct 2012 18:30 UTC in reply to "RE: lie-nux at it again."
Alfman
Member since:
2011-01-28

Gullible Jones,

The OP's clearly trolling, but you post an interesting question.

"$ dd if=/dev/zero of=~/dumpfile bs=4G count=1"

I don't get your result, it says "invalid number" for any value over 2G, probably because it's using a 32bit signed int to represent the size (on a 32 bit system).

"Mind you, Windows is just as bad about this - it just doesn't have tools like dd preinstalled that can easily crash your computer."


My own opinion is that this is a case of garbage in, garbage out. dd is a powerful tool and was not designed to second guess what the user wanted to do. You've asked it to allocate a huge 4GB buffer, fill that buffer with data from one file, and then write it out to another. If it has enough ram (including swap?) to do that it *will* execute your request as commanded. If it does not have enough ram, it will fail, just as expected. It's not particularly efficient, but it is doing exactly what you asked it to do. Windows behaves the exact same way, which is the correct way.


You could use smaller buffers, or use a truncate command to create sparse files. Maybe we could argue that GNU tools are too complicated for normal people to use, but lets not forget that the unix command line is in the domain of power users, most of us don't really want our commands to be dumbed down.



"(If you don't have swap space, the command will fail because you don't have enough memory. But it's not safe to run without swap space... right?)"

I don't believe in swap ;)
Look at it this way, if a system with 2GB ram + 2GB swap is good enough, then a system with 4GB ram + 0 swap should also be good enough. I get that swap space is so cheap that one might as well use it "just in case" or to extend the life of an older system, but personally I prefer to upgrade the ram than rely on swap.

Edited 2012-10-27 18:38 UTC

Reply Parent Score: 3