Deprecated: Creation of dynamic property Timber\Site::$pingback is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Site.php on line 180

Deprecated: Creation of dynamic property Timber\User::$name is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/User.php on line 118

Deprecated: Creation of dynamic property Timber\Post::$has_disclaimer is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_edit_lock is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_edit_last is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$onesignal_meta_box_present is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$onesignal_send_notification is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$onesignal_modify_title_and_content is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$onesignal_notification_custom_heading is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$onesignal_notification_custom_content is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$tipologia is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_tipologia is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$attributi is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_attributi is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$in_evidenza_newsletter is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_in_evidenza_newsletter is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$inviato_in_newsletter is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_inviato_in_newsletter is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_primary_category is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_primary_blz_affiliation_attributes is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_primary_content_type is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_primary_attributes is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_primary_speciali is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_focuskw is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_metadesc is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_linkdex is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_content_score is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_focuskeywords is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_keywordsynonyms is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_estimated-reading-time-minutes is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_wpseo_wordproof_timestamp is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_thumbnail_id is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$response_body is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$status is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$_yoast_indexnow_last_ping is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_date_gmt is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$comment_status is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$ping_status is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_password is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_name is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$to_ping is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$pinged is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_modified is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_modified_gmt is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_content_filtered is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$guid is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$menu_order is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$post_mime_type is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$comment_count is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71

Deprecated: Creation of dynamic property Timber\Post::$filter is deprecated in /var/www/html/web/app/themes/ilsoftware/vendor/timber/timber/lib/Core.php on line 71
Cambiare password dimenticata su Linux: ci vogliono solo 5 minuti | IlSoftware.it

Cambiare password dimenticata su Linux: ci vogliono solo 5 minuti

Due semplici procedure che permettono di cambiare la password dimenticata su Linux, per qualsiasi account presente sulla macchina in uso.

La disponibilità fisica di un computer da parte di un aggressore, espone i dati dell’utente a rischio di furto. A meno che il contenuto delle unità non sia protetto attraverso meccanismi crittografici affidabili. In questo articolo vediamo com’è semplice cambiare la password dimenticata su Linux: una procedura che richiede appena 5 minuti di tempo.

L’unico passaggio importante per modificare la password di qualunque account utente Linux, consiste nell’accedere a GRUB, noto bootloader utilizzato per avviare i sistemi operativi. GRUB consente di scegliere la piattaforma da avviare al boot del computer.

I passaggi illustrati di seguito si riferiscono alla distribuzione Linux Ubuntu ma gli stessi meccanismi sono di fatto applicabili su qualunque altra distro del pinguino.

Come cambiare una password dimenticata su Linux

Per forzare il cambio password all’avvio del PC, è innanzi tutto necessario accedere al menu di boot di GRUB. La schermata principale di GRUB si presenta in maniera molto simile a quella rappresentata in figura. Nel caso in cui GRUB non dovesse apparire, si può premere il tasto MAIUSC oppure più volte ESC, fino alla comparsa dello stesso menu.

Menu avvio GRUB Linux

A questo punto, usando i tasti freccia, bisogna selezionare l’opzione di avvio Advanced options (è evidenziata nella figura riportata poco sopra). Nella schermata seguente, è necessario accertarsi di scegliere la voce che riporta Recovery mode tra parentesi, premendo quindi il tasto Invio.

Recovery mode Linux

Agendo sul successivo Menu ripristino, si deve selezionare Root e premere Invio in modo tale da aprire una shell con i privilegi utente più elevati. Nella parte inferiore, viene visualizzato il messaggio Press Enter for maintenance: è sufficiente servirsi del tasto Invio per proseguire, quindi digitare il comando seguente:

mount -rw -o remount /

Cambiare password dimenticata su Linux

Il comando provvede ad abilitare i permessi di scrittura sulla partizione root: per impostazione predefinita, infatti, l’accesso è possibile solo in lettura. Il riferimento -rw (read/write) è inequivocabile.

Digitando ls /home, si ottiene la lista degli account utente presenti sulla macchina. Questo passaggio è utile per verificare il nome esatto dell’utente di cui si vuole cambiare la password. Nell’esempio, cambiamo la password dell’account michele.

Cambio password comando passwd Linux

Il comando passwd, seguito dal nome dell’account, consente di modificare la password (non è necessario conoscere la password già impostata). Nel caso in cui la password indicata non fosse sufficientemente sicura, Linux mostra un messaggio di avviso.

Da ultimo, digitando exit quindi scegliendo resume, si può richiedere il normale avvio della distribuzione Linux installata. Scegliendo l’account del quale si era dimenticato la password e digitando quella appena scelta, sarà possibile accedere al desktop.

Usare l’editor di GRUB per cambiare la password dimenticata

Un approccio leggermente diverso per modificare la password dimenticata per qualsiasi account utente Linux, consiste nell’attendere la comparsa del menu di GRUB all’avvio della macchina quindi nel premere il tasto E per accedere all’editor del bootloader.

In corrispondenza della riga che inizia per linux, si deve individuare la stringa ro (read only) e modificarla in rw (read/write). Al termine della stessa riga, inoltre, si deve aggiungere init=/bin/bash.

Quest’ultimo intervento, indica al kernel Linux di avviare direttamente una shell bash al boot, anziché eseguire il normale processo di inizializzazione del sistema. Questo significa che, una volta avviato il sistema, GRUB presenta la bash, senza che vengano avviati i servizi di sistema o altre componenti software.

Editor GRUB avvio Linux

Va tenuto presente che il layout di tastiera può in questo caso creare qualche problemino. Il simbolo dell’uguale (=) si ottiene premendo il tasto ^/ì sulla tastiera italiana; la barra rovesciata (/) si ottiene premendo il tasto -/_.

Premendo infine la combinazione di tasti CTRL+X, il sistema si riavvia mostrando la shell bash.

Cambio password bash Linux

Il comando passwd, seguito dal nome dell’account, consente di definire una nuova password. In questo caso, suggeriamo di evitare l’utilizzo di simboli speciali all’interno della password. Il layout di tastiera potrebbe infatti giocare brutti scherzi. Suggeriamo quindi di servirsi solamente di lettere e numeri, provvedendo infine a riavviare la macchina Linux.

Credit immagine in apertura: iStock.com – gdainti

Ti consigliamo anche

Link copiato negli appunti