RE: bad RAM? prove it with a crash dump?

2010-05-06 Thread Nate Eldredge
th a large zip file that had 32 bytes of libc.so somewhere in the middle... :-( And of course, swapping out the RAM wouldn't have fixed it. -- Nate Eldredge n...@thatsmathematics.com ___ freebsd-hackers@freebsd.org mailing list http://lists.free

Re: Modifying ELF files

2010-04-08 Thread Nate Eldredge
rocess, it will continue to use the original version, which will be kept around (invisibly) until all mappings go away. This is what compilers, install(8), etc, normally do. Does your signfile program do anything with the target file before open(..., O_RDWR)? -- Nate Eldredge n...@that

Re: namei() returns EISDIR for "/" (Re: svn commit: r203990 - head/lib/libc/sys)

2010-03-01 Thread Nate Eldredge
x27;t suppposed to be able to find out whether or not the file exists. Obviously that doesn't apply in this case, because anyone is entitled to know that /proc is the root of a mounted filesystem, but it seems to me that it's a good habit to check permission first. -- Nate Eldredge n

RE: ntpd hangs under FBSD 8

2010-02-24 Thread Nate Eldredge
to all this trouble to build a debugging libc, you could just grep for select() and place breakpoints on all occurrences. (It might also be obvious from looking at them which one is the offender.) Also, since a system call is causing the trouble, you might learn something from truss or ktrace.

Re: NFS write corruption on 8.0-RELEASE

2010-02-12 Thread Nate Eldredge
ggy program that doesn't check return values from system calls or handles signals in a stupid way, I don't see how this can happen, and I'm not sure what the Sun man page is referring to. -- Nate Eldredge n...@thatsmathematics.com ___ fr

Re: ptrace bug or feature?

2010-01-17 Thread Nate Eldredge
On Sun, 17 Jan 2010, Kostik Belousov wrote: It may be a missed feature, not a bug. There is obvious hack value in ability to modify syscall arguments from the debugger. Do you know whether other operating systems allow this ? Linux does, I've used it. -- Nate Eldre

Re: Suggestion: rename "killall" to "fkill", but wait five years to phase the new name in

2009-12-22 Thread Nate Eldredge
On Tue, 22 Dec 2009, Craig Small wrote: I also agree with Daniel; why would anyone want to literally kill every process? AFAIK, it's a helper program for shutdown(8) (or shutdown(1M) as they call it) and isn't really intended to be useful otherwise. -- Nate

Re: Email sent from "at" command going to the wrong account

2009-12-14 Thread Nate Eldredge
confirms the above behavior: A log-in and out of another account makes getlogin() return that account's name, even though the shell has been closed and we are back to the original shell and the original user a. Is this the intended behavior? Any hints would be appreciated. -- Nate Eldr

Re: Superpages on amd64 FreeBSD 7.2-STABLE

2009-12-10 Thread Nate Eldredge
ssarily. In the fork() case, presumably copy-on-write is to blame for the fragmentation. In the vfork() case, there's no copy at all. -- Nate Eldredge n...@thatsmathematics.com ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/ma

Re: ucred when euid/egid

2009-11-29 Thread Nate Eldredge
program that opens the file and passes its fd over a unix socket. But then it's really becoming a hack. :) Caution: I haven't tested any of this. -- Nate Eldredge n...@thatsmathematics.com ___ freebsd-hackers@freebsd.org mailing list h

Re: [patch] burncd: honour for envar SPEED

2009-11-10 Thread Nate Eldredge
core dump will reveal the problem anyway. Having a library function "protect itself" in this manner is not actually helpful, IMHO. -- Nate Eldredge n...@thatsmathematics.com ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org

Re: help needed to fix contrib/ee crash/exit when receiving SIGWINCH

2009-10-22 Thread Nate Eldredge
o the prompt. Seems a good start might be to compile ncurses with -g, link ee against it, put a breakpoint on the SIGWINCH handler, and start single stepping... -- Nate Eldredge n...@thatsmathematics.com ___ freebsd-hackers@freebsd.org mailing list

Re: mmap(2) segaults with certain len values and MAP_ANON|MAP_FIXED

2009-10-20 Thread Nate Eldredge
27;t. You have a length that isn't a multiple of the page size and wraps around 32 bits. I bet you got an EINVAL, and the mmap call didn't actually do anything. is this a known problem? seems reproducible on all branches. Not a problem at all, I suspect. -- Nate

Re: Running a program through gdb without "interfering"

2009-10-09 Thread Nate Eldredge
one has a more clever idea, I'd love to hear it. This won't work. You can't debug setuid programs (for reasons which should be obvious). You could do it if you ran everything as root, but it sounds like the bug doesn't occur in that case. -- Nate Eldredge n...@thatsmat

Re: genuine cpu I386_CPU kernel support

2009-09-23 Thread Nate Eldredge
486 behavior to avoid having to do explicit access checks when copying to user space, though AFAIK it checks the CPU at boot time to decide if this can be done. I haven't checked whether FreeBSD uses this feature, but it would be another thing to watch out for. -- N

Re: genuine cpu I386_CPU kernel support

2009-09-22 Thread Nate Eldredge
support all the hardware you can stick into a machine with an 80386 CPU. Unless, of course, you plan to put it on a network. I doubt that 4.x is up to date with respect to security patches. -- Nate Eldredge n...@thatsmathematics.com ___ freebsd

Re: ZFS group ownership

2009-09-15 Thread Nate Eldredge
tting the sgid bit on the directory in question, e.g. "chmod g+s dir". Then new files will inherit their group from the directory. I suspect this will work on FreeBSD/ZFS too even though "chmod g+s" on a directory is undocumented.

Re: Intermittent system hangs on 7.2-RELEASE-p1

2009-08-26 Thread Nate Eldredge
ure.) If I remember correctly, disabling ACPI made it go away. So that might be something to try, if rebooting is an option. What are the similarities and differences in hardware and software among the affected machines (you mentioned there were several)? -- Nate Eldredge nel

