1. ULIMIT - data segment, stack, resident set, etc.
I'm trying to figure out what some ULIMIT options do. I've learned
generally what most of the stuff is, but some options are still
confusing me.
The -d option sets the maximum data segment size. Now, from what I've
read, all that goes in there (using C programs as an example) would be
the global variables, right? (with a section of it for both
initialized and uninitialized variables) Now, I tried making a program
to test this, which would define a global char [10240]. Then I set
this option to 1 kilobyte, and my program ran fine. (I even had it
read/write to every char in the array, just to make sure nothing
screwy was going on) Shouldn't I get some sort of segmentation
fault/out of memory error?
Next, the -s option, which sets the maximum stack size. I think I have
this one pretty well figured out. In my test program, I defined a char
[10240] in main(), and I did get a segmentation fault when lowering
the maximum stack size below 12 KB. I'm not sure exactly why I needed
more than 11 (the only other thing that I would think would be in
there was my argc, argv, and an int used in main()) but I'm sure an
assembly programmer could tell me why. :)
I've got pretty much no idea what the maximum resident set (-m) option
does. All I can say is that it probably limits the total program's
memory usage. I guess that would include the text, data, and stack
segments? Is there anything else? But when I tried setting it to, say,
1 kb, with no swapfile, my programs would still run. I guess that that
means that if you run out of swapfile, it will use RAM no matter what
the limit is set at?
Finally, the -l option is for "the maximum size that may be locked
into memory." What is that? :)
2. magellan spacemouse XFree 4.01
3. loading executables into the data segment (poor man's exec)
4. Support for WinTV (ignore the 'Win' bit ;-)
5. Bruce's C Compiler Problem - No Data Segment
6. Apache users
7. addresses of shared objects' data segment
8. Linux Red Hat 6.0 and Solaris 7
9. Why can't I ping outside my segment SCO openserver
10. Why 'data subpacket too long' error?
11. Why can't I record data CD-RW's???
12. Why 'finger' returns old data?
13. why can't I set 'rw' permissions to my msdos partition?