This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
informatica:hp_z400_600_centos7_4 [2021/08/19 13:02] miquel [Configurar la connexió amb la consola] |
informatica:hp_z400_600_centos7_4 [2021/08/23 15:16] (current) miquel [Enllaços d'interès] |
||
|---|---|---|---|
| Line 13: | Line 13: | ||
| ===== Crear els comptes d' | ===== Crear els comptes d' | ||
| - | < | + | < |
| - | Crear: nmrsu, nmr, sermnuab...: | + | Comentar la creació dels comptes d' |
| * '' | * '' | ||
| * '' | * '' | ||
| Line 20: | Line 21: | ||
| </ | </ | ||
| - | ===== Configurar | + | ===== Configurar la connexió amb la consola ===== |
| + | |||
| + | La configuració final prevista dels dos dispositius de xarxa és, | ||
| + | |||
| + | * dispositiu '' | ||
| + | * dispositiu '' | ||
| + | |||
| + | |||
| + | <WRAP tip> | ||
| + | Tot i que la connexió a la xarxa de la UAB es podria configurar via DHCP, he vist que, en alguns casos molt esporàdics, | ||
| + | </ | ||
| - | Canvio | + | ==== Problemes amb la configuració |
| - | La configuració | + | Per canviar la connexió a la xarxa de la UAB de DHCP a manual, començo per consultar els paràmetres de la configuració per DHCP, |
| < | < | ||
| Line 196: | Line 207: | ||
| </ | </ | ||
| - | i reiniciar la xarxa un cop més, | + | i reiniciar la xarxa un cop més. |
| - | Malauradament el problema segueix sense resoldre' | + | Malauradament el problema segueix sense resoldre' |
| + | ==== Configuració de la xarxa UAB ==== | ||
| + | Començo per configurar el dispositiu '' | ||
| + | < | ||
| + | # nmcli general status | ||
| + | STATE CONNECTIVITY | ||
| + | connected | ||
| + | # nmcli general hostname | ||
| + | cie-56-18.uab.cat | ||
| - | #### Enllaços d' | + | # nmcli connection show --active |
| + | NAME | ||
| + | UAB-LAN | ||
| - | # 10 Useful " | + | # nmcli connection show id UAB-LAN |
| - | https://www.tecmint.com/ip-command-examples/ | + | connection.id: UAB LAN |
| - | # centos 7 - How to enable network adapter in centOS7 minimal? | + | connection.uuid: be7bd600-74cb-49ef-919f-c3c027459391 |
| - | https://superuser.com/ | + | connection.stable-id: |
| - | # How to Configure CentOS Network Settings {via terminal or GUI) | + | connection.type: |
| - | https:// | + | [...] |
| - | # How to Configure CentOS 7 Network Settings - Serverlab | + | connection.permissions: user: |
| - | https://www.serverlab.ca/tutorials/ | + | [...] |
| + | 802-3-ethernet.mac-address: | ||
| + | [...] | ||
| + | GENERAL.NAME: | ||
| + | GENERAL.UUID: | ||
| + | GENERAL.DEVICES: | ||
| + | GENERAL.STATE: | ||
| + | GENERAL.DEFAULT: | ||
| + | [...] -- | ||
| + | IP4.ADDRESS[1]: | ||
| + | IP4.GATEWAY: | ||
| + | IP4.ROUTE[1]: | ||
| + | IP4.ROUTE[2]: | ||
| + | IP4.DNS[1]: | ||
| + | IP4.DNS[2]: | ||
| + | IP4.DOMAIN[1]: | ||
| + | DHCP4.OPTION[1]: | ||
| + | [...] | ||
| + | DHCP4.OPTION[9]: | ||
| + | DHCP4.OPTION[10]: | ||
| + | [..] | ||
| + | DHCP4.OPTION[30]: | ||
| + | DHCP4.OPTION[31]: | ||
| + | [...] | ||
| + | </file> | ||
| + | per la nova configuració estàtica, | ||
| + | < | ||
| + | # cd / | ||
| + | # cat ifcfg-UAB-LAN | ||
| + | HWADDR=3C: | ||
| + | TYPE=Ethernet | ||
| + | PROXY_METHOD=none | ||
| + | BROWSER_ONLY=no | ||
| + | ETHTOOL_OPTS=" | ||
| + | BOOTPROTO=none | ||
| + | DEFROUTE=yes | ||
| + | IPV4_FAILURE_FATAL=yes | ||
| + | IPV6INIT=no | ||
| + | NAME=UAB-LAN | ||
| + | UUID=be7bd600-74cb-49ef-919f-c3c027459391 | ||
| + | ONBOOT=no | ||
| + | USERS=sermnadmin | ||
| + | IPADDR=158.109.56.18 | ||
| + | PREFIX=20 | ||
| + | GATEWAY=158.109.48.0 | ||
| + | DNS1=158.109.254.130 | ||
| + | DNS2=158.109.0.36 | ||
| + | DOMAIN=uab.es | ||
| + | </ | ||
| + | |||
| + | ==== Configuració de la xarxa de l' | ||
| + | |||
| + | Pel dispositiu de la xarxa de l' | ||
| + | |||
| + | < | ||
| + | # ping -c 5 spect | ||
| + | PING spect (149.236.99.90) 56(84) bytes of data. | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | |||
| + | --- spect ping statistics --- | ||
| + | 5 packets transmitted, | ||
| + | rtt min/ | ||
| + | </ | ||
| + | |||
| + | El fitxer de configuració d' | ||
| + | |||
| + | < | ||
| + | # cat ifcfg-CONSOLE-LAN | ||
| + | ZONE=trusted | ||
| + | USERCTL=no | ||
| + | NETMASK=255.255.255.0 | ||
| + | DEVICE=enp55s9 | ||
| + | TYPE=Ethernet | ||
| + | PROXY_METHOD=none | ||
| + | BROWSER_ONLY=no | ||
| + | BOOTPROTO=none | ||
| + | DEFROUTE=yes | ||
| + | IPV4_FAILURE_FATAL=yes | ||
| + | IPV6INIT=no | ||
| + | IPV6_AUTOCONF=yes | ||
| + | IPV6_DEFROUTE=yes | ||
| + | IPV6_FAILURE_FATAL=no | ||
| + | IPV6_ADDR_GEN_MODE=stable-privacy | ||
| + | NAME=" | ||
| + | UUID=227b37f9-5a73-4dfb-9ad4-60924a6fe3d9 | ||
| + | ONBOOT=yes | ||
| + | HWADDR=1C: | ||
| + | IPADDR=149.236.99.1 | ||
| + | PREFIX=24 | ||
| + | </ | ||
| + | |||
| + | ==== Comprovació de les rutes ==== | ||
| + | |||
| + | Un cop els dos dispositius de xarxa estan en funcionament, | ||
| + | |||
| + | < | ||
| + | # nmcli device status | ||
| + | DEVICE | ||
| + | enp1s0 | ||
| + | enp55s9 | ||
| + | lo | ||
| + | |||
| + | # ping -c 5 spect | ||
| + | PING spect (149.236.99.90) 56(84) bytes of data. | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | 64 bytes from spect (149.236.99.90): | ||
| + | |||
| + | --- spect ping statistics --- | ||
| + | 5 packets transmitted, | ||
| + | rtt min/ | ||
| + | |||
| + | # ping -c 5 gw.uab.cat | ||
| + | PING gw.uab.cat (158.109.0.3) 56(84) bytes of data. | ||
| + | 64 bytes from gw.uab.es (158.109.0.3): | ||
| + | 64 bytes from gw.uab.es (158.109.0.3): | ||
| + | 64 bytes from gw.uab.es (158.109.0.3): | ||
| + | 64 bytes from gw.uab.es (158.109.0.3): | ||
| + | 64 bytes from gw.uab.es (158.109.0.3): | ||
| + | |||
| + | --- gw.uab.cat ping statistics --- | ||
| + | 5 packets transmitted, | ||
| + | rtt min/ | ||
| + | </ | ||
| + | |||
| + | comprovo les rutes definides i veig que són les correctes, | ||
| + | |||
| + | < | ||
| + | # route | ||
| + | Kernel IP routing table | ||
| + | Destination | ||
| + | default | ||
| + | 149.236.99.0 | ||
| + | 158.109.48.0 | ||
| + | |||
| + | # route -n | ||
| + | Kernel IP routing table | ||
| + | Destination | ||
| + | 0.0.0.0 | ||
| + | 149.236.99.0 | ||
| + | 158.109.48.0 | ||
| + | </ | ||
| + | |||
| + | ==== Enllaços d' | ||
| + | |||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | |||
| + | ===== Eliminar els kernels més antics ===== | ||
| + | |||
| + | Al llarg del procés d' | ||
| + | |||
| + | < | ||
| + | # uname -snr | ||
| + | Linux cie-56-18.uab.cat 3.10.0-1160.36.2.el7.x86_64 | ||
| + | |||
| + | # awk -F\' ' | ||
| + | 0 : CentOS Linux (3.10.0-1160.25.1.el7.x86_64) 7 (Core) | ||
| + | 1 : CentOS Linux (3.10.0-1160.36.2.el7.x86_64) 7 (Core) | ||
| + | 2 : CentOS Linux (3.10.0-1160.21.1.el7.x86_64) 7 (Core) | ||
| + | 3 : CentOS Linux (3.10.0-1160.el7.x86_64) 7 (Core) | ||
| + | 4 : CentOS Linux (0-rescue-0f254d22a67c404692c5df67336e787a) 7 (Core) | ||
| + | 5 : Debian GNU/Linux (8.11) (on /dev/sda3) | ||
| + | </ | ||
| + | |||
| + | i ara ocupen espai a la partició '' | ||
| + | |||
| + | < | ||
| + | # df -hl | ||
| + | Filesystem | ||
| + | [...] | ||
| + | / | ||
| + | / | ||
| + | [...] | ||
| + | </ | ||
| + | |||
| + | Per eliminar els més antics, faig servir la comanda ''# | ||
| + | |||
| + | < | ||
| + | # package-cleanup --oldkernels --downloadonly | ||
| + | Loaded plugins: fastestmirror, | ||
| + | --> Running transaction check | ||
| + | ---> Package kernel.x86_64 0: | ||
| + | ---> Package kernel.x86_64 0: | ||
| + | ---> Package kernel-devel.x86_64 0: | ||
| + | ---> Package kernel-devel.x86_64 0: | ||
| + | --> Finished Dependency Resolution | ||
| + | |||
| + | Dependencies Resolved | ||
| + | |||
| + | ====================================================================================================================== | ||
| + | | ||
| + | ====================================================================================================================== | ||
| + | Removing: | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | |||
| + | Transaction Summary | ||
| + | ====================================================================================================================== | ||
| + | Remove | ||
| + | |||
| + | Installed size: 205 M | ||
| + | Background downloading packages, then exiting: | ||
| + | exiting because " | ||
| + | </ | ||
| + | |||
| + | Un cop convençut dels canvis proposats, executo la comanda '' | ||
| + | |||
| + | < | ||
| + | # package-cleanup --oldkernels | ||
| + | Loaded plugins: fastestmirror, | ||
| + | --> Running transaction check | ||
| + | ---> Package kernel.x86_64 0: | ||
| + | ---> Package kernel.x86_64 0: | ||
| + | ---> Package kernel-devel.x86_64 0: | ||
| + | ---> Package kernel-devel.x86_64 0: | ||
| + | --> Finished Dependency Resolution | ||
| + | |||
| + | Dependencies Resolved | ||
| + | |||
| + | ====================================================================================================================== | ||
| + | | ||
| + | ====================================================================================================================== | ||
| + | Removing: | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | |||
| + | Transaction Summary | ||
| + | ====================================================================================================================== | ||
| + | Remove | ||
| + | |||
| + | Installed size: 205 M | ||
| + | Is this ok [y/N]: y | ||
| + | Downloading packages: | ||
| + | Running transaction check | ||
| + | Running transaction test | ||
| + | Transaction test succeeded | ||
| + | Running transaction | ||
| + | Erasing | ||
| + | Erasing | ||
| + | Erasing | ||
| + | Erasing | ||
| + | Verifying | ||
| + | Verifying | ||
| + | Verifying | ||
| + | Verifying | ||
| + | |||
| + | Removed: | ||
| + | kernel.x86_64 0: | ||
| + | kernel-devel.x86_64 0: | ||
| + | |||
| + | Complete! | ||
| + | </ | ||
| + | |||
| + | i comprovo l' | ||
| + | |||
| + | < | ||
| + | # df -hl | ||
| + | Filesystem | ||
| + | [...] | ||
| + | / | ||
| + | / | ||
| + | [...] | ||
| + | </ | ||