Thursday, May 2, 2024
 Popular · Latest · Hot · Upcoming
2
rated 0 times [  2] [ 0]  / answers: 1 / hits: 8876  / 3 Years ago, thu, july 22, 2021, 12:50:42

I installed Ubuntu server 12.04 about 2 weeks ago. It had been working well and running 24/7 until I accidentally restarted it yesterday. Shouldn't have been a problem, yet now it just sits at a black screen. It's not a screen-has-no-signal black screen, it looks like it's actually displaying black all around.



Some facts:




  • It doesn't seem to be connecting to the network.

  • The keyboard NumLock key works.

  • Ctrl+Alt+Del key combination works.

  • The screen is working correctly. I can see the BIOS screens and I can boot into a live USB drive.

  • I recall rebooting the system a few times after I installed it and it was working fine, aside for the fact that the screen would remain at the Ubuntu logo, so I would have to Alt+F2 into another terminal to log in. Everything else was fine.



System:




  • P8H77-I motherboard (using on-board video)

  • 2x ssd drives in raid 1 (using mdadm)

  • Using Grub



The last thing I did before rebooting it was run apt-get update then apt-get upgrade but I don't remember seeing any kernel-related packages in the list.



I've booted from a "live" USB drive I made in order to install Ubuntu, however, I remember having a whole lot of trouble as I had to mount the CD image manually in order to install. I might have to get a real DVD drive and boot off that, but I don't have any optical media :|



Please let me know if you need any more info to help me troubleshoot.



Thanks in advance!



What have I tried?




  • I have tried holding F6 to get into GRUB

  • I have tried booting off a live drive. I believe I have to set "nomodeset" or something, but I don't know how to do that off a live CD on a raided system. Plus, this wouldn't explain why I was able to reboot before but not now.

  • I am aware of similar questions, but this is different because it's not happening right after install.. It rebooted a few times after install, ran for awhile, then this.


More From » 12.04

 Answers
6

I was able to resolve this issue after a few hours of battling it. It was unfortunate that so many seemingly related questions were caused by something else, so it took some guessing and trial and error to get it working.



First of all, I gather that the issue was that grub was failing to load /vmlinuz or /initrd.img and crashing before anything got to the screen. I believe that running apt-get upgrade at some point had updated the kernel and had not updated grub's settings.



What worked for me:



I booted off an ubuntu server 12.04 live CD and went into "Rescue a broken system". From there I went and selected "assemble raid array automatically", selected my root partition (the raid e.g. /dev/md0) and chose to go on a chroot shell on that directory.



From the shell I had to:




  • Regenerate mdadm's config: mdadm --detail --scan > /etc/mdadm/mdadm.conf

  • re-install grub:

    • grub-install /dev/sda

    • grub-install /dev/sdb


  • Update grub: update-grub

  • Update initramfs: update-initramfs <--- I believe this was the crucial part.



I then restarted the system and boom. Good to go.



P.S. This other question had some important background information that helped me. I did the kernel re-install bit from there, but it didn't work as that was not the problem.


[#32030] Friday, July 23, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ippalogu

Total Points: 215
Total Questions: 127
Total Answers: 146

Location: Denmark
Member since Tue, Jul 19, 2022
2 Years ago
;