Samba not working on OMV 4.x while working on OMV3.x

    • OMV 4.x

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Samba not working on OMV 4.x while working on OMV3.x

      Hello,

      I am new and installed initially the OMV3 using the ISO (openmediavault_3.0.86-amd64) and got all my CAMs to work perfectly (at the 1st attempt). As I wanted to install zoneminder etc... I opted to install a Debian 9.2.1 with OMV4 which went all ok. I did the same GUI configuration (and double checked the smb.conf which look the same) but for some reasons my CAMs keep saying:
      "Mounting to NAS server failed. Invalid directory or incorrect user name/password."

      I tried to set log level to 3 but didn't see the logs popping up in /var/log/samba so not sure how to debut and move forward.

      My CAMs are Hikvision and need to have a quota assigned to each directly. I emptyed the directories being shared by SMB to start clean.

      Noted that quota seems wrong (see size of Corridor directory for ex)


      Source Code

      1. root@Debian:/srv/dev-disk-by-id-scsi-0QEMU_QEMU_HARDDISK_drive-scsi1-part1# ll
      2. total 72
      3. -rw------- 1 root root 7168 nov. 19 14:18 aquota.group
      4. -rw------- 1 root root 7168 nov. 19 14:18 aquota.user
      5. drwxrws---+ 2 Back CAMs 4096 nov. 12 16:13 Back
      6. drwxrws---+ 3 Corridor CAMs 4096 nov. 12 16:14 Corridor
      7. drwxr-xr-x 2 www-data www-data 4096 nov. 19 15:19 events
      8. drwxrwsr-x+ 2 Front CAMs 4096 nov. 20 14:29 Front
      9. drwxr-xr-x 2 www-data www-data 4096 nov. 19 15:20 images
      10. drwxrws---+ 2 Jossua CAMs 4096 nov. 12 15:51 Jossua
      11. drwxrws---+ 3 Livingroom CAMs 4096 nov. 12 19:04 Livingroom
      12. drwx------ 2 root root 16384 févr. 11 2017 lost+found
      13. drwxrws---+ 3 Side CAMs 4096 nov. 18 14:51 Side
      14. drwxr-xr-x 2 www-data www-data 4096 nov. 19 15:20 sounds
      15. drwxrws---+ 2 Victorine CAMs 4096 nov. 12 15:51 Victorine
      16. root@Debian:/srv/dev-disk-by-id-scsi-0QEMU_QEMU_HARDDISK_drive-scsi1-part1# ll Corridor/
      17. total 8
      18. drwxrws---+ 2 Corridor CAMs 4096 nov. 12 16:14 datadir0
      19. -rwxrwx---+ 1 Corridor CAMs 68 nov. 12 16:14 info.bin
      Display All
      Corridor shows a size not linked to the HD space and over the definedvalue.

      Any idea of the issue? I don't necessary believe that my shares don't work because of this quota stuff but if you have some guidance on how to drill down the issue that would be appreciated.

      I have posted most of the important screens but please ask if anything missing or strange.

      Thanks
      XabiX

      Is there a way to export the OMV3 config and reimport in my Debian with OMV4? maybe that would do the trick quicker.
      Images
      • OMV_Users.png

        131.83 kB, 1,695×856, viewed 687 times
      • OMV_AcceRights.png

        143.44 kB, 1,778×877, viewed 507 times
      • OMV_Shares.png

        132.73 kB, 1,783×866, viewed 389 times
      • OmV_System.png

        96.2 kB, 1,778×876, viewed 1,194 times
      • OMV_Services.png

        62.5 kB, 1,786×629, viewed 383 times
      Files
      • smb.conf.txt

        (4.47 kB, downloaded 85 times, last: )

      The post was edited 4 times, last by XabiX ().

    • Not sure why but the service is showing red and here are some outputs that may give a hint?

      I did a start and it went back to my initial issue:

      Source Code

      1. root@Debian:~# systemctl start smbd
      2. root@Debian:~# systemctl status smbd
      3. ● smbd.service - Samba SMB Daemon
      4. Loaded: loaded (/lib/systemd/system/smbd.service; enabled; vendor preset: enabled)
      5. Active: active (running) since Mon 2017-11-20 21:44:16 CET; 4s ago
      6. Docs: man:smbd(8)
      7. man:samba(7)
      8. man:smb.conf(5)
      9. Main PID: 2482 (smbd)
      10. Status: "smbd: ready to serve connections..."
      11. Tasks: 3 (limit: 4915)
      12. CGroup: /system.slice/smbd.service
      13. ├─2482 /usr/sbin/smbd
      14. ├─2483 /usr/sbin/smbd
      15. └─2484 /usr/sbin/smbd
      16. nov. 20 21:44:15 Debian systemd[1]: Starting Samba SMB Daemon...
      17. nov. 20 21:44:16 Debian systemd[1]: smbd.service: Supervising process 2482 which is not our child. We'll most likely not notice when it exits.
      18. nov. 20 21:44:16 Debian systemd[1]: Started Samba SMB Daemon.
      Display All

      BTW I have succeed to connect from Windows on the shares but I am missing some parameters to ensure that one user can't access another one share.

      At least the config seem exactly the same but this Hikvision cameras are touchy. I believe the issue is not on the OMV4 itself but I don't understant why it worked on OMV3. Trying to reset one camera to see.

      Putting logs to Full i get:

      Source Code

      1. Nov 20 22:18:04 Debian smbd[10242]: [2017/11/20 22:18:04.902503, 1] ../source3/smbd/process.c:554(receive_smb_talloc)
      2. Nov 20 22:18:04 Debian smbd[10242]: receive_smb_raw_talloc failed for client ipv4:10.10.10.6:55283 read error = NT_STATUS_CONNECTION_RESET.
      3. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.921957, 2] ../source3/smbd/sesssetup.c:563(setup_new_vc_session)
      4. Nov 20 22:18:04 Debian smbd[10243]: setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
      5. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922135, 1] ../lib/param/loadparm.c:1729(lpcfg_do_global_parameter)
      6. Nov 20 22:18:04 Debian smbd[10243]: WARNING: The "syslog" option is deprecated
      7. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922153, 1] ../lib/param/loadparm.c:1729(lpcfg_do_global_parameter)
      8. Nov 20 22:18:04 Debian smbd[10243]: WARNING: The "syslog only" option is deprecated
      9. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922282, 1] ../lib/param/loadparm.c:1729(lpcfg_do_global_parameter)
      10. Nov 20 22:18:04 Debian smbd[10243]: WARNING: The "null passwords" option is deprecated
      11. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922309, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      12. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Victorine]"
      13. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922468, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      14. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Side]"
      15. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922702, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      16. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[LivingRoom]"
      17. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922837, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      18. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Jossua]"
      19. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.922975, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      20. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Front]"
      21. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.923133, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      22. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Corridor]"
      23. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.923235, 2] ../source3/param/loadparm.c:2685(lp_do_section)
      24. Nov 20 22:18:04 Debian smbd[10243]: Processing section "[Back]"
      25. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.923544, 2] ../libcli/auth/ntlm_check.c:424(ntlm_password_check)
      26. Nov 20 22:18:04 Debian smbd[10243]: ntlm_password_check: NTLMv1 passwords NOT PERMITTED for user Livingroom
      27. Nov 20 22:18:04 Debian smbd[10243]: [2017/11/20 22:18:04.923638, 2] ../source3/auth/auth.c:315(auth_check_ntlm_password)
      28. Nov 20 22:18:04 Debian smbd[10243]: check_ntlm_password: Authentication for user [Livingroom] -> [Livingroom] FAILED with error NT_STATUS_WRONG_PASSWORD
      29. Nov 20 22:18:04 Debian smbd[10244]: [2017/11/20 22:18:04.934880, 2] ../source3/smbd/sesssetup.c:563(setup_new_vc_session)
      30. Nov 20 22:18:04 Debian smbd[10244]: setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
      31. Nov 20 22:18:04 Debian smbd[10244]: [2017/11/20 22:18:04.935480, 1] ../lib/param/loadparm.c:1729(lpcfg_do_global_parameter)
      Display All
      I have checked several times my pwd but they are the same. Could it be because in my pwd there is the character & ?

      THANKS

      The post was edited 5 times, last by XabiX ().

    • Interesting reading: Privileges and permissions explained under OMV

      Not sure if the system permissions should still be root:user but then if that's the case then that may be my issue. When i created my share I did select "Recursive".

      Is that then my issue? should i put them back on root:Front for example? or delete the shares and create them again maybe worth :)

      Maybe the smb.conf file can be updated to avoid:
      Nov 20 22:49:19 Debian smbd[20916]: WARNING: The "syslog" option is deprecated
      Nov 20 22:49:19 Debian smbd[20916]: WARNING: The "syslog only" option is deprecated
      Nov 20 22:49:19 Debian smbd[20916]: WARNING: The "null passwords" option is deprecated

      Before the users had only one group and now in OMV4 there is this user group showing up. could this explain the differences? as my initial setup was exactly the same.

      getting lost!

      The post was edited 1 time, last by XabiX ().


    • gimble wrote:

      I added following line to the [global] section in /etc/samba/smb.conf:
      You shouldn´t edit /etc/samba/smb.conf directly. If you change SMB/CIFS settings in OMV the next time, the smb.conf is overwritten by OMV. You can force this by
      CLI> omv-mkconf samba

      Instead add your entry in the SMB/CIFS settings -> Advanced settings -> Extra options field.

      A second possibility is the add the next line to /etc/default/openmediavault

      OMV_SAMBA_NTLM_AUTH="YES"

      Then do a
      CLI> omv-mkconf samba
      CLI> service smbd restart
      You can check your SAMBA settings with
      CLI> testparm

      This is tested for OMV3. I hope it works also for OMV4.
      OMV 3.0.90 (Gray style)
      ASRock Rack C2550D4I - 16GB ECC - 6x WD RED 3TB (ZFS 2x3 Striped RaidZ1)- Fractal Design Node 304