Re: Who needs these silly statfs changes...

2003-11-15 Thread peter . edwards
(CC's trimmed, I'm sure I'm boring people at this stage.) Peter Edwards wrote: On Wed, Nov 12, 2003 at 06:04:00PM -0800, Kris Kennaway wrote: ...my sparc machine reports that my i386 nfs server has 15 exabytes of free space! [ ... ] The NFS protocols have unsigned fields where statfs has

Fwd: propgagate_priority() crashes: recursive msleep() ??

2003-11-14 Thread Peter Edwards
(Aplogies if this message is a duplicate: The original is AWOL for quite a while now) Hi, I'm getting a crash in propagate priority, as mentioned by a few people recently. Bug reports and comments about it seemed to have dropped off, so given that I can reliably reproduce it, I was trying to

Re: Who needs these silly statfs changes...

2003-11-14 Thread Peter Edwards
Bernd Walter wrote: On Thu, Nov 13, 2003 at 12:54:18AM -0800, Kris Kennaway wrote: On Thu, Nov 13, 2003 at 06:44:25PM +1100, Peter Jeremy wrote: On Wed, Nov 12, 2003 at 06:04:00PM -0800, Kris Kennaway wrote: ...my sparc machine reports that my i386 nfs server has 15 exabytes of

Re: Fwd: propgagate_priority() crashes: recursive msleep() ??

2003-11-14 Thread Peter Edwards
John Baldwin wrote: On 14-Nov-2003 Peter Edwards wrote: (Aplogies if this message is a duplicate: The original is AWOL for quite a while now) Hi, I'm getting a crash in propagate priority, as mentioned by a few people recently. Bug reports and comments about it seemed to have dropped off

Re: Who needs these silly statfs changes...

2003-11-14 Thread Peter Edwards
Bruce Evans wrote: On Fri, 14 Nov 2003, Peter Edwards wrote: Bernd Walter wrote: On Thu, Nov 13, 2003 at 12:54:18AM -0800, Kris Kennaway wrote: On Thu, Nov 13, 2003 at 06:44:25PM +1100, Peter Jeremy wrote: On Wed, Nov 12, 2003 at 06:04:00PM -0800, Kris Kennaway wrote: ...my sparc machine

Re: Who needs these silly statfs changes...

2003-11-14 Thread peter . edwards
On Fri, 14 Nov 2003, Peter Edwards wrote: Bruce Evans wrote: On Fri, 14 Nov 2003, Peter Edwards wrote: The NFS protocols have unsigned fields where statfs has signed equivalents: NFS can't represent negative available disk space ( Without the knowledge of the underlying filesystem

ATAPI-CD corruption since GEOMification ( possible fix)

2003-11-08 Thread Peter Edwards
-sectorsize; struct bio *bp2; - for (pos = 0; pos bp-bio_length; pos += bp-bio_length) { + for (pos = 0; pos bp-bio_length; pos += size) { if (!(bp2 = g_clone_bio(bp))) { bp-bio_error = ENOMEM; break; -- Peter Edwards

Bug: nmount(2) lacks parameter checking.

2003-11-04 Thread Peter Edwards
Hi, Looking over the code for nmount(), I think I noticed a few bugs. (tried send-pr, but the lack of a web-front-end at freebsd.org, and a decent mail system locally means that's not a runner) nmount() calls vfs_nmount() pretty much directly after copying in the io vector from userland.

RE: lockmgr panic on shutdown

2003-11-01 Thread peter . edwards
I can confirm the lockmgr panic on shutdown reported by someone else earlier (whose message I mistakenly deleted). It looks like swapper is trying to undo a lock from pagedaemon and runs into trouble. This is probably related to the Giant pushdown of vm_pageout() that alc did last week. I'm

RE: lockmgr panic on shutdown

2003-11-01 Thread peter . edwards
For giggles I'm rolling back vfs_default.c back to 1.87 since its along the backtrace path. This didn't work so -CURRENT is fully broke. I'd suggest staying on 10/30 not before 4PM PST if you want to not crash on shutdown. The patch worked for me. (Well, a slightly modified one: I passed 0

Re: Error assigning master socket: Too many open files

2003-10-22 Thread Peter Edwards
Andreas Klemm wrote: Hi, Urgend question, wanna help a collegue, who secured a router, but trying to scan ports fails with -current. I don't want to blame anybody, I know what the policy of current is. If I can't get quick help on this I use a Windows tool, no problem. I only want to save me the

Re: Text file busy

2003-09-15 Thread Peter Edwards
Terry Lambert wrote: Wesley Morgan wrote: It's also unfortunate that this protection does not seem to extend to libaries. I've had some in-use X libraries get overwritten with some very colorful results. So send patches. I did a year ago :-) See PR 37554. (Not the original patch, the

useful workaround and analysis of vnode-backed md deadlock

2003-09-10 Thread Peter Edwards
chunk of the running buf space is sitting queued for the md thread to process. The md thread can't continue without the vnode lock, so the running buffer space will not fall, and the bufdaemon cannot continue without running buffer space, so will never release the vnode lock. -- Peter Edwards

Re: 5.1, Data Corruption, Intel, Oh my! [patch] - Fatal trap 12

2003-08-14 Thread Peter Edwards
On Wed, 2003-08-13 at 07:38, Terry Lambert wrote: Peter Edwards wrote: ... He might also want to look for any function pointer that takes 5 arguments; Nice tactic, but misleading in this case, methinks. I assume your basing this on the 5 arguments shown in the backtrace. The 5

Re: 5.1, Data Corruption, Intel, Oh my! [patch] - Fatal trap 12

2003-08-14 Thread Peter Edwards
On Tue, 2003-08-12 at 12:52, Terry Lambert wrote: Bosko Milekic wrote: db trace _mtx_lock_flags(0,0,c07aa287,11e,c0c21aaa) at _mtx_lock_flags+0x43 vm_fault(c102f000,c000,2,0,c08205c0) at vm_fault+0x2b4 trap_pfault(c0c21b9e,0,c4d8,10,c4d8) at trap_pfault+0x152

Re: Crash in g_dev_strategy / CURRENT as of yesterday.

2003-08-14 Thread Peter Edwards
On Tue, 2003-08-12 at 20:39, Poul-Henning Kamp wrote: I'm not of a gdb wizard either, but I think you type up or down until you are at stack frame #12, and the simply say print *bp-b_dev This might help. The original stack trace had this: #10 0xc04f3c65 in trap (frame= {tf_fs =

Fun with gdb and threads...

2003-08-08 Thread Peter Edwards
Hi. This might be of interest to anyone who has tried debugging multi-threaded programs (of the libc_r variety) with gdb. This has been bugging me for months, and I finally got frustrated enough to find out what was going on. The symptom: Once you call any function that puts a thread to sleep,

Re: bge vlan stranges

2003-08-01 Thread Peter Edwards
Hm. A bit of a stab in the dark, but from sys/dev/bge/if_bge.c, line 3185 (on 5.1 release, 2399) /* Specify MTU. */ CSR_WRITE_4(sc, BGE_RX_MTU, ifp-if_mtu + ETHER_HDR_LEN + ETHER_CRC_LEN); Wonder if this should be /* Specify MTU. */

Re: bge vlan stranges

2003-08-01 Thread Peter Edwards
John Polstra [EMAIL PROTECTED] wrote: Peter Edwards [EMAIL PROTECTED] wrote: CSR_WRITE_4(sc, BGE_RX_MTU, ifp-if_mtu + ETHER_HDR_LEN + ETHER_CRC_LEN + ETHER_VLAN_ENCAP_LEN); Good guess, but the approved way of doing it is to add this code near the point where

Re: bge vlan stranges

2003-08-01 Thread Peter Edwards
John Polstra [EMAIL PROTECTED] wrote: No, you are right. I didn't read the posting carefully enough. Sorry! No problem. [snip] I assume you mean, that after setting if_hdrlen, [snip] I think you also have to set if_data.ifi_hdrlen as I said [snip] My fault: I jumped from one term for the

Re: bge vlan stranges

2003-08-01 Thread Peter Edwards
Ok. After all that, and given I've gone this far... Boris, does the patch included fix your problem? -- Peter Edwards. Index: sys/dev/bge/if_bge.c === RCS file: /pub/FreeBSD/development/FreeBSD-CVS/src/sys/dev/bge/if_bge.c,v

Re: NFS problem

2003-07-17 Thread Peter Edwards
Hi, All the files are 0-sized, dates are set back to the epoch and directories are seen as files. Exporting ufs2 filesystems works as expected. I've had problems like this exporting CDs via NFS to solaris. Sorry the details are murky, but if its the same problem, there's a work-around.

Re: imgact_gzip.c

2003-06-11 Thread Peter Edwards
On Sat, 2003-06-07 at 10:13, Poul-Henning Kamp wrote: In message [EMAIL PROTECTED], David Yeske writes: imgact_gzip.c seems to be pretty stale.  Has anyone considered fixing this?  If this were fixed then kldload() / linker_load_module() could deal with a gzipped .ko file, and gzipped elf

[resend] gdb, threads, and corefiles

2003-02-07 Thread Peter Edwards
Sorry if this appears twice: my webmail client appears to have dropped the original message on the floor. gdb didn't find threads in corefiles: The support was just missing. The attached patch does the job. Also attached is a small test program which easily generates a corefile with threads

/bin/ps buggette

2003-02-05 Thread Peter Edwards
, 0, CHAR, NULL, - 0}, {mwchan, MWCHAN, NULL, LJUST, mwchan, NULL, 6, 0, CHAR, NULL, 0}, {ni, , nice, 0, NULL, NULL, 0, 0, CHAR, NULL, 0}, {nice, NI, NULL, 0, kvar, NULL, 2, KOFF(ki_nice), CHAR, d, -- Peter Edwards. To Unsubscribe: send mail to [EMAIL

Re: Opening /dev/tty in session leader after controlling terminal is revoked causes panic.

2003-01-27 Thread Peter Edwards
[EMAIL PROTECTED] wrote: In message [EMAIL PROTECTED], Peter Edwards writes: The problem is in kern/tty_tty.c:ctty_clone. It's assuming that if the process has its P_CONTROLT flag set, then it's session has a valid vnode for it's controlling terminal. This doesn't hold if the terminal

Opening /dev/tty in session leader after controlling terminal is revoked causes panic.

2003-01-25 Thread Peter Edwards
. Cheers, Peter Edwards. GNU gdb 5.2.1 (FreeBSD) Copyright 2002 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type show copying to see the conditions

gdb of C++ program broken due to missing objects from Makefile.

2003-01-03 Thread Peter Edwards
Hi, Debugging trivial C++ programs in GDB is knackered, complaining about ABI doesn't define required function XXX when doing operations such as printing classes and structures which inherit from others, and setting breakpoints in virtual functions, etc. Adding gnu-v2-abi.c and gnu-v3-abi.c to

Re: Floating point problems

2002-10-25 Thread Peter Edwards
hang I've had with X and related. Thanks! juli. -- Juli Mallett [EMAIL PROTECTED] | FreeBSD: The Power To Serve Will break world for fulltime employment. | finger [EMAIL PROTECTED] http://people.FreeBSD.org/~jmallett/ | Support my FreeBSD hacking! -- Peter Edwards

Floating point problems

2002-10-24 Thread Peter Edwards
; sigemptyset(sa.sa_mask); sigaction(SIGINT, sa, 0); while (count 30) { d = x / y; err = 2.0 - d; if (err != 0.0) { fprintf(stderr, err %f!\n, err); exit(-1); } } } -- Peter Edwards. To Unsubscribe: send mail to [EMAIL

Re: Floating point problems

2002-10-24 Thread Peter Edwards
to produce any positive results after about 5 mins., which is 3-4 times longer than its ever been up before under the same stress. I'll report back in about 24 hours either way, but I think that's cured it. -- Peter. Bruce Evans [EMAIL PROTECTED] wrote: On Thu, 24 Oct 2002, Peter Edwards wrote

Bug unmounting readonly NTFS partitions uncovered by GEOM

2002-10-13 Thread Peter Edwards
13 Oct 2002 15:30:01 - @@ -508,6 +508,7 @@ vinvalbuf(ntmp-ntm_devvp, V_SAVE, NOCRED, td, 0, 0); + ronly = (mp-mnt_flag MNT_RDONLY) != 0; error = VOP_CLOSE(ntmp-ntm_devvp, ronly ? FREAD : FREAD|FWRITE, NOCRED, td); -- Peter Edwards To Unsubscribe

Re: Looking for comments on a new utility...

2002-06-11 Thread Peter Edwards
Solaris has something similar in /usr/proc/bin/ptree. One of the things it lets you do is specify _which_ user to use. Isn't the kvm_*() interface somewhat frowned upon? Is there anything missing from /proc that you need kvm_* for? -- Cheers, Peter. Juli Mallett wrote: Hej, As some of

Re: comparing executables

2002-04-03 Thread peter . edwards
Compare them without the ELF headers, a section at a time, so that the timestamps are irrelevent. From what I recall, there _are_ no timestamps in ELF images, and compiling the same executable multiple times locally here seems to bear out the fact: cmp on two successive outputs is identical.

Re: Contemplating THIS change to signals.

2002-03-07 Thread Peter Edwards
I mentioned something similar for a different reason. Go look at the last part of the following message in the recent -hackers archives: Subject: ptrace bug? MessageId: [EMAIL PROTECTED] (this was for -stable, BTW) Having the suspend for the ptrace()ing parent done in issignal is a pain

Re: vn.ko load/unload/mount = panic

2000-05-15 Thread Peter Edwards
Nick Hibma wrote: Correct me if I am wrong, but I don't think you actually have to disassociate any dev_t's from the driver (by clearing the si_drv[12] fields) because we call destroy_dev and cdevsw_remove, so any later uses of dev_t's get an error because the device has gone away. Apart

Re: vn.ko load/unload/mount = panic

2000-04-28 Thread Peter Edwards
I had a longer look at this, and a more complete patch is logged as PR kern/18270 (try at your own risk: it works for me). I'd appreciate someone more experienced having a look at it and commenting. Cheers, Peter. Wilko Bulte wrote: On Wed, Apr 26, 2000 at 04:25:46PM +0100, Peter Edwards

Re: vn.ko load/unload/mount = panic

2000-04-26 Thread Peter Edwards (local)
Hi, After a (very) quick look at the source it looks like there's a missing cdevsw_remove() missing from the MOD_UNLOAD/MOD_SHUTDOWN event handling I haven't time to test it, but try this: *** vn.c.oldWed Apr 26 16:23:03 2000 --- vn.cWed Apr 26 16:24:06 2000 *** ***

Re: vn.ko load/unload/mount = panic

2000-04-26 Thread Peter Edwards (local)
it. -- Peter. "Peter Edwards (local)" wrote: Hi, After a (very) quick look at the source it looks like there's a missing cdevsw_remove() missing from the MOD_UNLOAD/MOD_SHUTDOWN event handling I haven't time to test it, but try this: *** vn.c.oldWed Apr 26 16:23:03 2000

Re: tunefs -p doesn't work for read-write mounts

2000-03-03 Thread Peter Edwards
I just send-pr'ed a patch for this: misc/17143 David Malone wrote: On Fri, Mar 03, 2000 at 11:23:33AM +0200, Sheldon Hearn wrote: Shouldn't I be able to show the current tuneables for a given filesystem? # tunefs -p /usr tunefs: cannot work on read-write mounted file system

Re: C shell scripts (was: Re: which(1), rewritten in C?)

2000-03-03 Thread Peter Edwards
Assar Westerlund wrote: There's a real reason for not writing this in csh. Because the built-in function will return results for csh, which might not be the right ones for other shells. I got bitten by this by HP-UX 10's csh-based "which". My solaris-hosted NFS home directory had the

fstat(1) breakage + fix

1999-11-12 Thread Peter Edwards
Hi, fstat(1) should be able to take a set of filenames as arguments to limit the results of its output to the specified files. However, it doesn't work at the moment, because of the existance of udev_t. (It compares the st_dev from the stat structure used by stat(2) with in-kernel dev_t

tput(1) appears broken.

1999-08-31 Thread Peter Edwards
Hi, (Sorry if this hits the list a couple of times, I had some problems with my mail system) I never thought I'd see "clear" break :-) Here's a fix. It seems to be down to an ncurses change in tgetstr(). The implementation in ncurses just ignores the "area" parameter, while the one in