Re: mmap/munmap with zero length

2009-07-04 Thread Nate Eldredge
org/onlinepubs/9699919799/functions/munmap.html "The munmap() function shall fail if: ... [EINVAL] The len argument is 0." -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/

Re: Why kernel kills processes that run out of memory instead of just failing memory allocation system calls?

2009-05-21 Thread Nate Eldredge
On Thu, 21 May 2009, Yuri wrote: Nate Eldredge wrote: Suppose we run this program on a machine with just over 1 GB of memory. The fork() should give the child a private "copy" of the 1 GB buffer, by setting it to copy-on-write. In principle, after the fork(), the child might want

Re: Why kernel kills processes that run out of memory instead of just failing memory allocation system calls?

2009-05-21 Thread Nate Eldredge
On Thu, 21 May 2009, per...@pluto.rain.com wrote: Nate Eldredge wrote: With overcommit, we pretend to give the child a writable private copy of the buffer, in hopes that it won't actually use more of it than we can fulfill with physical memory. I am about 99% sure that the issue inv

Re: Why kernel kills processes that run out of memory instead of just failing memory allocation system calls?

2009-05-21 Thread Nate Eldredge
f you are paranoid, or run programs that you know will gracefully handle running out of memory. IMHO for general use it is better to have overcommit, but I know there are those who disagree. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Re: C99: Suggestions for style(9)

2009-04-28 Thread Nate Eldredge
e corner cases that real programs are unlikely to encounter. In particular, the features Christoph proposes to use work fine. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/l

Re: Bug in tcp wrappers?

2009-03-15 Thread Nate Eldredge
with something like glibc's getline(3), that uses realloc to size a buffer appropriately. If nobody else feels like doing this, maybe I will. -- Nate Eldredge neldre...@math.ucsd.edu___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.o

Re: Debugging init process.

2009-03-10 Thread Nate Eldredge
. Alternatively, there's always "printf debugging". What is wrong with init, that you need to debug it? It's a fairly simple program that's been around for a long time and should be pretty stable. -- Nate Eldredge neldre...@math.ucsd.edu __

Re: Spin down HDD after disk sync or before power off

2009-03-05 Thread Nate Eldredge
r system in a dual-boot setup.) There's no way that FreeBSD could send it a power-down sequence, but the BIOS could. Perhaps the OP's BIOS for some reason doesn't do this correctly. -- Nate Eldredge neldre...@math.ucsd.edu ___ fre

