I've had bus errors in Perl when the symlinks that point to /private/etc
from /etc were accidentally deleted, probably from my perl code altho
I'm not sure how.
You may want to check to see that they are still there and recreate them
(as root, via sudo) if they're not.
eric
On Monday, June 10, 2002, at 09:34 AM, R Blake wrote:
> hi all,
>
> i've built Perl 5.8.0RC1 on OSX Server 10.1.4 successfully .......
>
> just about everything seems to run fine. modperl2 is installed on a
> working Apache2.0.36 as well ....... but not without a minor fix .......
>
> i get a "bus error" when running the following test script:
>
> -------------------- test.pl ----------------
> use strict;
> use Socket;
>
> my $localhost_addr = pack('C4', 127, 0, 0, 1);
> my $default_localhost = gethostbyaddr($localhost_addr,
> Socket::AF_INET()) || 'localhost';
>
> print "localhost=$default_localhost\n";
> -------------------- test.pl ----------------
>
>>
>> [root@server]perl test.pl
>> Bus error
>
> here's the stack trace of the crash:
>
> **********
>
> OS Version: 10.1.4 (Build 5Q125)
> Host: server.internal.net
>
> Command: perl
> PID: 20193
>
> Exception: EXC_BAD_ACCESS (0x0001)
> Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x700c92fc
>
> Thread 0 Crashed:
> #0 0x70003b08 in memmove
> #1 0x00008540 in __res_vinit
> #2 0x00007624 in gen_res_get
> #3 0x000058f0 in net_data_create
> #4 0x0000582c in __net_data_init
> #5 0x00004340 in init
> #6 0x00003254 in gethostbyaddr
> #7 0x004658b8 in Perl_pp_ghostent
> #8 0x004656e4 in Perl_pp_ghbyaddr
> #9 0x003f8120 in Perl_runops_standard
> #10 0x00373e7c in S_run_body
> #11 0x003739c4 in perl_run
> #12 0x00001c20 in main
> #13 0x00001a54 in _start
> #14 0x00001884 in start
>
> PPC Thread State:
> srr0: 0x70003b08 srr1: 0x0000f030 vrsave: 0x00000000
> xer: 0x00000020 lr: 0x00008540 ctr: 0x70003a00 mq: 0x00000000
> r0: 0x10020035 r1: 0xbfffe7f0 r2: 0x700c930c r3: 0x700c92fc
> r4: 0x00a57230 r5: 0x00000000 r6: 0xac1e0a02 r7: 0x00000000
> r8: 0x00000000 r9: 0x00a57210 r10: 0x00000000 r11: 0x0003350c
> r12: 0x70003a00 r13: 0x00000000 r14: 0x80008a98 r15: 0x8000219c
> r16: 0xbfffec28 r17: 0xbfffec48 r18: 0x8000214c r19: 0x00000000
> r20: 0x00000001 r21: 0x87859393 r22: 0xc24bc195 r23: 0x87859393
> r24: 0x8000213c r25: 0x00000000 r26: 0xbffff424 r27: 0x00000000
> r28: 0x00000000 r29: 0x00000000 r30: 0xbfffe833 r31: 0x00007f90
>
> **********
> as this error does *not* occur on a virgin OSX 10.1.5 build (i know, a
> little apple-n-oranges) something, no doubt, has changed on my system
> that is causing gethostbyaddr to choke ......
>
> unfortunately, i haven't been clever enuf to track down the
> problem .......
>
> any thoughts/suggestions?
>
> many thanks!
>
> --------------------------------------
> R Blake
> blakers <at> mac.com
> http://homepage.mac.com/blakers
> --------------------------------------
> MacOSX ..... because Windows sux.
> --------------------------------------