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

samba: update to samba-4.x #1469

Merged
merged 8 commits into from Jul 11, 2017

Conversation

@MilhouseVH
Copy link
Contributor

commented Mar 22, 2017

Build pre-requisite: if

perl -MJSON -e 'exit(0);'

fails then you need to install sudo cpan JSON sudo apt-get install libjson-perl prior to building or the samba package will fail.

Thanks @sraue and @koying for laying the ground work on this.

This PR has a dependency on LibreELEC/service.libreelec.settings#62 which needs to be merged and LE settings bumped when this goes in.

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch from ea6348a to 7345c85 Mar 22, 2017

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Mar 22, 2017

Updated with the addition of libjson-perl to checkdeps - this works for Debian but probably needs testing on non-Debian build hosts.

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch 5 times, most recently from ef84765 to 3be1646 Mar 22, 2017

@escalade

This comment has been minimized.

Copy link
Contributor

commented Mar 27, 2017

I have a suggestion for this PR, the removal of the samba-autoshare script. A better approach is simply sharing /var/media as "Media" when SAMBA_AUTOSHARE=true. I can't see the point of creating a separate share on plugging a disk and restarting smbd each time, it's unnecessary complex.

Here's the changes I did in my build: escalade@788161b

There seems to be an issue with reported file size when Kodi uses libsmbclient from the updated version as well: https://forum.libreelec.tv/thread-302-post-42037.html#pid42037

Probably a good idea to test this PR properly :)

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Mar 27, 2017

I have a suggestion for this PR, the removal of the samba-autoshare script.

I'd probably be more inclined to handle that as a separate PR, as I'm not convinced this change has legs right now.

There seems to be an issue with reported file size when Kodi uses libsmbclient from the updated version as well: https://forum.libreelec.tv/thread-302-post-42037.html#pid42037

Yes, already fixed in this PR - the escalade@788161b commit on your branch is out of date, you should re-pull this PR.

Probably a good idea to test this PR properly :)

Unless we can resolve the anonymous access issue, and also the occasional thread locking issue (some kind of race condition?) I'm inclined to park this regardless of whatever it might fix. So far I've seen no evidence it actually fixes anything, and just causes more problems.

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Mar 28, 2017

Update to samba-4.6.1 due to security vulnerability: https://www.samba.org/samba/history/samba-4.6.1.html

@MilhouseVH MilhouseVH changed the title samba: update to samba-4.6.0 samba: update to samba-4.6.1 Mar 28, 2017

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch 4 times, most recently from 6818e48 to 5cb6464 Mar 29, 2017

@MilhouseVH MilhouseVH changed the title samba: update to samba-4.6.1 samba: update to samba-4.x Apr 2, 2017

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Apr 2, 2017

Updated to 4.6.2 which fixes a regression introduced by the 4.6.1 bug fix...

https://www.samba.org/samba/history/samba-4.6.2.html

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch from 905657a to 008d050 Apr 17, 2017

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Apr 17, 2017

Added a systemd commit.

smbd, nmbd, rpcbind and kodi (via libsmbclient) all maintain locks in /var.

When shutting down the system without the requirement on var.mount, systemd will attempt to stop the var.mount unit (ie. unmount /var) before the smbd, nmbd, rpcbind and kodi processes are terminated. As these processes all have open files on /var, the var.mount unit will fail.

Adding the var.mount requirement fixes this problem, and var.mount is stopped after the other processes.

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch from 008d050 to ad22f19 Apr 17, 2017

@stefansaraev

This comment has been minimized.

Copy link
Contributor

commented Apr 19, 2017

you can mount /var in initramfs: http://sprunge.us/DTLa and save yourself some pain.

@MilhouseVH

This comment has been minimized.

Copy link
Contributor Author

commented Apr 20, 2017

Thanks @stefansaraev - have dropped the systemd commit and added #1554

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch 8 times, most recently from f1b4565 to 2d0c26e May 10, 2017

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch from 8281d0a to 5f2dce8 May 24, 2017

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch 4 times, most recently from 3f5fcb7 to e7e7962 Jun 12, 2017

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch 2 times, most recently from dc95b43 to 56f546f Jul 6, 2017

@MilhouseVH MilhouseVH force-pushed the MilhouseVH:samba4 branch from 56f546f to d8db580 Jul 11, 2017

@chewitt chewitt merged commit 7661973 into LibreELEC:master Jul 11, 2017

@chewitt chewitt removed the MERGE BLOCKED label Jul 11, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.