Re: ln: posixly confused

2009-03-03 Thread Nate Eldredge
es". Therefore, I think it's a fair interpretation to say that a symbolic link to an existing directory "names" it. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.o

portupgrade spurious skips

2009-02-26 Thread Nate Eldredge
has ideas about how to construct a reasonable test case that could help me make this reproducible and easier to investigate. Any thoughts? Thanks in advance. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http:/

Re: shmmax tops out at 2G?

2009-02-24 Thread Nate Eldredge
you need (unsigned) long. -- Nate Eldredge neldre...@math.ucsd.edu___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Re: pahole - Finding holes in kernel structs

2009-02-12 Thread Nate Eldredge
a structure that already does this. Most places in the kernel, I don't think either of these would be true. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-

Re: Kernel Module - GCC Requires memmove

2009-01-21 Thread Nate Eldredge
e for these functions. I vaguely recall Linux having a policy that compiling the kernel without optimization was not supported, possibly because of situations like this. -- Nate Eldredge neldre...@math.ucsd.edu ___ freebsd-hackers@freebsd.org ma

Re: gcc 4.3.2 libgcc_s.so exception handling broken?

2009-01-17 Thread Nate Eldredge
is as simple as possible. If you can do it with C++ rather than Ada it might be easier, so people don't have to install the Ada compiler. Also please mention the commands you use to compile, and what they output when you compile using -v, and what architecture you are on. -- Na

Re: Confused by segfault with legitimate call to strerror(3) on amd64 / sysctl (3) setting `odd' errno's

2009-01-16 Thread Nate Eldredge
ng statements is correct? #include #include execl("/bin/sh", "/bin/sh", 0); execl("/bin/sh", "/bin/sh", NULL); -- Nate Eldredge neldre...@math.ucsd.edu___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Re: lzo2 shows insane speed gap

2008-12-29 Thread Nate Eldredge
t;fast" and "slow" machines (CPU, amount of memory, load on the machine, kernel version, disk, etc). If the copied binary isn't faster than the natively produced one, then it would be good to have information about the compiler options, versions, etc. -- Nate Eldredge

Re: AMD64 qemu completely broken?

2008-12-07 Thread Nate Eldredge
On Sun, 7 Dec 2008, Juergen Lock wrote: On Thu, Dec 04, 2008 at 02:43:47PM -0800, Nate Eldredge wrote: On Thu, 4 Dec 2008, Juergen Lock wrote: I forgot to say the qemu-devel port (as well as the later snapshots I posted about on -emulation) also support -curses, which shows the emulated vga

Re: RFC: small syscons and kbd patch

2008-12-05 Thread Nate Eldredge
On Fri, 5 Dec 2008, Stephen Montgomery-Smith wrote: Nate Eldredge wrote: int bangbang(int x) { return !!x; } int ternary(int x) { return x ? 1 : 0; } Stylewise, I prefer int notzero(int x) { return x!=0; } icc -O0 compiles notzero the same as bangbang (better than ternary). tcc

Re: RFC: small syscons and kbd patch

2008-12-05 Thread Nate Eldredge
the Dow Jones Industrial Average on this coming Monday, December 8, 2008, is even, then style(9) shall be edited to indicate that `!!x' is preferred. If odd, then style(9) shall prefer `x ? 1 : 0'. :-) -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Re: AMD64 qemu completely broken?

2008-12-04 Thread Nate Eldredge
code in BSD's Net2, circa 1991. It is identified in a comment as a "quick hack" and adorned with several /* XXX */. Naturally the code and the comments survive intact, 17 years later. :-( -- Nate Eldredge [EMAIL PROTECTED] ___ fre

Re: tcsh loses the foreground process group?

2008-12-03 Thread Nate Eldredge
On Wed, 3 Dec 2008, Nate Eldredge wrote: Thanks for the report. It looks like this is yet another manifestation of a problem in tcsh, where it does inappropriate things in a vfork'ed subshell. In my tests, running tcsh with -F (which causes it to use fork instead of vfork) causes the pr

Re: tcsh loses the foreground process group?

2008-12-03 Thread Nate Eldredge
ropriate things after vfork (modifying global variables), or at least clean up before exiting, but IMHO that is less clean; vfork really shouldn't be used here at all. -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing

