Guest - Testers are needed for the reworked CDateTime core component. See... https://forum.kodi.tv/showthread.php?tid=378981 (September 29) x
Hide drives/partitions in Kodi file list (Video/Music/Picture)
#1
Hi,

since I have a dualboot config on one Harddisk I see the Windows and Windows boot partition in the Kodi Filelists inside Kodi/LibreElec.

Is there a way to hide / unmount them?

Thanks, regards,
Michael
Reply
#2
Thread moved to Windows
|Banned add-ons (wiki)|Forum rules (wiki)|VPN policy (wiki)|First time user (wiki)|FAQs (wiki) Troubleshooting (wiki)|Add-ons (wiki)|Free content (wiki)|Debug Log (wiki)|

Kodi Blog Posts
Reply
#3
Code:
cp /usr/lib/udev/rules.d/95-udevil-mount.rules /storage/.config/udev.rules.d/95-udevil-mount.rules
nano /storage/.config/udev.rules.d/95-udevil-mount.rules

^^ edit the ENV{ID_FS_LABEL} line to add the partition names that you don't want to mount (check them using 'blkid') then reboot .. and in theory they won't be mounted. Delete the file any time to revert to normal behaviour.
Reply
#4
Moving to Linux, as this is LibreELEC and not Windows (they're the 'other' partitions).
Reply
#5
Thanks, will Test it tomorrow. Real Live didnt want me today to sit on the Computer :-)

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
Reply
#6
sry, I am to new in this thing...
I have following drives:
Code:
/dev/sda1: LABEL="System" UUID="176a0f9f-42a7-49a8-86cb-aadc3567dd24" TYPE="ext4" PARTUUID="9d73bbba-01"
/dev/sda2: LABEL="System-reserviert" UUID="889CD3FA9CD3E0AC" TYPE="ntfs" PARTUUID="9d73bbba-02"
/dev/sda3: LABEL="Windows" UUID="2CE0D8BFE0D89106" TYPE="ntfs" PARTUUID="9d73bbba-03"
/dev/sda4: LABEL="Storage" UUID="1f996d9c-0ebc-4c0e-9850-2bfeed17c5a7" TYPE="ext4" PARTUUID="9d73bbba-04"
/dev/loop0: TYPE="squashfs"
/dev/sdb1: LABEL="USB3Intern" UUID="fdd4437b-7743-d201-e040-437b7743d201" TYPE="ext4" PARTUUID="3da040e0-01"
I want to unmount "System-reserviert" and "Windows"

What do I change in this commands:
Code:
# dont run in "installer" mode
IMPORT{cmdline}="installer"
ENV{installer}=="1", GOTO="exit"

# check for blockdevices, /dev/sd*, /dev/sr* and /dev/mmc*
SUBSYSTEM!="block", KERNEL!="sd*|sr*|mmc*", GOTO="exit"

# check for special partitions we dont want mount
IMPORT{builtin}="blkid"
ENV{ID_FS_LABEL}=="EFI|BOOT|Recovery|RECOVERY|SETTINGS|boot|root0|share0", GOTO="exit"

# /dev/sd* and /dev/mmc* ith partitions/disk and filesystems only and /dev/sr* disks only
KERNEL=="sd*|mmc*", ENV{DEVTYPE}=="partition|disk", ENV{ID_FS_USAGE}=="filesystem", GOTO="harddisk"
KERNEL=="sr*", ENV{DEVTYPE}=="disk", GOTO="optical"
GOTO="exit"

# mount or umount for hdds
LABEL="harddisk"
ACTION=="add", RUN+="/usr/bin/systemctl restart udevil-mount@/dev/%k.service"
ACTION=="remove", RUN+="/usr/bin/systemctl stop udevil-mount@/dev/%k.service"
GOTO="exit"

# mount or umount for opticals
LABEL="optical"
ACTION=="add|change", RUN+="/usr/bin/systemctl restart udevil-mount@/dev/%k.service"
GOTO="exit"

# Exit
LABEL="exit"

thanks
Reply
#7
Help please

Gesendet von meinem ONEPLUS A3003 mit Tapatalk
Reply
#8
In theory, you simply add the labels of the partitions you *don't* want to mount to the ENV{ID_FS_LABEL}=="..." line, inside the quotes.

I can't 100% be certain that it's simply a case of adding "System-reserviert" and "Windows" into that list, though - I'd defer to chewitt there that blkid give you the appropriate labels (vs. e.g. ls -l /dev/disk/*) - but that's what I'd try. Back up the file before you start editing it, of course...
Reply

Logout Mark Read Team Forum Stats Members Help
Hide drives/partitions in Kodi file list (Video/Music/Picture)0