Debian: Zistite a zmeňte názov hostiteľa
Názov hostiteľa môžete zobraziť a zmeniť pod Debianom. Ukážeme vám postupné kroky.
Zobraziť názvy hostiteľov pod Debianom
- Otvorte terminál a do príkazového riadka zadajte „hostname“.
- Príkaz "hostname -f" vydá úplný názov hostiteľa sam FQDN (plne kvalifikovaný názov domény).
Debian: zmena názvu hostiteľa - takže to bude fungovať
Názov hostiteľa môžete zmeniť pod Debianom počas prevádzky alebo natrvalo.
- Ak chcete počas prevádzky zmeniť názov hostiteľa, zadajte do terminálu príkaz „hostname“ a za ním nový názov. Príkaz je „názov hostiteľa NEWER_NAME“.
- Ak chcete natrvalo zmeniť názov hostiteľa, môžete ho upraviť pomocou ľubovoľného editora. Názov hostiteľa je v súbore "/ etc / hostname".
- Aby bolo možné vykonať zmenu okamžite, jednoducho použite skript, ktorý sa spustí aj pri spustení systému. Ak to chcete urobiť, do terminálu zadajte „/etc/init.d/hostname.sh“.
Vedeli ste? Preto je Linux rozšírenejší ako Windows
V nasledujúcom praktickom tipe si vysvetlíme, ako aktualizovať Debian.