systemd.mount with disk label
here are some points
- e2label will not work with the mounted partitions.
- the service file name is correspond with the
Where
option. - check the
systemctl status
results for the unit file.
here is my procedure and the unit file example.
# label the partition e2label /dev/sd?? hdd-label1 # create the unit file. cat > /etc/systemd/system/mnt-aaa.mount <<EOF [Unit] Description = mount WesternDigital 1T to /mnt/aaa After = local-fs.target [Mount] #What = /dev/disk/by-label/ts1t-deg What = LABEL=wd1t-deg Where = /mnt/aaa Type = ext4 Options = nofail [Install] WantedBy = default.target EOF # reload and mount... systemctl daemon-reload systemctl status mnt-aaa.mount # check the errors systemctl start mnt-aaa.mount
コメント
Comments powered by Disqus