Re: [Testers wanted] /dev/console cleanups

2008-11-20 Thread Nate Eldredge
On Thu, 20 Nov 2008, Jeremy Chadwick wrote: On Wed, Nov 19, 2008 at 11:48:36PM -0800, Nate Eldredge wrote: On Wed, 19 Nov 2008, Jeremy Chadwick wrote: On Thu, Nov 20, 2008 at 05:39:36PM +1100, Peter Jeremy wrote: I hope that never gets committed - it will make debugging kernel problems

Re: [Testers wanted] /dev/console cleanups

2008-11-19 Thread Nate Eldredge
little tweaking of the init scripts at most. If you should have a crash and suspect there is useful data in the buffer, you can boot to single-user mode (avoiding the clear) and retrieve it manually. Seems like this should make everyone happy. -- Nate Eldredge [EMAIL PROTECTED

Re: How can I add new binaries to the mfsroot image?

2008-11-16 Thread Nate Eldredge
work in an interactive fixit shell but not during the automated sysinstall session? Wild guess: the shared libraries are present somewhere else on the CD, which perhaps is either not mounted or not pointed to by LD_LIBRARY_PATH or similar until the fixit shell is run. -- Nate Eldredge [EMAIL

Re: Unprivileged user can't set sticky bit on a file; why?

2008-11-14 Thread Nate Eldredge
On Fri, 14 Nov 2008, Volodymyr Kostyrko wrote: Nate Eldredge wrote: I came across this when trying to rsync some files which had the sticky bit set on the remote side. (It's the historical Unix archive from tuhs.org; the files in question are part of an unpacked V7 UNIX installation

Unprivileged user can't set sticky bit on a file; why?

2008-11-13 Thread Nate Eldredge
l as set the setgid bit on a file with a group that the * process is not a member of. Both of these are allowed in * jail(8). */ but does not explain why unprivileged process should be forbidden to set the sticky bit. -- Nate Eldredge [EMAIL PROTECTED]

Re: ukbd attachment and root mount

2008-11-12 Thread Nate Eldredge
where to start. I haven't been following this thread, and I'm pretty sleepy right now, so sorry if this is irrelevant, but I had a somewhat similar problem that was fixed by adding hint.atkbd.0.flags="0x1" to /boot/device.hints . -- N

Re: Asynchronous pipe I/O

2008-11-05 Thread Nate Eldredge
state = OK; } if (FD_ISSET(out_fd, &write_set)) { writer_state = write_one(out_fd); if (reader_state == WAIT) reader_state = OK; } /* Check for termination */ if (writer_state == GIVEUP) break; /* can't wr

Re: includes, configure, /usr/lib vs. /usr/local/lib, and linux coders

2008-10-31 Thread Nate Eldredge
in /usr/local/include which isn't searched by default. I find that behavior inconvenient, which is why I set those environment variables, so I don't have to think about it. -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebs

Re: memtest86+ can not link: binutils issue?

2008-10-31 Thread Nate Eldredge
don't know if it will fix your error but maybe it at least won't crash. ld crashing is definitely a bug, and it would be nice if you could file a PR, including the object files. If the GNU version doesn't crash that would be useful information for the PR also, as it might encoura

Re: neophyte: tcsetattr() gives 22 error in i386, not in amd64?

2008-10-24 Thread Nate Eldredge
no 22 is EINVAL, "Invalid argument". perror() is your friend. [snip code] -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Re: Why does adding /usr/lib32 to LD_LIBRARY_PATH break 64-bit binaries?

2008-10-23 Thread Nate Eldredge
, so having libutil.so there makes sense in my mind. I think your best bet is to dig into whatever is setting LD_LIBRARY_PATH and get it set correctly. Remove /usr/lib32 or at least ensure that /lib is searched first. Trying to change rtld's behavior is not the right approach, IMHO. --

Re: Laptop suggestions?

2008-10-22 Thread Nate Eldredge
ent interface. For instance, on the laptop pictured, holding Fn and pressing F6 would increase the screen brightness, probably without sending a keycode. A desktop machine would probably have a button on the monitor itself to do this. -- Nate Eldredge [EMAIL PROTECTED] __

Re: indicating a debug image

2008-10-16 Thread Nate Eldredge
duces #1. gcc without -g produces #2. gcc -g produces #3. You can distinguish #1 because 'nm image' will give no output. nm and objdump don't appear able to distinguish #2 and #3, but readelf -w will give a bunch of output for #3 and none for #2. Does that help? --

Re: Is it possible to recover from SEGV?

2008-10-11 Thread Nate Eldredge
else. There is also a libsigsegv which looks like it wraps some of this process in a less machine-specific way. Out of curiosity, what are you looking to achieve with this? And what architecture are you on? -- Nate Eldredge [EMAIL PROTECTED] ___ fr

Re: ZFS boot

2008-10-11 Thread Nate Eldredge
saved my machines data 4 times already (dieing hardware, unexpected power bounces, etc) Sure, but if my "new" machine isn't studly enough to run it, there's no hope for an old machine. So I'm trying to figure out what

Re: ZFS boot

2008-10-11 Thread Nate Eldredge
with 1 G of memory, which the page implies is insufficient. Is it really? -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Re: continuous backup solution for FreeBSD

2008-10-08 Thread Nate Eldredge
7;ve heard other people report data corruption. -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Re: Debugging reboot with Linux emulation

2008-08-13 Thread Nate Eldredge
ke a nasty bug, hopefully in the linuxolator. Indeed. -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Debugging reboot with Linux emulation

2008-08-12 Thread Nate Eldredge
I can do nothing except hit the power button. I do have hint.atkbd.0.flags="0x1" in /boot/device.hints. Unfortunately I don't have a PS/2 keyboard on hand, though I can try and get a hold of one if all else fails. -- Nate Eldre

Re: read with timeout ??

2008-08-08 Thread Nate Eldredge
er se, though if the underlying hardware device is interrupt-driven, that will be what (indirectly) triggers the wake-up. poll does seem to be more convenient than messing about with fd_set's. select is older and so it comes to my mind first, tha

Re: read with timeout ??

2008-08-07 Thread Nate Eldredge
that there's a function in FreeBSD's libc that makes that simple, but I forget the function name. If anyone can remember something like what I'm talking about, I sure would appreciate a function name. I can figure out how it works, if I could only dredge up that name. man 2 s

Re: General questions about virtual memory

2008-07-30 Thread Nate Eldredge
unction with the FreeBSD kernel source to see an actual example. I found this approach very instructive. -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsu

Re: consolekit on 7.0-STABLE i386

2008-07-30 Thread Nate Eldredge
just indicates where in the kernel it's sleeping. I don't understand what you mean by "high volumes in procs-b". -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/

Re: SCHED_4BSD bad interactivity on 7.0 vs 6.3

2008-07-14 Thread Nate Eldredge
On Sun, 13 Jul 2008, Nate Eldredge wrote: On Sun, 13 Jul 2008, Kris Kennaway wrote: Nate Eldredge wrote: On Sun, 13 Jul 2008, Kris Kennaway wrote: Nate Eldredge wrote: Hi folks, Hopefully this is a good list for this topic. It seems like there has been a regression in interactivity from

Re: SCHED_4BSD bad interactivity on 7.0 vs 6.3

2008-07-13 Thread Nate Eldredge
On Sun, 13 Jul 2008, Kris Kennaway wrote: Nate Eldredge wrote: On Sun, 13 Jul 2008, Kris Kennaway wrote: Nate Eldredge wrote: Hi folks, Hopefully this is a good list for this topic. It seems like there has been a regression in interactivity from 6.3-RELEASE to 7.0-RELEASE when using the

Re: SCHED_4BSD bad interactivity on 7.0 vs 6.3

2008-07-13 Thread Nate Eldredge
On Sun, 13 Jul 2008, Kris Kennaway wrote: Nate Eldredge wrote: Hi folks, Hopefully this is a good list for this topic. It seems like there has been a regression in interactivity from 6.3-RELEASE to 7.0-RELEASE when using the SCHED_4BSD scheduler. After upgrading my single-cpu amd64 box

SCHED_4BSD bad interactivity on 7.0 vs 6.3

2008-07-12 Thread Nate Eldredge
ost people are still going to be using SCHED_4BSD. It used to be acceptable but now it isn't. Does anyone know why it's regressed so badly? -- Nate Eldredge [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.