Summary: | ASTERISK-01795: Asterisk doesnt run on an Opteron (compiles OK though). | ||
Reporter: | deon (deon) | Labels: | |
Date Opened: | 2004-06-10 08:57:44 | Date Closed: | 2004-09-25 02:42:34 |
Priority: | Major | Regression? | No |
Status: | Closed/Complete | Components: | Core/General |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ||
Description: | Hey Guys, I've just got my shiney new AMD Opteron system and I compled asterisk (CVS 1.0-stable tree). The complile works fine (I just used make rpm), however when I start asterisk, no modules can load (so it abends).I've even added "noload" to the configuration file thinking that it was just the chan_modem - but it seems that EVERY chan_*, res_* modules wont load. [SetLanguage] == Registered application 'SetLanguage' [SetVar] == Registered application 'SetVar' [StripMSD] == Registered application 'StripMSD' [Suffix] == Registered application 'Suffix' [Wait] == Registered application 'Wait' Asterisk Dynamic Loader Starting: [chan_modem.so]Jun 10 23:41:14 WARNING[182894112384]: loader.c:289 ast_load_resource: Unexpected key returned by module /usr/lib/asterisk/modules/chan_modem.so Jun 10 23:41:14 WARNING[182894112384]: loader.c:293 ast_load_resource: 1 error(s) loading module /usr/lib/asterisk/modules/chan_modem.so, aborted Jun 10 23:41:14 WARNING[182894112384]: loader.c:359 load_modules: Loading module chan_modem.so failed! Here is the tail of strace - I think the problem is around the mprotect - as that results in ENOMEM which to me looks like an error - I'm no C/C++ programmer though :-) 18353 open("/etc/asterisk/modules.conf", O_RDONLY) = 6 18353 fstat(6, {st_mode=S_IFREG|0640, st_size=858, ...}) = 0 18353 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a9555a000 18353 read(6, ";\n; Asterisk configuration file\n"..., 4096) = 858 18353 read(6, "", 4096) = 0 18353 close(6) = 0 18353 munmap(0x2a9555a000, 4096) = 0 18353 futex(0x34805010f4, FUTEX_WAKE, 2147483647) = 0 18353 open("/usr/lib/asterisk/modules/chan_modem.so", O_RDONLY) = 6 18353 read(6, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@\36\0\0"..., 640) = 640 18353 fstat(6, {st_mode=S_IFREG|0755, st_size=77372, ...}) = 0 18353 mmap(NULL, 1071096, PROT_READ|PROT_EXEC, MAP_PRIVATE, 6, 0) = 0x2a9556c000 18353 mprotect(0, 1050616, PROT_NONE) = -1 ENOMEM (Cannot allocate memory) 18353 mmap(0x2a9566c000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 6, 0) = 0x2a9566c000 18353 close(6) = 0 18353 write(5, "Jun 10 23:38:38 WARNING[18289411"..., 113) = 113 18353 write(1, "Jun 10 23:38:38 WARNING[18289411"..., 71) = 71 18353 write(1, "Unexpected key returned by modul"..., 74) = 74 18353 write(5, "Jun 10 23:38:38 WARNING[18289411"..., 114) = 114 18353 write(1, "Jun 10 23:38:38 WARNING[18289411"..., 71) = 71 18353 write(1, "1 error(s) loading module /usr/l"..., 75) = 75 18353 munmap(0x2a9556c000, 1071096) = 0 18353 write(5, "Jun 10 23:38:38 WARNING[18289411"..., 76) = 76 18353 write(1, "Jun 10 23:38:38 WARNING[18289411"..., 66) = 66 18353 write(1, "Loading module chan_modem.so fai"..., 37) = 37 18353 munmap(0x2a95559000, 4096) = 0 18353 munmap(0x2a95558000, 4096) = 0 18353 munmap(0x2a95557000, 4096) = 0 18353 exit_group(1) = ? ****** ADDITIONAL INFORMATION ****** Not sure if you guys have access to an opteron, so I'm happy to help out where I can... | ||
Comments: | By: Brian West (bkw918) 2004-06-10 09:49:39 Talk to Zoa he runs without problems on an opteron By: zoa (zoa) 2004-06-13 08:18:28 try the -dev branch, * needs some Makefile tweaking to make it compile, but it seems like you got that far. If you want to test with the same version i'm using: Asterisk CVS-HEAD-05/17/04-07:26:09 built by root@julius on a x86_64 running Linux Find me on #asterisk if you need more help. By: Olle Johansson (oej) 2004-06-13 14:45:15 Not supported in 1-0stable. Contact Zoa on IRC for help. If it still doesn't work, reopen this bug. By: Olle Johansson (oej) 2004-06-13 16:25:23 Mark added some changes to CVS head this evening. Please test and confirm. By: Mark Spencer (markster) 2004-06-13 18:32:13 Note that you will need to change ARCH=k8 to ARCH=athlon as per the instructions in the Makefile if you are not runnning gcc 3.4 By: zoa (zoa) 2004-06-14 04:21:17 iirc, you will need to make some changes in the makefile for ilbc too. (+ it doesnt like the gsm optimization). Also, make sure you are not loading 32 bit modules for a 64 bit asterisk, it doesnt like that either. "File" can tell you the format. By: Mark Spencer (markster) 2004-06-14 14:41:07 All the changes for iLBC, GSM, etc are already in CVS and it's built as a 64-bit Asterisk. By: Olle Johansson (oej) 2004-06-14 14:48:57 Deon: Can you please check if this works for you? Download CVS head and try compiling on your system. /OEJ By: deon (deon) 2004-06-14 17:12:09 Wow, you take the weekend off, and I find out you guys have been working hard... Thanks :-) Yes, cvs updating now and will try tonight. Thanks guys... ...deon By: Mark Spencer (markster) 2004-06-16 21:36:31 Did it work for you? By: deon (deon) 2004-06-17 01:38:34 Guys, it compiled and works a treat - thanks! BTW, I didnt make the change in the makefile from k8 to athlon (and I'm using GCC 3.3.3 - FC2) - should I make that change? Also, mysql stuff doesnt work - I basically added references to /usr/lib64, which worked for everything EXCEPT the cdr - it doesnt compile, so I might open a new bug for that... Thanks heaps.. By: Mark Spencer (markster) 2004-06-17 11:08:01 No worries, if it compiled it should be good. Looks like I need to get FC2 on my x86_64, too. By: Mark Spencer (markster) 2004-06-17 14:35:26 Fixed in CVS |