Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segmentation fault on MacPro5,1 #4

Open
b- opened this issue Jan 18, 2023 · 6 comments
Open

Segmentation fault on MacPro5,1 #4

b- opened this issue Jan 18, 2023 · 6 comments
Labels
help wanted Extra attention is needed

Comments

@b-
Copy link
Contributor

b- commented Jan 18, 2023

Running on Proxmox VE (basically Debian bullseye), compiled from source with completely default configuration (apart from #3). I’m running on a MacPro5,1.

Transcript:

# macfand -n
Loading profile for model: macpro5,1
dbug: opening profile /usr/local/macfand/machines//macpro5,1.conf
Segmentation fault

the profile exists and is being read:

# strace !!
strace macfand -n
execve("/usr/local/bin/macfand", ["macfand", "-n"], 0x7ffc65a8c758 /* 21 vars */) = 0
brk(NULL)                               = 0x556b0a696000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=70188, ...}) = 0
mmap(NULL, 70188, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fab6e781000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libconfig.so.9", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0 /\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=47768, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fab6e77f000
mmap(NULL, 2142976, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fab6e400000
mprotect(0x7fab6e40b000, 2093056, PROT_NONE) = 0
mmap(0x7fab6e60a000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xa000) = 0x7fab6e60a000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libm.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\0\322\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=1321344, ...}) = 0
mmap(NULL, 1323280, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fab6e63b000
mmap(0x7fab6e648000, 630784, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xd000) = 0x7fab6e648000
mmap(0x7fab6e6e2000, 634880, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xa7000) = 0x7fab6e6e2000
mmap(0x7fab6e77d000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x141000) = 0x7fab6e77d000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@>\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1905632, ...}) = 0
mmap(NULL, 1918592, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fab6e22b000
mmap(0x7fab6e24d000, 1417216, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x22000) = 0x7fab6e24d000
mmap(0x7fab6e3a7000, 323584, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x17c000) = 0x7fab6e3a7000
mmap(0x7fab6e3f6000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1ca000) = 0x7fab6e3f6000
mmap(0x7fab6e3fc000, 13952, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fab6e3fc000
close(3)                                = 0
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fab6e638000
arch_prctl(ARCH_SET_FS, 0x7fab6e638740) = 0
mprotect(0x7fab6e3f6000, 16384, PROT_READ) = 0
mprotect(0x7fab6e77d000, 4096, PROT_READ) = 0
mprotect(0x7fab6e60a000, 4096, PROT_READ) = 0
mprotect(0x556b08d8e000, 4096, PROT_READ) = 0
mprotect(0x7fab6e7bd000, 4096, PROT_READ) = 0
munmap(0x7fab6e781000, 70188)           = 0
brk(NULL)                               = 0x556b0a696000
brk(0x556b0a6b7000)                     = 0x556b0a6b7000
rt_sigaction(SIGCHLD, {sa_handler=SIG_IGN, sa_mask=[CHLD], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTSTP, {sa_handler=SIG_IGN, sa_mask=[TSTP], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTTOU, {sa_handler=SIG_IGN, sa_mask=[TTOU], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTTIN, {sa_handler=SIG_IGN, sa_mask=[TTIN], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGINT, {sa_handler=0x556b08d8c491, sa_mask=[INT], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGHUP, {sa_handler=0x556b08d8c491, sa_mask=[HUP], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTERM, {sa_handler=0x556b08d8c491, sa_mask=[TERM], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fab6e263d60}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
openat(AT_FDCWD, "/etc/macfand.conf", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=1348, ...}) = 0
fstat(3, {st_mode=S_IFREG|0644, st_size=1348, ...}) = 0
read(3, "# macfand - Fan Control daemon f"..., 8192) = 1348
read(3, "", 4096)                       = 0
read(3, "", 8192)                       = 0
close(3)                                = 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(0x88, 0), ...}) = 0
write(1, "Loading profile for model: macpr"..., 37Loading profile for model: macpro5,1
) = 37
write(1, "dbug: opening profile /usr/local"..., 66dbug: opening profile /usr/local/macfand/machines//macpro5,1.conf
) = 66
openat(AT_FDCWD, "/usr/local/macfand/machines//macpro5,1.conf", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=8003, ...}) = 0
fstat(3, {st_mode=S_IFREG|0644, st_size=8003, ...}) = 0
read(3, "# macpro5,1.conf\n#\n# Machine Nam"..., 8192) = 8003
read(3, "", 4096)                       = 0
brk(0x556b0a6d8000)                     = 0x556b0a6d8000
read(3, "", 8192)                       = 0
close(3)                                = 0
--- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0x1} ---
+++ killed by SIGSEGV +++
Segmentation fault
@ablakely
Copy link
Owner

Interesting, it seems to crash after reading the configuration file. Can you try running with gdb?

@ablakely ablakely added the help wanted Extra attention is needed label Nov 17, 2023
@ablakely
Copy link
Owner

Is this still an issue @b-?

@b-
Copy link
Contributor Author

b- commented Dec 18, 2023

I'll have to try it again, but I can make a point of doing so and let you know.

@b-
Copy link
Contributor Author

b- commented Jan 2, 2024

Sorry for the late reply, the past few weeks have been busy.

I just compiled and installed fresh on Proxmox 8.1.3 which is basically just Debian Bookworm with a Linux 6.5.11-7 kernel. I'm still getting the same behavior. I'm happy to try with gdb, but I honestly don't really know how to use it.

EDIT: Okay, actually I got some information out of gdb more easily than I expected:

(gdb) r -n
Starting program: /root/macfand/macfand -n
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Loading profile for model: macpro5,1
dbug: opening profile /usr/local/macfand/machines/macpro5,1.conf

Program received signal SIGSEGV, Segmentation fault.
__memcpy_sse2_unaligned_erms () at ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S:341
341     ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S: No such file or directory.
(gdb) 

@TobiasvonCarnap
Copy link

macpro5,1.conf has values for CPUA and CPUB, could it be possible that this is a profile only for dual tray models?

@b-
Copy link
Contributor Author

b- commented Jun 18, 2024

macpro5,1.conf has values for CPUA and CPUB, could it be possible that this is a profile only for dual tray models?

I don't think this should be an issue, as my machine does have two sockets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants