Showing posts with label GRUB. Show all posts
Showing posts with label GRUB. Show all posts

15/08/2018

[Ubuntu] Revert kernel back to older version

Intro story: So much luck in a single day.

I always keep only 2 kernel versions after every update, so that I can boot back if something goes wrong. This usually helps, except today I decided to upgrade my Ubuntu from 16.04 to 18.04 since I like spending my nights fixing stuff after unnecessary upgrades, but hey, the future is there.

So I first fully updated my current installation (1st kernel bump), then migrated to the new one (2nd kernel bump) and it turns out I got two 4.15 kernels, with only different minor version.

Double interesting, my wireless card:

02:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8821AE 802.11ac PCIe Wireless Network Adapter

apparently has issues (read: bug) with kernel 4.15 preventing it from working at all (not even connected to the router), and even more interesting, on one version it can actually only connect to websites under google.com domain..

Anyway, quick fix was to revert back my kernel, here is how for future me to remember:
  1. go to http://kernel.ubuntu.com/~kernel-ppa/mainline/ and download in the same folder: linux-headers-VERSION-generic-XXX_SYSTEM.deb, linux-headers-VERSION_all.deb, linux-image-VERSION-generic-XXX_SYSTEM.deb for your system, eg I have 64 bit system and got amd64 files
  2. install them by going into the folder where you downloaded them, make sure there are only those three .deb files and run: sudo dpkg -i *.deb
  3. restart the system, then press SHIFT at boot to enter the GRUB choices, then check from the top line (number 0) to the line of your kernel version. If your installation has the "Advanced" menu entry and does not display all kernels, go there and do the same counting. We need this to set a default GRUB entry to always boot in this kernel
  4. edit /etc/default/grub and change the value of GRUB_DEFAULT to the number you counted OR to (exactly as shown) "1>N" if you have the "Advanced" menu option. This means you want to boot into the Nth entry (starting from 0) under the "Advanced" menu. Also set GRUB_TIMEOUT to some value in seconds that's more than 1, to have some time to block the boot process in case of mistakes
  5. run sudo update-grub and you are set
Note that this is a TEMPORARY fix, you would not want to have a fully updated system run on an older version of the kernel, mainly because some obscure dependency or feature might be missing/not working, therefore check back periodically to see if your issue has been addressed and try the latest kernel version out!


04/06/2016

[Ubuntu] fix plymouthd splash load boot error

We sometimes struggle to keep up with all the things that are constantly evolving, so I like how Ubuntu still gives us reassurances that some important features are cemented in its core, such as the plymouthd boot splash error: "plymouthd could not load boot splash: could not access needed shared library".

Just update the kernel and you might be the lucky winner that gets stuck at boot.

The fix is easy and fast enough though. The immediate thing you can try is to edit the boot options when GRUB presents you the list of boot choices:
  1. select the Ubuntu line corresponding to the kernel you want to boot and press the e key
  2. find the line where the ro quiet splash parameters are set (unless you have already changed them in the past), but then you know which line I'm talking about anyway ;)
  3. remove the splash parameter
  4. add at the end of the line: gfxpayload=keep
  5. press F10 to boot

13/02/2015

[Linux] Boot in console mode

So you absolutely wanted that fancy video driver to work, but it didn't. Now it's impossible to boot into your system, even with the Ctrl+Alt+FX combination to get a tty to show up.

You can however boot directly into console mode. From the GRUB menu, before selecting a line to boot, press the "e" key.

Find the line you were going to boot (usually starts with "linux") and replace:

rgba quiet or rgbh quiet or the similar parameter you may have

with:

text 3

or another number which will be the runlevel of your choice.

Then press F10 to boot from that configuration or save, select the modified line and press enter.

Once you're logged in your console you can always try to start the graphical environment with:

startx

[CentOS] Detect Windows installation and update GRUB

After installing CentOS on your wannabe dual-boot machine, you realize with horror that for very important and critical reasons, your system does not have a dual boot menu and it's not able to recognize and read the Windows partition.

The solution is luckily very simple:

yum install epel-release
yum install ntfs-3g

This will allow the system to correctly manage NTFS filesystems.

grub2-mkconfig -o /boot/grub2/grub.cfg

This will update GRUB so that it shows the dual boot options now that it's able to recognize the Windows partition.

grub2-set-default X

This is optional and it's used to set the X kernel/OS as default when starting the system. You can find the number by reading the file /boot/grub2/grub.cfg

20/04/2009

Install Ubuntu on Windows using Wubi / Installare Ubuntu su Windows usando Wubi

IN ENGLISH:

In this guide we’re going to see how to install Ubuntu as a Windows app, and boot it via Windows bootloader. The procedure is fast and easy but there are some limitations:

  • Hibernation is not supported.
  • Wubi filesystem is more vulnerable to hard reboots (unplugging the power) than a normal filesystem.
  • Since Wubi installs Ubuntu on the same file partition as Windows, Ubuntu may see a slight degradation in performance over time due to FAT32/NTFS file fragmentation, which could possibly be alleviated via defragging the disk.

So why using Wubi?

  • No need to do anything for new users, just type username and password and press install, next reboot you’ll have the choice to use Windows or Ubuntu
  • Easy to uninstall as a Windows app
  • It doesn’t overwrite your MBR, so it’s less dangerous than installing GRUB directly
  • Installation process is faster
  • Possibility to choose which Ubuntu version to install

Let’s get started.

  1. Download Wubi.
    1. (optional) Pre-download the .iso version of Ubuntu you want. You may skip this step if you own the Ubuntu CD you want to install, or if you want Wubi to download it for you. Please note that Wubi will download the appropriate image for your architecture, this means if you’ve a 64-bit architecture it’ll download a 64-bit Ubuntu. If you want to make it pick the 32-bit version, run Wubi with the --32bit flag. See FAQ for further info.
  2. If you’ve downloaded the .iso, place it in the same folder as wubi.exe, if you own the CD, put it in the drive. Now launch wubi.exe.
  3. Select all the options you desire (remember to enter a password), then click install.
  4. When prompted to reboot, do it and when you get the choice to run either Windows or Ubuntu, choose Ubuntu to complete the installation.
  5. Done!. :)

To uninstall Ubuntu, simply do it from Windows control panel.

Note that there’s the Portable Ubuntu project that allows you to install AND run Ubuntu as a Windows app. It’s less tested but you might want to give it a try.

 

IN ITALIANO:

In questa guida vedremo come installare Ubuntu come se fosse un’applicazione Windows, e bootarlo successivamente tramite il bootloader di Windows. La procedura è semplice e veloce ma ci sono delle limitazioni:

  • L’ibernazione non è supportata.
  • Il filesystem di Wubi è più vulnerabile agli hard reboot (staccare la corrente) di un normale filesystem.
  • Dal momento che Wubi installa Ubuntu nella stessa partizione di Windows, le performance potrebbero degradare nel tempo a causa della frammentazione dei file nel filesystem FAT32/NTFS, che si puo’ pero’ risolvere deframmentando il disco.

Allora perchè usare Wubi?

  • Nessuna necessità di fare qualcosa da parte dei nuovi utenti, semplicemente inserite nome utente e password e cliccate installa, al prossimo riavvio avrete la possibilità di usare Windows o Ubuntu
  • Facile da disinstallare quanto un’applicazione Windows
  • Non sovrascrive l’MBR, quindi è meno pericoloso che installare il GRUB
  • Il processo di installazione è più rapido
  • SI puo’ scegliere quale versione di Ubuntu installare

Ok, cominciamo.

  1. Scaricate Wubi.
    1. (opzionale) Pre-scaricate la versione di Ubuntu desiderata. Potete saltare questo passo se possedete il CD di Ubuntu o se volete che sia Wubi a scaricarla per voi. Ricordate che Wubi scaricherà la versione di Ubuntu adatta per la vostra architettura, quindi se avete un’architettura a 64-bit lui prenderà Ubuntu a 64bit. Se volete che usi la versione a 32-bit, lanciate Wubi con il flag –32bit. Leggete le FAQ per più info.
  2. Se avete scaricato la .iso, mettetela nella stessa cartella di wubi.exe, se avete il CD, inseritelo nel lettore. Lanciate wubi.exe.
  3. Selezionate tutte le opzioni che desiderate(ricordate di inserire una password), e premete installa.
  4. Quando vi si richiederà di riavviare, fatelo e quando potrete scegliere tra Windows o Ubuntu, scegliete Ubuntu per completare l’installazione.
  5. Finito!. :)

Per disnstallare Ubuntu, fatelo semplicemente dal pannello di controllo di Windows.

Sappiate che esiste un progetto Portable Ubuntu che vi permette di installare E far girare Ubuntu come se fosse un’applicazione Windows. E’ meno testato, ma potreste volerci dare un’occhiata. La guida è in inglese ma dovrebbe essere facile seguirla poichè è ben completa di immagini. Non so se mai la tradurro’ :)

04/04/2009

Remove GRUB from Vista

For those who are encountering problems removing GRUB from Windows Vista (32 or 64 bit), just follow these steps:

  1. download and extract this archive: Systemintegrasjon AS' MbrFix
  2. remember to look at the readme if something doesn't seem clear
  3. go into the directory you extracted the files in by command console: start->run->cmd->enter
  4. type: cd \directoryinwhichyouextracted\
  5. type: C:\> MbrFix /drive 0 fixmbr /vista /yes
  6. done :)
  7. remember to fuck off all those fake linux nerds who keep saying to use fixmbr
Per coloro che avessero problemi nel rimuovere GRUB da Windows Vista (32 o 64 bit), basta seguire questi passi:
  1. scaricate ed estraete questo archivio: Systemintegrasjon AS' MbrFix
  2. recatevi nella cartella dove avete estratto i file mediante console comandi: start->esegui->cmd->invio (attenzione che Vista la cartella Programmi passando da console la chiama "Program Files")
  3. digitate: cd \cartellaincuiaveteestratto\
  4. digitate: C:\> MbrFix /drive 0 fixmbr /vista /yes
  5. fine :)
  6. ricordatevi di fanculizzare tutti quei finti nerd di linux che continuano a dire di usare fixmbr

 

 

Thanks to Systemintegrasjon for MbrFix!