README 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. $OpenBSD: README,v 1.3 2014/07/22 10:55:41 ajacoutot Exp $
  2. +-----------------------------------------------------------------------
  3. | Running ${FULLPKGNAME} on OpenBSD
  4. +-----------------------------------------------------------------------
  5. The hotplug-diskmount command is invoked by the hotplugd(8) daemon
  6. from its attach script and terminates when the device is detached.
  7. Before using it for the first time, create the directory where all
  8. mountpoints will be placed:
  9. # ${TRUEPREFIX}/libexec/hotplug-diskmount init
  10. Enable hotplugd at boot time:
  11. # echo hotplugd_flags= >> /etc/rc.conf.local
  12. Edit the /etc/hotplug/attach script (remember to set the executable
  13. bit, if needed):
  14. #!/bin/sh
  15. DEVCLASS=${1}
  16. DEVNAME=${2}
  17. LOGIN=joeuser
  18. case ${DEVCLASS} in
  19. 2)
  20. ${TRUEPREFIX}/libexec/hotplug-diskmount attach -u ${LOGIN} -m 700 ${DEVNAME}
  21. ;;
  22. esac
  23. When a new device is inserted into the system, filesystems from
  24. this device will be automatically mounted under /vol/DRIVE_NAME.
  25. hotplug-diskmount will mount as many partitions as disk contains.