Ambos lados, revisión anteriorRevisión previaPróxima revisión | Revisión previaPróxima revisiónAmbos lados, revisión siguiente |
es:howtos:slackware_admin:how_to_configure_fstab_and_lilo.conf_with_persistent_naming [2019/02/05 15:32 (UTC)] – [Label] slackwarespanol | es:howtos:slackware_admin:how_to_configure_fstab_and_lilo.conf_with_persistent_naming [2019/04/26 02:30 (UTC)] – [GPT (PartLabel and PartUUID)] antares_alf |
---|
<note warning>En proceso de traducción. Victor</note> | |
<!-- Add your text below. We strongly advise to start with a Headline (see button bar above). --> | <!-- Add your text below. We strongly advise to start with a Headline (see button bar above). --> |
| |
====== Cómo configurar fstab y lilo.conf con nombres persistentes ====== | ====== Cómo configurar fstab y lilo.conf con nombres persistentes ====== |
| |
¿Alguna vez ha tenido el orden de cambio de sus unidades / dev / sda y / dev / sdb? ¿Conectar un dispositivo USB antes de arrancar su computadora causó un pánico en el kernel? ¿Con frecuencia desenchufa o conecta dispositivos nuevos en su computadora, cambiando así el orden de los nombres de los dispositivos? Si ha respondido afirmativamente a alguno de ellos, podría ser un buen candidato para utilizar nombres persistentes en su gestor de arranque y fstab. | ¿Alguna vez ha tenido el orden de cambio de sus unidades /dev/sda y /dev/sdb? ¿Conectar un dispositivo USB antes de arrancar su computadora causó un pánico en el kernel? ¿Con frecuencia desenchufa o conecta dispositivos nuevos en su computadora, cambiando así el orden de los nombres de los dispositivos? Si ha respondido afirmativamente a alguno de ellos, podría ser un buen candidato para utilizar nombres persistentes en su gestor de arranque y fstab. |
===== ¿Qué es el nombramiento persistente? ===== | ===== ¿Qué es el nombramiento persistente? ===== |
| |
La denominación persistente le permite hacer referencia a su unidad por algo que no cambia. Hay varios métodos diferentes disponibles para la asignación de nombres persistentes y cubriremos lo siguiente: ID, etiqueta y UUID, así como PartLabel y PartUUID basados en GPT. Las más utilizadas son las etiquetas y los UUID, principalmente porque han existido durante mucho tiempo. Las tablas de partición GPT introdujeron una versión actualizada de etiquetas y UUID denominados partlabel y partuuid que se almacenan directamente en la tabla de partición. Sin embargo, comenzando con el kernel 3.8, PartUUID se ha expandido para generar identificadores únicos más cortos (UID) para las particiones MBR, permitiendo esencialmente que las unidades MBR usen PARTUUID. | El nombramiento persistente le permite hacer referencia a su unidad en forma fija. Hay varios métodos diferentes disponibles para la asignación de nombres persistentes y cubriremos lo siguiente: ID, etiqueta y UUID, así como PartLabel y PartUUID basados en GPT. Las más utilizadas son las etiquetas y los UUID, principalmente porque han existido durante mucho tiempo. Las tablas de partición GPT introdujeron una versión actualizada de etiquetas y UUID denominados partlabel y partuuid que se almacenan directamente en la tabla de partición. Sin embargo, a partir del kernel 3.8, PartUUID se ha expandido para generar identificadores únicos más cortos (UID) para las particiones MBR, permitiendo esencialmente que las unidades MBR usen PARTUUID. |
| |
Ahora, vamos a profundizar en los diversos métodos: | Ahora, vamos a profundizar en los diversos métodos: |
| |
==== ID ==== | ==== ID ==== |
| |
==== Label ==== | ==== Label ==== |
| |
Las etiquetas (label) son un nombre opcional configurado por el usuario para la unidad. La mayoría de los sistemas de archivos admiten esto, pero no siempre se crean automáticamente. Todas las etiquetas se pueden encontrar en '' /dev/disk/by-label/ '' y se pueden ver fácilmente usando '' ls -la /dev/disk/by-label / ''. | Las etiquetas (label) son un nombre opcional configurado por el usuario para la unidad. La mayoría de los sistemas de archivos admiten esto, pero no siempre se crean automáticamente. Todas las etiquetas se pueden encontrar en ''/dev/disk/by-label/'' y se pueden ver fácilmente usando ''ls -la /dev/disk/by-label/''. |
| |
<code>/dev/disk/by-label: | <code>/dev/disk/by-label: |
lrwxrwxrwx 1 root root 10 Jul 31 17:18 Data -> ../../sdb1</code> | lrwxrwxrwx 1 root root 10 Jul 31 17:18 Data -> ../../sdb1</code> |
| |
Las etiquetas pueden ser bastante convenientes sobre las ID debido a su capacidad para ser extremadamente cortas y memorables. Sin embargo, si no tiene cuidado o si mueve los discos entre sistemas, puede tener problemas con nombres duplicados que causan conflictos. Tanto lilo como fstab admiten el uso de '' LABEL = "Backup '' 'para hacer referencia directamente a la unidad en lugar de tener que usar' '/dev/disk/by-label/ Backup' ', lo que hace que esta sea una opción mucho más sencilla para hacer referencia a las unidades. | Las etiquetas pueden ser bastante convenientes sobre las ID debido a su capacidad para ser extremadamente cortas y memorables. Sin embargo, si no tiene cuidado o si mueve los discos entre sistemas, puede tener problemas con nombres duplicados que causan conflictos. Tanto lilo como fstab admiten el uso de ''LABEL = "Backup"'' para hacer referencia directamente a la unidad en lugar de tener que usar ''/dev/disk/by-label/ Backup'', lo que hace que esta sea una opción mucho más sencilla para hacer referencia a las unidades. |
| |
Si desea agregar una etiqueta a su partición, [[https://wiki.archlinux.org/index.php/persistent_block_device_naming#by-label | ArchWiki]] esta página tiene instrucciones para la mayoría de los sistemas de archivos. | Si desea agregar una etiqueta a su partición, [[https://wiki.archlinux.org/index.php/persistent_block_device_naming#by-label | ArchWiki]] esta página tiene instrucciones para la mayoría de los sistemas de archivos. |
==== UUID ===== | ==== UUID ===== |
| |
[[https://en.wikipedia.org/wiki/Universally_unique_identifier | UUIDs]] (**U**niversally **U**nique **ID**entifiers) are a unique identifier generated for a partition. All Linux filesystems will generate UUIDs when they're formatted. FAT and NTFS filesystems do not support UUIDs, however, a short UID is used in place of a regular UUID. All UUIDs can be found under ''/dev/disk/by-uuid/'' and can be viewed using ''ls -la /dev/disk/by-uuid/'' | [[https://en.wikipedia.org/wiki/Universally_unique_identifier | Los UUID]] (**ID**entificadores **Ú**nicos **U**niversales) son un identificador único generado para una partición. Todos los sistemas de archivos de Linux generarán UUID cuando se formatean. Los sistemas de archivos FAT y NTFS no admiten UUID, sin embargo, se utiliza un UID corto en lugar de un UUID normal. Todos los UUID se pueden encontrar en ''/dev/disk/by-uuid/'' y se pueden ver usando ''ls -la /dev/disk/by-uuid/'' |
| |
<code>/dev/disk/by-uuid: | <code>/dev/disk/by-uuid: |
lrwxrwxrwx 1 root root 10 Jul 31 17:18 126AC3506AC32EF3 -> ../../sdq1 #Example NTFS UID -- not really in my system</code> | lrwxrwxrwx 1 root root 10 Jul 31 17:18 126AC3506AC32EF3 -> ../../sdq1 #Example NTFS UID -- not really in my system</code> |
| |
UUIDs can also be referenced by using just ''UUID=226f1db3-2f14-4862-9998-8be1e8f7cdc9'' in your ''/etc/lilo.conf'' and ''/etc/fstab'' files. | También se puede hacer referencia a los UUID utilizando solo ''UUID = 226f1db3-2f14-4862-9998-8be1e8f7cdc9'' en sus archivos ''/etc/lilo.conf'' y ''/etc/fstab''. |
==== GPT (PartLabel and PartUUID)==== | ==== GPT (PartLabel and PartUUID)==== |
| |
The [[https://en.wikipedia.org/wiki/Master_boot_record|MBR]] (Master Boot Record) has been the primary partition table for harddrives for the past few decades (it was introduced in 1983). However, it is unable to be used on disks larger than 2TBs. That is where [[https://en.wikipedia.org/wiki/GUID_Partition_Table|GPT]] (GUID Partition Table) comes in. This was developed as part of the [[https://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Interface|UEFI]] spec but can be used without using UEFI. | El [[https://en.wikipedia.org/wiki/Master_boot_record|MBR]] (Master Boot Record) ha sido la tabla de partición primaria para los discos duros durante las últimas décadas (se introdujo en 1983). Sin embargo, no se puede utilizar en discos de más de 2 TB. Ahí es donde entra [[https://en.wikipedia.org/wiki/GUID_Partition_Table|GPT]] (Tabla de particiones GUID). Esto se desarrolló como parte de [[https://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Interface | UEFI]] espec. Pero se puede usar sin usar UEFI. |
| |
In addition to the limitations of the MBR, there are also limitations of using UUIDs and Labels, mainly being that if you use those in your bootloader, you are required to use an [[howtos:slackware_admin:kernelbuilding#creating_an_initrd|initrd]]. While it is recommended by Pat to use an initrd, many users prefer using a kernel that doesn't require one (either using the huge kernel or building a custom kernel with the required hardware support compiled in). The GPT spec added PartLabel and PARTUUID as a way to save that information directly to the partition table (the "part" stands for partition). While both PartLabel and PartUUID are included in the GPT spec, the kernel only supports booting PARTUUIDs, so you can't use PartLabel in your bootloaders. If you want to use PartUUID, you don't need any initrd to be able to read this data, which makes it much easier to use on systems that aren't already using an initrd. Initially, since PARTUUID was introduced as part of the GPT spec, MBR-based devices could not be referenced using PARTUUID; however, basic support for PartUUID on MBR partitions was added starting with the 3.8 Linux kernel, so now any drive can be referenced by its "PARTUUID". | |
| |
| Además de las limitaciones del MBR, también existen limitaciones para el uso de UUID y etiquetas, principalmente porque si usa los de su cargador de arranque, debe usar un [[howtos: slackware_admin: kernelbuilding # creating_an_initrin | initrd]]. Si bien Pat recomienda usar un initrd, muchos usuarios prefieren usar un kernel que no requiere uno (ya sea usando el kernel enorme o construyendo un kernel personalizado con el soporte de hardware necesario compilado). La especificación de GPT agregó PartLabel y PARTUUID como una forma de guardar esa información directamente en la tabla de particiones ("part" significa partición). Si bien PartLabel y PartUUID están incluidos en la especificación GPT, el kernel solo admite el inicio de PARTUUID, por lo que no puede usar PartLabel en sus cargadores de arranque. Si desea usar PartUUID, no necesita ningún initrd para poder leer estos datos, lo que hace que sea mucho más fácil de usar en sistemas que aún no usan initrd. Inicialmente, dado que PARTUUID se introdujo como parte de la especificación de GPT, no se pudo hacer referencia a los dispositivos basados en MBR utilizando PARTUUID; sin embargo, el soporte básico para PartUUID en particiones MBR se agregó a partir del kernel 3.8 de Linux, por lo que ahora se puede hacer referencia a cualquier unidad con su "PARTUUID". |
=== PartLabel === | === PartLabel === |
| |
This is almost identical to the regular Label option. It is located under ''/dev/disk/by-partlabel/'' and can be viewed with ''ls -la /dev/disk/by-partlabel''. PARTLABEL can only be used in the fstab. Due to lack of support in the kernel, you will need to use one of the other persistent naming conventions in your lilo.conf | Esto es casi idéntico a la opción de etiqueta normal. Se encuentra en ''/dev/disk/by-partlabel/'' y se puede ver con ''ls -la /dev/disk/by-partlabel''. PARTLABEL solo se puede utilizar en el fstab. Debido a la falta de soporte en el kernel, necesitará usar una de las otras convenciones de nombres persistentes en su lilo.conf |
| |
<code>/dev/disk/by-partlabel: | <code>/dev/disk/by-partlabel: |
lrwxrwxrwx 1 root root 10 Jul 31 17:18 Linux\\x20filesystem -> ../../sdc1</code> | lrwxrwxrwx 1 root root 10 Jul 31 17:18 Linux\\x20filesystem -> ../../sdc1</code> |
| |
Also, this will only show official PARTLABELs. It will not show any labels from disks using MBR. If you need to view those, you can use ''blkid''. | Además, esto solo mostrará PARTLABELs oficiales. No mostrará ninguna etiqueta de los discos que utilizan MBR. Si necesita verlos, puede usar ''blkid''. |
| |
<code>slackware@darkstar:~$ su - | <code>slackware@darkstar:~$ su - |
/dev/sda3: UUID="226f1db3-2f14-4862-9998-8be1e8f7cdc9" TYPE="ext4" PARTUUID="6f47c81b-03"</code> | /dev/sda3: UUID="226f1db3-2f14-4862-9998-8be1e8f7cdc9" TYPE="ext4" PARTUUID="6f47c81b-03"</code> |
| |
As you can see in the case of ''/dev/sdc1'', you can have a different LABEL and PARTLABEL. That is because these are stored independently of one another. LABEL is a filesystem trait, whereas PARTLABEL is a partition trait. Also note, based on how I created my filesystem, it has a generic "Linux filesystem" PARTLABEL, so if I were to create a new filesystem on a new drive without changing anything, I would have two drives with the same PARTLABEL. This is not an issue unless you try to reference the disk as a PARTLABEL. | Como puede ver en el caso de ''/dev/sdc1'', puede tener una LABEL y PARTLABEL diferente. Esto se debe a que estos se almacenan de forma independiente el uno del otro. LABEL es un rasgo del sistema de archivos, mientras que PARTLABEL es un rasgo de partición. También tenga en cuenta que, en función de cómo creé mi sistema de archivos, tiene un PARTLABEL genérico del "sistema de archivos Linux", por lo que si tuviera que crear un nuevo sistema de archivos en una nueva unidad sin cambiar nada, tendría dos unidades con la misma PARTLABEL. Esto no es un problema a menos que intente hacer referencia al disco como un PARTLABEL. |
| |
If you want to add or change your PARTLABEL, you can do so using ''gdisk'' or ''cgdisk''. | Si desea agregar o cambiar su PARTLABEL, puede hacerlo usando ''gdisk'' o ''cgdisk''. |
| |
=== PartUUID === | === PartUUID === |
| |
This is similar to PartLabel in that it is almost identical to it's not-"Part" counterpart (regular UUID). This UUID is generated automatically whenever you create/resize/move a partition. This will be a different UUID than the one provided by the filesystem. All PartUUIDs can be found under ''/dev/disk/by-partuuid/'' and can be viewed using ''ls -la /dev/disk/by-partuuid/''. | Esto es similar a PartLabel en que es casi idéntico a su contraparte "Parte" (UUID regular). Este UUID se genera automáticamente cada vez que crea/redimensiona/mueve una partición. Este será un UUID diferente al proporcionado por el sistema de archivos. Todos los PartUUID se pueden encontrar en ''/dev/disk/by-partuuid/'' y se pueden ver usando ''ls -la /dev/disk/by-partuuid/''. |
| |
<code>/dev/disk/by-partuuid: | <code>/dev/disk/by-partuuid: |
lrwxrwxrwx 1 root root 10 Jul 31 17:18 468a6e66-39e3-4072-8997-0550dd12ad8e -> ../../sdb1</code> | lrwxrwxrwx 1 root root 10 Jul 31 17:18 468a6e66-39e3-4072-8997-0550dd12ad8e -> ../../sdb1</code> |
| |
As you can see, this is just like PartLabel in that it only shows official PartUUIDs on GPT disks. If you need to view the system generated PartUUID for MBR partitions, you need to use blkid. | Como puede ver, esto es como PartLabel solo muestra los PartUUID oficiales en los discos GPT. Si necesita ver el PartUUID generado por el sistema para particiones MBR, necesita usar blkid. |
| |
<code>slackware@darkstar:~$ su - | <code>slackware@darkstar:~$ su - |
/dev/sda3: UUID="226f1db3-2f14-4862-9998-8be1e8f7cdc9" TYPE="ext4" PARTUUID="6f47c81b-03"</code> | /dev/sda3: UUID="226f1db3-2f14-4862-9998-8be1e8f7cdc9" TYPE="ext4" PARTUUID="6f47c81b-03"</code> |
| |
For non-GPT filesystems, the PARTUUID is generated from the Disk Identifier, followed by the partition number. You can view your Disk Identifier using fdisk. | Para sistemas de archivos que no son GPT, el PARTUUID se genera a partir del Identificador de disco, seguido del número de partición. Puedes ver tu identificador de disco usando fdisk. |
| |
<code>root@darkstar:~# fdisk -l /dev/sda | grep identifier | <code>root@darkstar:~# fdisk -l /dev/sda | grep identifier |
Disk identifier: 0x6f47c81b</code> | Disk identifier: 0x6f47c81b</code> |
| |
<note tip>Due to the newness of GPT support, lilo does not have direct support of calling it, rather you need to use an addappend option (see the lilo.conf section below for further information). For PartUUIDs on MBR disks, the only time they'll change is if additional partitions are created. Keep that in mind if you're using them in your fstab and/or lilo.conf.</note> | <note tip>Debido a la novedad del soporte de GPT, lilo no tiene soporte directo para llamarlo, más bien necesita usar una opción de complemento (vea la sección lilo.conf a continuación para obtener más información). Para PartUUIDs en discos MBR, la única vez que cambiarán es si se crean particiones adicionales. Tenlo en cuenta si los estás usando en tu fstab y / o lilo.conf.</note> |
| |
===== fstab ===== | ===== fstab ===== |
| |
Your ''/etc/fstab'' is the easiest file to change. You simply replace any entries that pointed to your device names with TYPE=value (TYPE can be LABEL, UUID, PARTLABEL, PARTUUID). The original device names are listed as comments for your reference, they don't need to be in the final file. (Personally, since I like it to look nice and neat, I will make everything spaced out evenly.) | Su '' /etc/fstab '' es el archivo más fácil de cambiar. Simplemente reemplace cualquier entrada que apunte a los nombres de su dispositivo con TYPE = value (TYPE puede ser LABEL, UUID, PARTLABEL, PARTUUID). Los nombres de dispositivos originales se enumeran como comentarios para su referencia, no es necesario que estén en el archivo final. (Personalmente, ya que me gusta que se vea bien y ordenado, haré que todo esté espaciado uniformemente). |
| |
<code>slackware@darkstar:~$ cat /etc/fstab | <code>slackware@darkstar:~$ cat /etc/fstab |
===== lilo.conf ===== | ===== lilo.conf ===== |
| |
Your ''/etc/lilo.conf'' takes a bit more finesse to change. Not everything is properly supported like the fstab options, so we need to throw in a few workarounds, depending on what you want to use. | Su '' /etc/lilo.conf '' requiere un poco más de precisión para cambiar. No todo está correctamente soportado como las opciones de fstab, por lo que necesitamos incluir algunas soluciones alternativas, dependiendo de lo que quieras usar. |
| |
To start out, we need to set up the top of your ''/etc/lilo.conf''. This mainly includes the boot entry. This is what lilo uses to determine where to write the bootloader code into the partition table. This is only referenced when you run lilo to install the bootloader, so it won't be as affected as other drives if they're moved. However, if you've already taken the time to get this far, you might as well ensure you don't run into any issues by referencing your drive using persistent naming. | Para comenzar, necesitamos configurar la parte superior de su '' /etc/lilo.conf ''. Esto incluye principalmente la entrada de arranque. Esto es lo que usa lilo para determinar dónde escribir el código del bootloader en la tabla de particiones. Solo se hace referencia a esto cuando ejecuta lilo para instalar el bootloader, por lo que no se verá tan afectado como otras unidades si se mueven. Sin embargo, si ya se ha tomado la molestia de llegar tan lejos, también debería asegurarse de no tener ningún problema al hacer referencia a su unidad utilizando nombres permanentes. |
| |
To do this, we would need to replace ''/dev/sda'' (or whatever your default boot drive is) with a reference that doesn't change. Since we need to reference the drive itself, and not any specific partitions, we need to use the ID method. Once you find the disk ID for your main drive, replace your boot with the full path to the ID. (NOTE: the original /dev/sda is commented out and only there for reference, you don't need to keep it.) | Para hacer esto, deberíamos reemplazar ''/dev/sda '' (o cualquiera que sea su unidad de arranque predeterminada) con una referencia que no cambie. Ya que necesitamos hacer referencia a la unidad en sí, y no a particiones específicas, necesitamos usar el método de ID. Una vez que encuentre la ID del disco para su unidad principal, reemplace su arranque con la ruta completa a la ID. (NOTA: el /dev/sda original está comentado y solo para su referencia, no es necesario que lo guarde). |
| |
<code>#boot = /dev/sda | <code>#boot = /dev/sda |
boot = /dev/disk/by-id/ata-Crucial_CT480M500SSD1_13440956798B</code> | boot = /dev/disk/by-id/ata-Crucial_CT480M500SSD1_13440956798B</code> |
| |
Once you have the boot portion set up, you can then move onto the root partitions for your OSes. | Una vez que haya configurado la parte de arranque, puede moverse a las particiones raíz para sus sistemas operativos. |
| |
==== LABEL and UUID ==== | ==== LABEL and UUID ==== |
| |
To use Labels and UUIDs, you need to use an [[howtos:slackware_admin:kernelbuilding#creating_an_initrd|initrd]]. It won't work without it. Since PARTLABEL in your lilo.conf isn't supported, if you want to use a label there, you will have to use this method. When building your initrd, you need to make sure you pass the -r option to specify your root partition, and set it to either your label or UUID. You can use the ''/usr/share/mkinitrd/mkinitrd_command_generator.sh'' script, although, if you're building it for a kernel version that you're not currently running (but have installed), make sure you pass the kernel version you intend to use to the script using the -k option. It will then spit out a mkinitrd command you can use, which you would just need to adjust the -r option. | Para usar label y UUID, debe usar un [[howtos: slackware_admin: kernelbuilding # creating_an_initrd | initrd]]. No funcionará sin él. Ya que PARTLABEL en su lilo.conf no es compatible, si desea usar una etiqueta allí, tendrá que usar este método. Al crear su initrd, debe asegurarse de pasar la opción -r para especificar su partición raíz y establecerla en su etiqueta o UUID. Puede usar el script '' /usr/share/mkinitrd/mkinitrd_command_generator.sh '', aunque, si lo está compilando para una versión de kernel que no está ejecutando actualmente (pero tiene instalada), asegúrese de pasar la versión del kernel que pretende utilizar en el script mediante la opción -k. A continuación, escupirá un comando mkinitrd que puede usar, que solo tendría que ajustar la opción -r. |
| |
<code>root@darkstar:~# /usr/share/mkinitrd/mkinitrd_command_generator.sh -k 4.4.14 | <code>root@darkstar:~# /usr/share/mkinitrd/mkinitrd_command_generator.sh -k 4.4.14 |
root@darkstar:~#</code> | root@darkstar:~#</code> |
| |
As you'll notice, the command provided by mkinitrd uses ''/dev/sda2'' as the root drive, so we need to change that to match the UUID of the drive before running the mkinitrd command. By default, it will output the ''/boot/initrd.gz'' file, but I prefer to call mine based on the kernel version (which is helpful to ensure you don't overwrite a known-good initrd). When including the root partition in your initrd, it can be removed from lilo, since it won't use it (however, I've left it in but commented it out for visual reference). | Como notará, el comando proporcionado por mkinitrd usa '' /dev/sda2 '' como unidad raíz, por lo que necesitamos cambiarlo para que coincida con el UUID de la unidad antes de ejecutar el comando mkinitrd. De forma predeterminada, generará el archivo '' /boot/initrd.gz '', pero prefiero llamar al mío en función de la versión del kernel (lo cual es útil para garantizar que no sobrescriba un initrd en buen estado). Al incluir la partición raíz en su initrd, puede eliminarse de lilo, ya que no la utilizará (sin embargo, la he dejado pero la he comentado para referencia visual). |
| |
Once you generate an initrd, you need to reference it in your stanza. I don't have any labels set for my primary drive, so I added an example that is commented out. You can use one or the other. As before, I commented out the original device, but it doesn't have to remain in the conf file. | Una vez que genere un initrd, necesita referenciarlo en la sección. No tengo ningún conjunto de etiquetas para mi unidad principal, así que agregué un ejemplo que está comentado. Puedes usar uno u otro. Como antes, comenté el dispositivo original, pero no tiene que permanecer en el archivo conf. |
| |
<note tip>Instead of changing your original stanza, it might be beneficial to keep it there in case you accidentally screw something up and your system doesn't boot, then you can just select your original config and go and fix things and try it again. Once you have verified your system boots properly with your new stanza, if desired, you can remove the old one.</note> | <note tip>En lugar de cambiar su sección original, puede ser beneficioso mantenerlo allí en caso de que accidentalmente estropee algo y su sistema no arranque, entonces puede seleccionar su configuración original e ir a arreglar las cosas y volver a intentarlo. Una vez que haya verificado que su sistema se inicia correctamente con su nueva estrofa, si lo desea, puede eliminar la anterior.</note> |
| |
<code>image = /boot/vmlinuz-generic-3.10.17 | <code>image = /boot/vmlinuz-generic-3.10.17 |
==== PARTUUID ==== | ==== PARTUUID ==== |
| |
Now, as mentioned above, PARTUUID does not require an initrd (although, it works fine if you do use one). However, lilo is old enough that it doesn't have proper support for it, so there is a workaround to get it working. Instead of referencing root like we did above, we need to replace the root option within an "addappend". This will add anything extra to the initial append line at the top of lilo.conf. Keep in mind your spaces, as it will be placed directly afterwards, so it might be wise to include an extra space at the beginning of the line to ensure it doesn't accidentally combine words (which would likely cause a kernel panic and prevent you from booting). For me, since my root partition is on a drive with an MBR, I'll have the shortened PARTUUID instead of the regular 32 character length of a proper PARTUUID. | Ahora, como se mencionó anteriormente, PARTUUID no requiere un initrd (aunque, funciona bien si lo usa). Sin embargo, lilo tiene la edad suficiente para no tener el soporte adecuado para él, así que hay una solución para que funcione. En lugar de hacer referencia a la raíz como hicimos anteriormente, necesitamos reemplazar la opción de la raíz dentro de un "addappend". Esto agregará algo adicional a la línea de adición inicial en la parte superior de lilo.conf. Tenga en cuenta sus espacios, ya que se colocarán directamente después, por lo que puede ser conveniente incluir un espacio adicional al principio de la línea para asegurarse de que no combine palabras accidentalmente (lo que probablemente causaría un pánico en el núcleo y le evitaría desde el arranque). Para mí, dado que mi partición raíz está en una unidad con un MBR, tendré el PARTUUID acortado en lugar de la longitud normal de 32 caracteres de un PARTUUID adecuado. |
| |
<code>image = /boot/vmlinuz-generic | <code>image = /boot/vmlinuz-generic |
label = Slack-default | label = Slack-default |
read-only</code> | read-only</code> |
| <note important> |
| Como se indicó anteriormente, PARTLABEL no es compatible con lilo.</note> |
| |
As noted above, PARTLABEL is not supported with lilo. | ==== Terminando ==== |
| |
==== Finishing Up ==== | |
| |
Once you have your ''/etc/lilo.conf'' file updated, we should test it to make sure there aren't any glaring errors. Lilo has the ability to test a config using the -t option. | Una vez que haya actualizado su archivo '' /etc/lilo.conf '', debemos probarlo para asegurarnos de que no haya errores evidentes. Lilo tiene la capacidad de probar una configuración usando la opción -t. |
| |
<code>root@darkstar:~# lilo -t | <code>root@darkstar:~# lilo -t |
One warning was issued.</code> | One warning was issued.</code> |
| |
The LBA32 warning is normal with Slackware's ''lilo.conf'' and can be ignored (however, you can get rid of it by added ''LBA32'' in the Global section of your ''lilo.conf''). The main thing we're looking for is that all of our stanzas were added and no errors were issued. If that worked, then we can run lilo by itself to finish the process. | La advertencia de LBA32 es normal con '' lilo.conf '' de Slackware y puede ignorarse (sin embargo, puede eliminarla agregando '' LBA32 '' en la sección Global de su '' lilo.conf ''). Lo principal que estamos buscando es que todas nuestras estrofas se agregaron y no se emitieron errores. Si eso funcionó, entonces podemos ejecutar lilo por sí mismo para finalizar el proceso. |
| |
<code>root@darkstar:~# lilo | <code>root@darkstar:~# lilo |
One warning was issued.</code> | One warning was issued.</code> |
| |
If you got this far, go ahead and reboot. Your system should now no longer rely on device names that can easily change. | Si llegaste tan lejos, ve y reinicia. Su sistema ya no debería confiar en nombres de dispositivos que puedan cambiar fácilmente. |
| |
<note important>Final thing to remember, is your device names can change at any time. As should always be the case, whether or not you're using persistent names, before you do anything that may wipe a drive (e.g. ''dd'', ''fdisk'', etc), ensure you are using the correct drive name. You don't want to assume your thumbdrive is ''/dev/sdc'' (because that's what it's always been) before using dd to write that shiny new Slackware64-current iso on there. If your device names have changed, you could be writing that iso to your root partition and take out your whole OS. Use the tools provided above (the various folders under ''/dev/disk/'', ''blkid'', and/or ''dmesg'') to verify what device name you want to use before running the command.</note> | <note important>Lo último para recordar, es que los nombres de sus dispositivos pueden cambiar en cualquier momento. Como siempre debería ser el caso, esté usando o no nombres persistentes, antes de hacer cualquier cosa que pueda borrar una unidad (por ejemplo, '' dd '', '' fdisk '', etc.), asegúrese de estar usando la unidad correcta nombre. No debes asumir que tu unidad de disco es '' / dev / sdc '' (porque eso es lo que siempre ha sido) antes de usar dd para escribir esa nueva versión brillante de Slackware64-current iso allí. Si los nombres de sus dispositivos han cambiado, podría estar escribiendo eso en su partición raíz y eliminando todo su sistema operativo. Utilice las herramientas proporcionadas anteriormente (las diversas carpetas en '' /dev/disk/ '', '' blkid '' y/o '' dmesg '') para verificar qué nombre de dispositivo desea usar antes de ejecutar el comando.</note> |
| |
====== Sources ====== | ====== Fuentes ====== |
<!-- If you are copying information from another source, then specify that source --> | <!-- If you are copying information from another source, then specify that source --> |
<!-- * Original source: [[http://some.website.org/some/page.html]] --> | <!-- * Original source: [[http://some.website.org/some/page.html]] --> |
<!-- Authors are allowed to give credit to themselves! --> | <!-- Authors are allowed to give credit to themselves! --> |
* Originally written by Jeremy Hansen aka [[wiki:user:bassmadrigal | bassmadrigal]] | * Originalmente escrito por Jeremy Hansen alias [[wiki:user:bassmadrigal | bassmadrigal]] |
| * Traducido por: [[wiki:user: slackwarespanol | Victor]] 2019/02/05 16:20 (UTC) |
<!-- * Contributions by [[wiki:user:yyy | User Y]] --> | <!-- * Contributions by [[wiki:user:yyy | User Y]] --> |
| |