-
Notifications
You must be signed in to change notification settings - Fork 87
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
internal error: signal 11 - when saving word or excel files #357
Comments
For the record, this is the stacktrace shared by Reindl Harald on the list:
|
@ITelligencia With which netatalk version did this usecase last work? BTW, this doesn't have any bearing with the current issue, but you don't need to use the |
@ITelligencia so I tried to replicate your environment as much as possible (although with Debian Bullseye), using similar afp.conf settings, and running the latest Office 365 native Mac apps. I was able to save docx and xlsx files from the Mac onto multiple netatalk AFP shares without encountering errors. So there must be something else environmental in your setup. For instance, are you using a file system that is not ext4? Would it be possible to get debug logs from netatalk leading up to the crash? You can set |
Hello, I believe I'm experiencing the issue mentioned here, but I'm not a linux/netatalk expert. MS Word Freezes on Mac M1 when saving/closing files located on netatalk fileserver. Client Environment:
File server Environment:
Stack trace:
Additionally, I don't know if this is helpful, but I see in the dpkg logs an upgrade to netatalk around the time this started in early June 2023...
Any help resolving, including work-arounds is helpful. |
UPDATE - after downgrading to netatalk 3.1.12~ds-9build1 the issue is resolved for me. |
Awesome - that worked for me, as well!
Much appreciated,
Ruben
From: "Paul Merrill" ***@***.***>
To: "Netatalk/netatalk" ***@***.***>
Cc: "RUBEN ITELLIGENCIA.CA" ***@***.***>, "Mention" ***@***.***>
Sent: Tuesday, July 11, 2023 8:19:48 AM
Subject: Re: [Netatalk/netatalk] internal error: signal 11 - when saving word or excel files (Issue #357)
UPDATE - after downgrading to netatalk 3.1.12~ds-9build1 the issue is resolved for me.
—
Reply to this email directly, [ #357 (comment) | view it on GitHub ] , or [ https://github.com/notifications/unsubscribe-auth/AGCVUESGDUNKNK247HYUE7LXPVOIJANCNFSM6AAAAAAZJRFK44 | unsubscribe ] .
You are receiving this because you were mentioned. Message ID: ***@***.***>
|
Thanks for sharing the additional context. Let me set up an Ubuntu VM to see what patches they applied to In the meantime, it'd love it if you could provide me with debug logs leading up to the crash. This would help immensely with pinpointing the source of the problem. |
Confirmed that the latest Ubuntu package pulls in the entire range of security patches contained in 3.1.15:
compared to
So this issue is very likely falling under the same umbrella as #236 |
@dpm3354 Would you be able to share the contents of your afp.conf with me as well? Also, how are your shared volumes configured? Are they on the same file system as the Linux system, or on external storage media somehow? |
Hi @rdmark - my afp.conf file below. I've changed the name of the mountpoint and user to amountpoint and auser, respectively. Additionally, you asked for debug logs from before the crash. I'm not familiar with what you mean. Is that from syslog, just earlier in the trace that I already provided? Or is that something else, something I would need to recreate for you? I'm not able to spend much time helping, unfortunately, but if it's easy, I'm happy to send.
|
@dpm3354 thanks for this! You really don't do anything fancy in your afp.conf so these settings are clearly not the differentiator. Yes by logs, I mean syslog. For one, I'd love to see the ~100 lines that lead up to the crash. Additionally if you have the time, by putting |
Hi rdmark, On my test server, once I upgrade to the latest netatalk package (3.1.12 on ubuntu server 22.04), then reconnect from my mac, the syslog immediately starts spewing errors. I have attached a syslog excerpt from during the updating (nothing interesting) and then an excerpt with the errors right after the update - it basically keeps repeating the last error, while Word hangs as it can't finalise saving the doc. There is a very basic afp.conf: ; Netatalk 3.x configuration file [Global] [testruben] |
on this test server, /opt/testruben is not on a different drive. settings in fstab: |
@ITelligencia This is very helpful, thank you! The The one lead here is that you have xattr and ACL enabled for your file system, which I don't. Both are types of extended attributes, so there's a good chance that this is what makes the difference! |
Okay I was able to reproduce this issue now. What I did was to add the Even more curiously, the xattr man page suggests that you shouldn't even use the user_xattr option with an ext4 file system. If I read the man page correctly, it's a legacy option to enable EAs on reiserfs and legacy ext variants. Could anyone more knowledgeable here confirm or refute this? |
ext4 supports xattrs by default, so the mount option makes no
difference. You can use the *attr command to verify like setfattr -n
user.foo -v bar file.
|
Thanks @slowfranklin , that's a helpful troubleshooting method. I spotted the Now, what seems to happen when saving the Word/Excel file, is that the application stores temporary files in a new temp dir, which I believe should be converted to a macOS bundle afterwards, but this process fails and it stays a temp dir and netatalk crashes. My additional logging gives the error This is the complete debug log.
|
On 7/30/23 08:01, Daniel Markstedt wrote:
Now, what seems to happen when saving the Word/Excel file,
can't reproduce. I've installed latest Office on a Mac with Venture,
connected to Netatalk and tried different create/save/open/edit/save
combinations, both with main and branch-netatalk-3-1, neither did crash.
I have a very basic setup
[Global]
log file = /var/log/netatalk.log
log level = default:info
[test]
path = /srv/samba/test
sharing a btrfs filesystem.
Am I missing any steps in the reproducer?
…-slow
--
Ralph Boehme, Samba Team https://samba.org/
SerNet Samba Team Lead https://sernet.de/en/
SAMBA+ Samba packages https://samba.plus/
|
@slowfranklin The difference in your setup might be the file system. I replicated your setup but on my ext4 file system, and observing the behavior illustrated in the screenshot here. Word creates a zero byte bundle on the Netatalk volume, but then hangs permanently. Shortly after you can see the temporary folder appearing in the shared Netatalk volume. |
On 7/31/23 07:46, Daniel Markstedt wrote:
@slowfranklin <https://github.com/slowfranklin> The difference in your
setup might be the file system.
I'm pretty sure it's not the filesystem. As far as Netatalk is
concerned, as long as it's a POSIX conforming filesystem and supports
xattrs, for Netatalk they're all the same.
…-slow
--
Ralph Boehme, Samba Team https://samba.org/
SerNet Samba Team Lead https://sernet.de/en/
SAMBA+ Samba packages https://samba.plus/
|
The ext4 filesystem and the mounting arguments used, were the only differences in my setup. I reproduced the internal error on a clean vm.Once i have a few minutes, i will do it again, leaving out the mounting arguments.Rubenfrom his phoneOn Jul 31, 2023, at 12:19 AM, slowfranklin ***@***.***> wrote:
On 7/31/23 07:46, Daniel Markstedt wrote:
@slowfranklin <https://github.com/slowfranklin> The difference in your
setup might be the file system.
I'm pretty sure it's not the filesystem. As far as Netatalk is
concerned, as long as it's a POSIX conforming filesystem and supports
xattrs, for Netatalk they're all the same.
…-slow
--
Ralph Boehme, Samba Team https://samba.org/
SerNet Samba Team Lead https://sernet.de/en/
SAMBA+ Samba packages https://samba.plus/
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: ***@***.***>
|
These files @rdmark showed were orphaned on my system too. From what I can tell, these files were created, MS Word froze and then the files were left there. My fs was also ext4. |
I have a similar issue with 3.1.15 on FreeBSD 13.2 and a ZFS-backed share. With ZFS xattr=on (default) it triggers the segfault immediately when accessing the share from macOS. Hope this additional data point helps. |
With some additional logging I tracked down the failing assertion to this line: https://github.com/Netatalk/netatalk/blob/96f4fa3355c470ae6763327a2d270f400f75c210/libatalk/adouble/ad_open.c#L1660C10-L1660C10 It seems this host of headers are failing the overflow check since the buffer is 0 bytes. Looking at the callstack this comes from when Word's temp files are being copied.
Next, to figure out why we have 0 buffer here... |
I have a tentative fix in PR #363 -- any takers to run a few tests? The nature of this fix is that when copying metadata, we now check that the destination has > 0 buffer before attempting the copy. The fix may have side effects, so please be careful to backup your data before testing! |
Hi Paul, sure thing - forgive me, but how do I git clone that version? Do I git clone the master, then switch to that (rdmark-issue-236?) branch?
Ruben Rouw
Elastix Certified Engineer
780.604.6041
IT Consulting | Design | Implementation
Email is the best way to reach me.
To get my immediate attention, if I don't respond to text, try WhatsApp.
From: "Paul Merrill" ***@***.***>
To: "Netatalk" ***@***.***>
Cc: "RUBEN ITELLIGENCIA.CA" ***@***.***>, "Mention" ***@***.***>
Sent: Wednesday, August 9, 2023 11:43:18 PM
Subject: Re: [Netatalk/netatalk] internal error: signal 11 - when saving word or excel files (Issue #357)
I have a tentative fix in PR [ #363 | #363 ] -- any takers to run a few tests?
The nature of this fix is that when copying metadata, we now check that the destination has > 0 buffer before attempting the copy. The fix may have side effects, so please be careful to backup your data before testing!
—
Reply to this email directly, [ #357 (comment) | view it on GitHub ] , or [ https://github.com/notifications/unsubscribe-auth/AGCVUES2YTJWD7YJA5H72ULXURYHNANCNFSM6AAAAAAZJRFK44 | unsubscribe ] .
You are receiving this because you were mentioned. Message ID: ***@***.***>
|
@ITelligencia Correct, please clone this git repo, then checkout the rdmark-issue-236 branch. |
For the record, doing some git blaming I found an adjacent bug that was fixed 10 years ago: https://sourceforge.net/p/netatalk/bugs/510/ Here I learned that the apple_dump tool actually supports EA metadata, i.e. |
That works. Initially there was an improvement, but Word would still intermittently hang on save, though just for a long time.
Then I removed the explicit xattr arguments (defaults,user_xattr,acl) from fstab and remounted the volume (rebooted). Word now saves normally every time.
I just tested with 1 document.
If you want, I could apply it on our production server and test it for a few days? I won't be able to implement till next week.
Ruben Rouw
Elastix Certified Engineer
780.604.6041
IT Consulting | Design | Implementation
Email is the best way to reach me.
To get my immediate attention, if I don't respond to text, try WhatsApp.
From: "Paul Merrill" ***@***.***>
To: "Netatalk" ***@***.***>
Cc: "RUBEN ITELLIGENCIA.CA" ***@***.***>, "Mention" ***@***.***>
Sent: Wednesday, August 9, 2023 11:43:18 PM
Subject: Re: [Netatalk/netatalk] internal error: signal 11 - when saving word or excel files (Issue #357)
I have a tentative fix in PR [ #363 | #363 ] -- any takers to run a few tests?
The nature of this fix is that when copying metadata, we now check that the destination has > 0 buffer before attempting the copy. The fix may have side effects, so please be careful to backup your data before testing!
—
Reply to this email directly, [ #357 (comment) | view it on GitHub ] , or [ https://github.com/notifications/unsubscribe-auth/AGCVUES2YTJWD7YJA5H72ULXURYHNANCNFSM6AAAAAAZJRFK44 | unsubscribe ] .
You are receiving this because you were mentioned. Message ID: ***@***.***>
|
@ITelligencia May I ask you to share the exact netatalk code revision that you used for testing? E.g. do The reason for asking, is because I did a major rebase of my work branch with #178 last night, while reverting my own crude fix. So depending on when you did |
commit 04b4787 (HEAD -> rdmark-issue-236, origin/rdmark-issue-236)
From: "Paul Merrill" ***@***.***>
To: "Netatalk" ***@***.***>
Cc: "RUBEN ITELLIGENCIA.CA" ***@***.***>, "Mention" ***@***.***>
Sent: Friday, August 11, 2023 11:11:18 AM
Subject: Re: [Netatalk/netatalk] internal error: signal 11 - when saving word or excel files (Issue #357)
[ https://github.com/ITelligencia | @ITelligencia ] May I ask you to share the exact netatalk code revision that you used for testing? E.g. do git log and tell me the HEAD commit.
The reason for asking, is because I did a major rebase of my work branch with [ #178 | #178 ] last night, while reverting my own crude fix. So depending on when you did git pull you may have very different code.
—
Reply to this email directly, [ #357 (comment) | view it on GitHub ] , or [ https://github.com/notifications/unsubscribe-auth/AGCVUETJIGX4KHCDNGKHL2DXUZRTNANCNFSM6AAAAAAZJRFK44 | unsubscribe ] .
You are receiving this because you were mentioned. Message ID: ***@***.***>
|
@ITelligencia Thanks, so you're definitely using outdated code there. May I ask you to pull the latest code and run your tests again (make sure you rebase with |
Done: rebased - reinstalled - re-enabled xattr - Works flawlessly!
Much appreciated
From: "Paul Merrill" ***@***.***>
To: "Netatalk" ***@***.***>
Cc: "RUBEN ITELLIGENCIA.CA" ***@***.***>, "Mention" ***@***.***>
Sent: Friday, August 11, 2023 11:37:25 AM
Subject: Re: [Netatalk/netatalk] internal error: signal 11 - when saving word or excel files (Issue #357)
[ https://github.com/ITelligencia | @ITelligencia ] Thanks, so you're definitely using outdated code there. May I ask you to pull the latest code and run your tests again (make sure you rebase with git pull --rebase )? Please make sure to re-enable xattr on the file system.
—
Reply to this email directly, [ #357 (comment) | view it on GitHub ] , or [ https://github.com/notifications/unsubscribe-auth/AGCVUEWWS2WUDPKFLPR2JUTXUZUVLANCNFSM6AAAAAAZJRFK44 | unsubscribe ] .
You are receiving this because you were mentioned. Message ID: ***@***.***>
|
Excellent news -- thank you so much for running these tests! |
The primary bug fix #178 has been merged to main, so I'm closing this ticket as resolved. Please raise a new ticket if you run into similar assertions down the line! |
The Debian Buster netatalk package has been hotfixed now, so if you're running Buster you can do The patch will probably propagate to Ubuntu soon, too, although I don't have any insights into their process. |
Note that the netatalk package in Debian unstable has been patched now with a fix for this bug:
|
I have time to install and try this patch over the next two to four weeks. I am unfamiliar with the ubuntu/deb patch/release process. It appears this is not yet in ubuntu, is that correct? Otherwise, please point me to the correct version for ubuntu and I will be happy to provide feedback on if this is working for me. |
@dpm3354 Yes you're correct, Ubuntu hasn't updated their package since 3.1.15~ds-1ubuntu1, whereas in upstream Debian we put out a 3.1.18 deb two months ago. Ubuntu's deb sync process is documented here https://wiki.ubuntu.com/SyncRequestProcess Edit: It seems like anyone can initiate a out-of-cycle sync request by filing a Launchpad ticket. You could try it yourself if you feel up for it. :) |
Similar to issue described on the admin list, but here users have no problem authenticating.
Hi,
After updating our ubuntu 20.04 ubuntu fileserver, netatalk stopped working - or rather, clients are unable to save microsoft 365 files.
I started again on a fresh ubuntu 23.04 server (also tried 22.04), but
Word and Excel on mac (M1 and M2) clients hang when saving files. Initially installed netatalk via apt, then moved on to the latest version, 3.1.15, as I understood this issue was fixed from 3.1.14.
I used the following configure options:
./configure
--with-init-style=debian-systemd
--without-libevent
--without-tdb
--with-cracklib
--enable-krbV-uam
--with-pam-confdir=/etc/pam.d
--with-dbus-daemon=/usr/bin/dbus-daemon
-—with-dbus-sysconf-dir=/etc/dbus-1/system.d
--with-tracker-pkgconfig-version=3.0
afp.conf:
[Global]
max connections = 1000
zeroconf = yes
hostname = netatalk
;nodebug = yes
vol preset = my default values
[my default values]
ea = samba
;convert appledouble = no
[Backups and Clones]
path = /volume1/Backups_and_Clones
valid users = @users
directory perm = 0775
file perm =0664
/var/log/syslog:
2023-06-16T10:11:54.282523-06:00 netatalk afpd[1292]: INTERNAL ERROR: Signal 11 in pid 1292 (3.1.15)
2023-06-16T10:11:54.282686-06:00 netatalk afpd[1292]: ===============================================================
2023-06-16T10:11:54.282888-06:00 netatalk afpd[1292]: PANIC: internal error
2023-06-16T10:11:54.283917-06:00 netatalk afpd[1292]: BACKTRACE: 11 stack frames:
2023-06-16T10:11:54.284215-06:00 netatalk afpd[1292]: #0 /usr/local/lib/libatalk.so.18(netatalk_panic+0x39) [0x7fb364eeda69]
2023-06-16T10:11:54.284304-06:00 netatalk afpd[1292]: #1 /usr/local/lib/libatalk.so.18(+0x3abbe) [0x7fb364eedbbe]
2023-06-16T10:11:54.284423-06:00 netatalk afpd[1292]: #2 /lib/x86_64-linux-gnu/libc.so.6(+0x3c4b0) [0x7fb36483c4b0]
2023-06-16T10:11:54.284514-06:00 netatalk afpd[1292]: #3 /lib/x86_64-linux-gnu/libc.so.6(+0x170e2c) [0x7fb364970e2c]
2023-06-16T10:11:54.284598-06:00 netatalk afpd[1292]: #4 /usr/local/lib/libatalk.so.18(ad_copy_header+0x55) [0x7fb364ecae45]
2023-06-16T10:11:54.284799-06:00 netatalk afpd[1292]: #5 /usr/local/sbin/afpd(afp_exchangefiles+0x758) [0x563d4afcdf78]
2023-06-16T10:11:54.284917-06:00 netatalk afpd[1292]: #6 /usr/local/sbin/afpd(afp_over_dsi+0x57b) [0x563d4afb7b0b]
2023-06-16T10:11:54.285008-06:00 netatalk afpd[1292]: #7 /usr/local/sbin/afpd(main+0x9af) [0x563d4afb5aaf]
2023-06-16T10:11:54.285114-06:00 netatalk afpd[1292]: #8 /lib/x86_64-linux-gnu/libc.so.6(+0x23a90) [0x7fb364823a90]
2023-06-16T10:11:54.285220-06:00 netatalk afpd[1292]: #9 /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x89) [0x7fb364823b49]
2023-06-16T10:11:54.285328-06:00 netatalk afpd[1292]: #10 /usr/local/sbin/afpd(_start+0x25) [0x563d4afb5e05]
The text was updated successfully, but these errors were encountered: