public inbox for blinux-list@redhat.com
 help / color / mirror / Atom feed
* delay local file system mounting
@  blinux-list
   ` blinux-list
   ` blinux-list
  0 siblings, 2 replies; 3+ messages in thread
From: blinux-list @  UTC (permalink / raw)


I have a raid array that I use for storage, and it takes a while for it to be mounted. This causes a delay, sometimes quite significant, before the login prompt appears.
Is there a way to cause a 
/etc/fstab
entry to be delayed? I know I could always mount the array manually after login, but I'd rather not if I can avoid it.




^ permalink raw reply	[flat|nested] 3+ messages in thread

* delay local file system mounting
   delay local file system mounting blinux-list
@  ` blinux-list
   ` blinux-list
  1 sibling, 0 replies; 3+ messages in thread
From: blinux-list @  UTC (permalink / raw)


Tim here.  The typical way I've heard of doing this is

1) edit your /etc/fstab so that your mount is set to "noauto" rather
than "auto".  This prevents it from automatically mounting and
causing the delay.  Then

2) create a crontab entry to mount it:

  $ sudo crontab -e

and add a line like

  @reboot mount /path/to/raid /mount/where/you/want/your/raid

This will mount the RAID device later in the boot process while still
allowing the rest of the system to boot.  This assumes that the RAID
is to be mounted by root for system-wide access.  If you're mounting
it as a user, you can do it in your ~/.xsession (or your
window-manager's startup script/file such as ~/.fluxbox/startup).

Note that (somewhat obviously) this only works if the boot process
doesn't require anything on that RAID device.

-tim


On May 27, 2021, Linux for blind general discussion wrote:
> I have a raid array that I use for storage, and it takes a while
> for it to be mounted. This causes a delay, sometimes quite
> significant, before the login prompt appears. Is there a way to
> cause a /etc/fstab entry to be delayed? I know I could always mount
> the array manually after login, but I'd rather not if I can avoid
> it.
> 
> 
> _______________________________________________
> Blinux-list mailing list
> Blinux-list at redhat.com
> https://listman.redhat.com/mailman/listinfo/blinux-list
> 



^ permalink raw reply	[flat|nested] 3+ messages in thread

* delay local file system mounting
   delay local file system mounting blinux-list
   ` blinux-list
@  ` blinux-list
  1 sibling, 0 replies; 3+ messages in thread
From: blinux-list @  UTC (permalink / raw)


27.05.2021 21:20, Linux for blind general discussion ?????:
> I have a raid array that I use for storage, and it takes a while for it to be mounted. This causes a delay, sometimes quite significant, before the login prompt appears.
> Is there a way to cause a
> /etc/fstab
> entry to be delayed? I know I could always mount the array manually after login, but I'd rather not if I can avoid it.
>
>
it's not hard to do if your distribution uses systemd as init.

you need to add the x-systemd.automount option to the mountpoint entry 
in your fstab.
then the disk will be automatically mounted when some process writes to it.
you can also set the time to unmount with the x-systemd.idle-timeout = 
by default the disk will not be unmounted.

-- 
Sincerely, Alexander.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~ UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
 delay local file system mounting blinux-list
 ` blinux-list
 ` blinux-list

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).