Difference between revisions of "Fstab - Use SystemD automount/es"

Created page with "Un problema que esto causa es que si me olvido de comentar los recursos compartidos de NFS que estoy usando del archivo /etc/fstab, tengo que esperar uno o dos minutos durante..."
(Created page with "La magia (para mí) que estas opciones traen es que si un recurso compartido de red o un disco externo que está siento llamado via /etc/fstab no está presente, estas salvan...")
Tags: Mobile web edit Mobile edit
(Created page with "Un problema que esto causa es que si me olvido de comentar los recursos compartidos de NFS que estoy usando del archivo /etc/fstab, tengo que esperar uno o dos minutos durante...")
Line 1: Line 1:
<languages/>
<languages/>
__TOC__
__TOC__
{{SectionTemplate|Introduction|
{{SectionTemplate|Introducción|
He encontrador una combinacíon de opciones para systemd (en el Archwiki [https://wiki.archlinux.org/index.php/Systemd#Automount]) que pueden utilizarse en el /etc/fstab al montar dispositivos de almacenamiento -- sean estos internos, externos. o recursos compartidos de red.  
He encontrador una combinacíon de opciones para systemd (en el Archwiki [https://wiki.archlinux.org/index.php/Systemd#Automount]) que pueden utilizarse en el /etc/fstab al montar dispositivos de almacenamiento -- sean estos internos, externos. o recursos compartidos de red.  


La magia (para mí) que estas opciones traen es que si un recurso compartido de red o un disco externo que está siento llamado via /etc/fstab no está presente, estas salvan tu maquina de colgarse por un minuto o dos durante el proceso de arranque.
La magia (para mí) que estas opciones traen es que si un recurso compartido de red o un disco externo que está siento llamado via /etc/fstab no está presente, estas salvan tu maquina de colgarse por un minuto o dos durante el proceso de arranque.


A device called this way via /etc/fstab is mounted the first time data is attempted to be accessed from it. Only on this first mount is there any (minor) noticeable delay, when compared to having the device mounted the "old" way.}}
Un dispositivo llamado de esta forma vía /etc/fstab es montado la primera vez que se intenta acceder a los datos desde él. Unicamente en este primer montaje hay una (mínima) demora notable, comparado con tener el dispositivo montado de la forma "altigua".}}


{{SectionTemplate|1=A suitable problem example|2=
{{SectionTemplate|1=Un ejemplo adecuado del problema|2=
I have a ReadyNAS Duo v1, which is connected to my LAN. These days I quite often turn it off as it doesn't need to run perpetually.
Tengo un ReadyNAS Duo v1, que está conectado a mi LAN. En estos días, a menudo lo apago, ya que no necesita funcionar perpetuamente.


A problem that this causes is that if I forget to comment out the NFS share(s) that I'm using from the /etc/fstab file, I have to wait for a minute or two during the boot process whilst the system repetitively tries to make a connection.
Un problema que esto causa es que si me olvido de comentar los recursos compartidos de NFS que estoy usando del archivo /etc/fstab, tengo que esperar uno o dos minutos durante el proceso de arranque mientras el sistema intenta repetidamente para hacer una conexión.


I attempted to get AutoFS [https://wiki.manjaro.org/index.php?title=Using_autofs_(automount)_with_NFS]to work for me. I got close but I just wasn't allowed to see the files on the NFS NAS share.
Intenté obtener AutoFS [https://wiki.manjaro.org/index.php?title=Using_autofs_(automount)_with_NFS] para trabajar para mi Me acerqué, pero simplemente no se me permitió ver los archivos en el recurso compartido NFS NAS.


So then I found the following extremely simple & effective solution. (Wish I had of done this one first, as it would have saved me a couple of hours of a loosing battle!)}}
Entonces encontré la siguiente solución extremadamente simple y efectiva. (¡Ojalá hubiera hecho esto primero, ya que me habría ahorrado un par de horas de una batalla perdida!)}}


{{SectionTemplate|1=How do you do use it?|2=
{{SectionTemplate|1=¿Cómo lo usas?|2=
Add the following to the beginning of the options section in your /etc/fstab, the numbers at the end are a time limit for how long it should try to make a connection before giving up & moving on:
Agregue lo siguiente al comienzo de la sección de opciones en su /etc/fstab, los números al final son un límite de tiempo de cuánto tiempo debe intentar establecer una conexión antes de darse por vencido y seguir adelante:


  {{File|file=/etc/fstab|content=<pre>noauto,x-systemd.automount,x-systemd.device-timeout=10</pre>}}
  {{File|file=/etc/fstab|content=<pre>noauto,x-systemd.automount,x-systemd.device-timeout=10</pre>}}




After I added the above to the following line in my fstab:
Después de agregar lo anterior a la siguiente línea en mi fstab:


  {{File|file=/etc/fstab|content=<pre>192.168.1.15:/media-2 /mnt/NAS-media-2 nfs noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,hard,intr,noatime 0 0</pre>}}
  {{File|file=/etc/fstab|content=<pre>192.168.1.15:/media-2 /mnt/NAS-media-2 nfs noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,hard,intr,noatime 0 0</pre>}}




I could boot Manjaro whilst the ReadyNAS' Cat-6 network cable was unplugged, & there was NO noticeable delay. After the system was booted, I plugged the cable in & then called the NFS share /media-2 in Worker & it read the drive & listed the contents.
Pude iniciar Manjaro mientras el cable de red Cat-6 de ReadyNAS estaba desenchufado y NO hubo un retraso notable. Después de que se inició el sistema, conecté el cable y luego llamé al NFS share /media-2 en Worker y leyó la unidad y listó el contenido.


Después de eso, desconecté la unidad, que tenía a Worker (mi administrador de archivos preferido) buscándola porque no había cambiado del directorio media-2. Cuando volví a enchufar el cable, tomó aproximadamente 10 segundos y luego Worker volvió a enumerar automáticamente el contenido de esta partición muy grande que tiene más de 2000 directorios, cada uno con varios archivos.}}
Después de eso, desconecté la unidad, que tenía a Worker (mi administrador de archivos preferido) buscándola porque no había cambiado del directorio media-2. Cuando volví a enchufar el cable, tomó aproximadamente 10 segundos y luego Worker volvió a enumerar automáticamente el contenido de esta partición muy grande que tiene más de 2000 directorios, cada uno con varios archivos.}}


{{SectionTemplate|1=Speed up your boot|2=
{{SectionTemplate|1=Acelera tu arranque|2=
If you have a very large /home & the boot process is held up when a scheduled fsck takes place (really not a big problem if you are using ext4), you can add the '''x-systemd.automount''' section to the options section of the line in your fstab for /home like so:
If you have a very large /home & the boot process is held up when a scheduled fsck takes place (really not a big problem if you are using ext4), you can add the '''x-systemd.automount''' section to the options section of the line in your fstab for /home like so:


  {{File|file=/etc/fstab|content=<pre>UUID=<id.number> /home noauto,x-systemd.automount,ext4 defaults 0 1</pre>}}
  {{File|file=/etc/fstab|content=<pre>UUID=<id.number> /home noauto,x-systemd.automount,ext4 defaults 0 1</pre>}}


This will allow services that do not depend on /home to start while /home is checked by fsck. Mounting /home when it is first accessed, the kernel will buffer all file access to /home until it is ready.}}
Esto permitirá a los servicios que no dependen en /home a iniciar mientras /home es verificada por fsck. Montando /home cuando se accede por primera vez, el kernel almacenará en búfer todo el acceso a archivos a /home hasta que esté listo.}}


[[Category:Contents Page{{#translation:}}]]
[[Category:Contents Page{{#translation:}}]]
448

edits