Unable to create shares - cannot select device

    • OMV 3.x
    • Resolved
    • Unable to create shares - cannot select device

      Hi folks,
      I have successfully managed to install OMV 3.0.89 on a WD MyCloud Gen2 6TB NAS device. It all went smoothly, however, I am running into problems when creating shares. That's what I do:

      - Click "Shared Folders" in the menu
      - Click "Add"
      - Try to select a device by clicking the little down arrow in the Device field

      => Nothing happens. I cannot select a device on which a shared folder could be generated. The Device field still says "Select a device..."

      My idea was to check the available devices in File Systems. Two partitions are listed:

      /dev/sda2,,ext4,5.41TiB,5.14TiB,57.94MiB,Yes,No,Online
      /dev/sda3,,ext4,2.68GiB,1.36GiB,1.1 GiB, Yes,Yes, Online

      Further, I tried unmounting the sda2 partition via GUI. When clicking the Unmount button, I get this error message:
      The XPath query '//system/fstab/mntent[((((((fsname='/dev/sda2' or fsname='/dev/disk/by-id/ata-WDC_WD60EFRX-68L0BN1_WD-WX21DB63A9N5-part2') or fsname='/dev/disk/by-id/wwn-0x50014ee263b21e16-part2') or fsname='/dev/disk/by-partlabel/primary') or fsname='/dev/disk/by-partuuid/4df20f43-052a-497b-9e80-99aead559319') or fsname='/dev/disk/by-uuid/8b98cd24-db99-4df2-94ba-f1a50b352cab') or fsname='8b98cd24-db99-4df2-94ba-f1a50b352cab')]' does not return the requested number of 1 object(s).


      Error #0:
      exception 'OMV\Config\DatabaseException' with message 'The XPath query '//system/fstab/mntent[((((((fsname='/dev/sda2' or fsname='/dev/disk/by-id/ata-WDC_WD60EFRX-68L0BN1_WD-WX21DB63A9N5-part2') or fsname='/dev/disk/by-id/wwn-0x50014ee263b21e16-part2') or fsname='/dev/disk/by-partlabel/primary') or fsname='/dev/disk/by-partuuid/4df20f43-052a-497b-9e80-99aead559319') or fsname='/dev/disk/by-uuid/365b52f3-c2ac-4115-8bbb-a7bcba9dbe8a') or fsname='365b52f3-c2ac-4115-8bbb-a7bcba9dbe8a')]' does not return the requested number of 1 object(s).' in /usr/share/php/openmediavault/config/database.inc:172
      Stack trace:
      #0 /usr/share/openmediavault/engined/rpc/filesystemmgmt.inc(952): OMV\Config\Database->getByFilter('conf.system.fil...', Array, 1)
      #1 [internal function]: OMVRpcServiceFileSystemMgmt->umount(Array, Array)
      #2 /usr/share/php/openmediavault/rpc/serviceabstract.inc(124): call_user_func_array(Array, Array)
      #3 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod('umount', Array, Array)
      #4 /usr/sbin/omv-engined(536): OMV\Rpc\Rpc::call('FileSystemMgmt', 'umount', Array, Array, 1)
      #5 {main}
      I have no problem mounting/unmounting the partition as root on the shell.

      That's how mount shows the devices:

      /dev/sda3 on / type ext4 (rw,relatime,data=ordered)

      /dev/sda2 on /home type ext4 (rw,relatime,data=ordered)
      Here is the fstab output:

      # Default mounts

      /dev/sda3 / ext4 rw,noauto 0 1
      proc /proc proc defaults 0 0
      devpts /dev/pts devpts defaults,gid5,mode=620 0 0
      tmpfs /dev/shm tmpfs mode=0777 0 0
      tmpfs /tmp tmpfs mode=1777 0 0
      tmpfs /run tmpfs mode=0755,nosuid,nodev 0 0
      sysfs /sys sysfs defaults 0 0

      # Add swap
      /dev/sda1 swap swap defaults 0 0
      /dev/sda2 /home ext4 defaults 0 0
      tmpfs /tmp tmpfs defaults 0 0
      # >>> [openmediavault]
      # <<< [openmediavault]
      Any help is appreciated!
      Images
      • wd_01.PNG

        4.25 kB, 600×139, viewed 905 times
      • wd_02.PNG

        10.75 kB, 951×230, viewed 1,614 times
      • wd_03.PNG

        16.94 kB, 789×591, viewed 1,083 times

      The post was edited 3 times, last by Aileron79 ().

    • Aileron79 wrote:

      Solved:
      - Partition Type needs to be 15 (Linux Filesystem)
      - Partition must NOT be mounted in /etc/fstab but rather in the GUI.
      Hi!

      I am having the same problems you had with my WD My Cloud Gen2. I followed the instructions of Fox to install Debian and OpenMediaVault, but I am having the exact problems that you described.

      I am not very used to work with partitions, and I don't know a lot about fstab and partition types. Could you tell me how do you solved it? How can I do those things?

      Thanking you in advance,
      Xoán
    • Problem - it is impossible to select the device on which we create the shared resource
      This is most likely due to the fact that on the laptop with which WD My Cloud is configured, Windows is installed.

      If you go over SSH to WD My Cloud and type the command fdisk -l, then you will see the source of the problem:

      Source Code

      1. Device Start End Sectors Size Type
      2. /dev/sda1 2048 1953791 1951744 953M Microsoft basic data
      3. /dev/sda2 7813120 488396799 480583680 229.2G Microsoft basic data
      4. /dev/sda3 1953792 7813119 5859328 2.8G Microsoft basic data

      The data partition type is 6-Microsoft basic data, and should be 15-Linux filesystem
      We do the following:

      Source Code

      1. root@wdmc:~# fdisk /dev/sda
      2. Welcome to fdisk (util-linux 2.25.2).
      3. Changes will remain in memory only, until you decide to write them.
      4. Be careful before using the write command.
      5. Command (m for help): t
      6. Partition number (1-3, default 3): 2
      7. Partition type (type L to list all types): 15
      8. Changed type of partition 'Microsoft basic data' to 'Linux filesystem'.
      9. Command (m for help): w
      10. The partition table has been altered.
      11. Calling ioctl() to re-read partition table.
      12. Re-reading the partition table failed.: Device or resource busy
      13. The kernel still uses the old table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8).
      14. root@wdmc:~# partprobe
      15. root@wdmc:~# umount /dev/sda2
      Display All
      that is, we changed the type of the data section and unmounted it.
      After that, already in the OMW Web interface, a data section was mounted and we had the opportunity to select it
    • Users Online 1

      1 Guest