Thursday, October 31, 2019

icons - How do you get a *.desktop file to work for a non-repository app?

I turned the Amazon cloud reader site https://read.amazon.com into a desktop app with nativefier. It works amazingly well as a standalone reader for books that have been downloaded and also automatically downloads books in the cloud when requested.


Instead of launching /home/myname/kindle-web-linux-x64/kindle-web from the console all the time, I tried to make a Kindle-Web desktop file to place in the launcher. My file won't work in two ways:



  1. It won't launch Kindle-Web.

  2. It does not display the Kindle icon on the file when viewed in Nautilus.


The code is below. Can anyone tell me where I went wrong. The icon files are in /home/myname/.local/share/icons/hicolor/, and /home/myname/.icons/hicolor/*.



[Desktop Entry]
Version=1.0
Name=Kindle-Web
Comment=Desktop app created from Kindle Cloud Reader page (https://read.amazon.com) by nativefier
Exec=/home/myname/kindle-web-linux-x64/kindle-web
Path=/home/myname/
# StartupNotify=true
# StartupWMClass=kindle-web
Icon=0914_Kindle.0
# Terminal=false
Type=Application
Categories=Publishing;Literature;Documentation;Office;

system installation - Can't launch windows 8, trying to use Ubuntu

Alright, so I have no idea if I'm even posting this properly so here goes nothing.



I guess I cold halted and it messed up my hard drive, leaving me stuck on a repair screen that never works. I tried booting with the Windows 8 disk I had to reinstall, but I need a product code I no longer have.



I found (using Hiren's bootCD) that all my files had been moved to a found.000 folder, which seems to be the problem. I'm unsure if my hard drive is actually broken though. I used the chksys command (can't remember the actual name for the life of me), but it didn't work, so I'm feeling the hard drive might be broken.



I'm left with either buying an ssd to replace the hard drive, or another Windows 8, unsure if either would work. I decided that instead of buying a new Windows, I would just make a bootable ubuntu disc and install Ubuntu instead of reinstalling Windows.



The problem is, unlike when I boot up through the windows disc to reinstall, booting through the linux disc doesn't work. It seems to be ignored and I get sent to the perpetually failing Windows auto repair.




Why can't I boot through the ubuntu disc? I downloaded the iso and burned it to a CD-R. Is it because my hard drive is broken?



As you can see, I'm pretty noob, so any help would be greatly appreciated.



tl; dr: Can't boot through ubuntu installation disc, need help.

11.04 - Enable HDMI audio for an Nvidia card

I am using a GTX470 with an HDMI output, this card is able to handle the video and audio. I have no issues with the video but I get no sound. Is there a guide to enable sound on this card through hdmi that could be written out or I could be guided to. Thanks!

bash - How to invoke a text file as a list of commands

Problem: 245,000 plus files residing in multiple recup_dir folders (output from photo_rec run) needing to be moved to a centralized folder for further recovery operations. All files are *.jpg files.



I have a text file named newlist1.txt that I have formatted in the following 4 ways. And to change to each variety, a good find/replace editor is essential. these script files are in a folder /disks/Keep/new-s1-recov. I know, I could have used just . to indicate where to mv the files, but initially, the scripts were in another folder, and the period would not have sufficed.




  1. echo !(recov1/recup_dir.1033/f340010.jpg)| xargs mv -t /disks/Keep/new-s1-recov


  2. echo !recov1/recup_dir.1034/f3442050jpg| xargs mv -t /disks/Keep/new-s1-recov


  3. echo recov1/recup_dir.1034/f344208.jpg| xargs mv -t /disks/Keep/new-s1-recov


  4. ls recov1/recup_dir.1034/f344208.jpg| xargs mv -t /disks/Keep/new-s1-recov





the last two examples, 3 & 4, work correctly when executed from the command line.
None of the examples work when I type



sh newlist1.txt


or




bash newlist1.txt


The thing is, I have over 245000 files that need to be moved. Why don't I use the file manager and do groups of several hundred at a time? Because the file manager is possibly the worst piece of software in Ubuntu 16.04.3. So, the command line is the preferable way of accomplishing this task. If I spend several days figuring out how to get it done like this, I'll consider it time well spent. I have wasted more than that on the file manager, waiting for the screen to come out of its seeming daze and finally show that the movement of several files has finally been accomplished.



The formatting above was taken from other examples I found at various times. I tried to adapt my problem to someone else's solution.



So, the question is: How do I format the 245000 lines (using nano texteditor which has a find/replace without having to add some additional software to gedit) and get it into a file which can be invoked by whatever command so that Ubuntu doesn't give me "TOO MANY ARGUMENTS" and die. It will submit each line as a command, and when it's done, it will execute the next line and so on until it's finished.

Wednesday, October 30, 2019

tablet - Ubuntu on an Asus Transformer Prime?

Can Ubuntu be put on a tablet that currently has Android on it (instead of android)?



I have a tablet (Asus Transformer Prime) that I would like to play with tech-wise and I wanted to know if there is a way I can get Ubuntu on it, so that I could use it with ROS to do robot design/programming.

drivers - Intel graphic ppa error after apt-get update

how can i ignore this message?


W: GPG error: https://download.01.org/gfx/ubuntu/16.04/main xenial InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 56A3DEF863961D39
W: The repository 'https://download.01.org/gfx/ubuntu/16.04/main xenial InRelease' is not signed.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.

Its from intel update gfx.

Selective command-history in the terminal?



Within a terminal, when you press up in your keyboard, you get to see the past commands you have given to it before in order. I was wondering if there was a way to see only the commands in the past starting with -for instance, "ls -l". That way, if the list of commands is:





  1. ls -l -a

  2. cmake

  3. cd ~/Desktop

  4. cmake



A way to just write "ls" and tab or whatever combination of key-strokes needed to pop up the past command giving in to the terminal starting with "ls"




Thanks,



It won't show things only starting with ls, but you can do Ctrl-R ls to do a backwards search through history. Repeat Ctrl-R to find the next match.


Ubuntu 16.04 | Can't log back in from suspend after kernel update using GNOME 3 (NVIDIA)

Recently I upgraded the kernel I was using to the newest available, and everything worked great until the screen locked and I couldn't log back in. At first it was a black screen displaying the top bar with the clock and user name, now it's like the desktop froze even though I still can move my cursor.
Reading all the questions asked here and trying all of the solutions provided the only way I could get back was rebooting (logging through Crtl+Alt+F2)



I have tried sudo dpkg-reconfigure lightdm changing between GDM and LightDM.
And I tried sudo chown user:user .Xauthority.



I also tried reinstalling GDM and disabling and/or upgrading the nvidia drivers, as I read that that could have been the problem.*



kernel: 4.13.8-041308-generic
shell: Gnome 3.18.5
distro: Ubuntu 16.04




Edit: *Just playing around with nvidia releases I discovered that sudo apt-get install nvidia-current solved the problem but it brought other problems as well.

12.04 - Ubuntu is using Intel Compatible controller instead of NVidia



I'm trying to run Minecraft on my Ubuntu 12.04 but I'm having the following error:




[08:04:00 INFO]: Client> org.lwjgl.LWJGLException: Could not init GLX




[08:04:00 INFO]: Client> at
org.lwjgl.opengl.LinuxDisplayPeerInfo.initDefaultPeerInfo(Native
Method) ~[lwjgl-2.9.1.jar:?]
[08:04:00 INFO]: Client> at org.lwjgl.opengl.LinuxDisplayPeerInfo.(LinuxDisplayPeerInfo.java:61)



~[lwjgl-2.9.1.jar:?] [08:04:00 INFO]: Client> at
org.lwjgl.opengl.LinuxDisplay.createPeerInfo(LinuxDisplay.java:818)



~[lwjgl-2.9.1.jar:?] [08:04:00 INFO]: Client> at
org.lwjgl.opengl.DrawableGL.setPixelFormat(DrawableGL.java:61)




~[lwjgl-2.9.1.jar:?] [08:04:00 INFO]: Client> at
org.lwjgl.opengl.Display.create(Display.java:846)



~[lwjgl-2.9.1.jar:?] [08:04:00 INFO]: Client> at
org.lwjgl.opengl.Display.create(Display.java:757)



~[lwjgl-2.9.1.jar:?] [08:04:00 INFO]: Client> at azl.ad(SourceFile:312) [1.7.5.jar:?]



[08:04:00 INFO]: Client> at azl.f(SourceFile:696) [1.7.5.jar:?]




[08:04:00 INFO]: Client> at
net.minecraft.client.main.Main.main(SourceFile:148) [1.7.5.jar:?]



[08:04:01 INFO]: Client> Xlib: extension "GLX" missing on display
":0".




Looking around the net, I found out my nvidia drivers are not being used, using the following command:




lsb_release -a && lspci -vmk | grep -A 8 -B 2 VGA && lspci | grep VGA && glxinfo | grep -w 'direct\|OpenGL'



I get:




No LSB modules are available. Distributor ID: Ubuntu



Description: Ubuntu 12.04.4 LTS Release: 12.04 Codename: precise



Device: 00:02.0 Class: VGA compatible controller Vendor: Intel




Corporation Device: 4th Gen Core Processor Integrated Graphics



Controller SVendor: Hewlett-Packard Company SDevice: Device 1966



Rev: 06 Driver: i915 Module: i915



00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core



Processor Integrated Graphics Controller (rev 06) Xlib: extension




"GLX" missing on display ":0". Xlib: extension "GLX" missing on



display ":0". Xlib: extension "GLX" missing on display ":0". Xlib:



extension "GLX" missing on display ":0". Xlib: extension "GLX"



missing on display ":0". Error: couldn't find RGB GLX visual or



fbconfig Xlib: extension "GLX" missing on display ":0". Xlib:




extension "GLX" missing on display ":0". Xlib: extension "GLX"



missing on display ":0". Xlib: extension "GLX" missing on display



":0". Xlib: extension "GLX" missing on display ":0". Xlib: extension



"GLX" missing on display ":0". Xlib: extension "GLX" missing on



display ":0".





How can I get the right driver installed and used by default?



BTW, in the Additional Drivers section I see the nvidia driver, but it says that the driver is installed but not being used.



Well, installing Bumblebee solved my issues.



Here are the steps I followed:




https://wiki.ubuntu.com/Bumblebee


Tuesday, October 29, 2019

14.04 - Software Updater: Requires installation of un-trusted packages

I used "sudo apt-get update" command in terminal and resulted with below log,


Help me to fix this issue, thanks in advance for your kind reply.


LOG:(I made typo in the link reference to post this question as i don't have enough reputation)


Reading package lists... Done
W: Failed to fetch archive.ubuntu/ubuntu/dists/trusty/InRelease


W: Failed to fetch in.archive.ubuntu/ubuntu/dists/trusty/InRelease


W: Failed to fetch in.archive.ubuntu/ubuntu/dists/trusty-backports/InRelease


W: Failed to fetch archive.canonical/ubuntu/dists/trusty/InRelease


W: Failed to fetch extras.ubuntu.com/ubuntu/dists/trusty/InRelease


W: Failed to fetch in.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease


W: Failed to fetch cdrom://Ubuntu 14.04 LTS Trusty Tahr - Release i386 (20140417)/dists/trusty/main/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs


W: Failed to fetch cdrom://Ubuntu 14.04 LTS Trusty Tahr - Release i386 (20140417)/dists/trusty/restricted/binary-i386/Packages Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs


W: Failed to fetch archive.ubuntu/ubuntu/dists/trusty/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Failed to fetch in.archive.ubuntu/ubuntu/dists/trusty/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Failed to fetch in.archive.ubuntu/ubuntu/dists/trusty-backports/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Failed to fetch in.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Failed to fetch archive.canonical.com/ubuntu/dists/trusty/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Failed to fetch extras.ubuntu.com/ubuntu/dists/trusty/Release.gpg Unable to connect to 192.168.0.2:8080:


W: Some index files failed to download. They have been ignored, or old ones used instead.

boot - Unable to log in and unable to reset the password




I was reading some blog and I found that I can manually start GUI by issuing this command sudo startx, so I did that. I did it in the terminal with the GUI already running. Now I'm unable to login to my user account.



Before that my PC used to boot straight into my account without asking for the password (without even showing the GRUB menu since I have only Ubuntu 12.04 installed on my PC). But now it boots and lands in a screen (without showing the GRUB menu) which displays my user account along with the Guest account. When I choose my account, it asks for the password. I entered the password but it comes back again to the same screen without any response. I am damn sure that the password that I entered was right. When I choose the Guest account, everything goes well. Now I have access only to the Guest account.



Before posting this question, I read similar questions posted here:



My user ID and password is correct: can not log in to Ubuntu 12.04




Unable to log in to my account



Login fails after crash



and I tried solutions suggested for them but nothing worked.



This page (https://help.ubuntu.com/community/LostPassword) and this page (https://wiki.ubuntu.com/RecoveryMode) seems to provide some solutions but I could not bring up the GRUB menu by pressing the SHIFT key or the ESC key. While booting, I kept pressing the keys (I tried both the keys separately) but it would land straight onto the screen displaying user accounts.



I logged into the Guest user and changed my administrator account to standard one. I have no way to know what the root password is.




I opened the Terminal in the Guest account and entered sudo passwd root. It returned the following:



sudo: unable to change sudoers gid: Operation not permitted
sudo: setresuid() [0, 0, 0] -> [128, -1, -1]: Operation not permitted


Now I can not access any of my files or folders. Are there any possible solutions to my problem without re-installing the OS? Is there any way to reset all the User accounts and regain access to my account?




  • Reboot the system and hold down the SHIFT key before the system boots into Ubuntu.


  • Choose the Recovery Mode using Arrow keys and press ENTER.

  • Choose 'root' from the list that appears. It will bring up the command line interface.

  • Type rm ~/.Xauthority and hit ENTER.

  • Type rm -rf ~/.config/autostart and hit ENTER.

  • Type shutdown -r now to reboot the system.



What this does is that it just deletes a couple of configuration files (nothing to worry).


Monday, October 28, 2019

dpkg - "No space left on device" when installing packages, yet I have space left

Whether through update manager, or through terminal, I error out.



When I try sudo apt-get update && sudo apt-get upgrade:



Fetched 1,024 kB in 20s (51.0 kB/s) 
Reading package lists... Done

Reading package lists... Done
Building dependency tree Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies: linux-headers-generic :
Depends: linux-headers-3.13.0-29-generic but it is not installed
E: Unmet dependencies. Try using -f.


And When I try sudo apt-get -f install:




Unpacking linux-headers-3.13.0-29-generic (3.13.0-29.53) ... 
dpkg: error processing archive /var/cache/apt/archives/linux-headers-3.13.0-29-generic_3.13.0-29.53_amd64.deb
(--unpack): unable to create /usr/src/linux-headers-3.13.0-29-generic/include/config/inotify/user.h.dpkg-new' (while processing./usr/src/linux-headers-3.13.0-29-generic/include/config/inotify/user.h'): No space left on device
No apport report written because the error message indicates a disk full error dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing: /var/cache/apt/archives/linux-headers-3.13.0-29-generic_3.13.0-29.53_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)


When I open Ubuntu software center, I get the following text:





New software can't be installed because there is a problem with the
software currently installed. Do you want to repair this problem now?




I get the option to 'repair' or 'cancel'. If I hit 'repair', I get the following error:



Package operation failed
the installation or removal of a software package failed.
(Reading database ... 417598 files and directories currently installed.)

Preparing to unpack .../linux-headers-3.13.0-29-generic_3.13.0-29.53_amd64.deb ... Unpacking linux-headers-3.13.0-29-generic (3.13.0-29.53) ...
dpkg: error processing archive /var/cache/apt/archives/linux-headers-3.13.0-29-generic_3.13.0-29.53_amd64.deb
(--unpack): unable to create /usr/src/linux-headers-3.13.0-29-generic/include/config/bug.h.dpkg-new' (while processing./usr/src/linux-headers-3.13.0-29-generic/include/config/bug.h'): No space left on device
No apport report written because the error message indicates a disk full error dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing: /var/cache/apt/archives/linux-headers-3.13.0-29-generic_3.13.0-29.53_amd64.deb
Error in function: dpkg: dependency problems prevent configuration of linux-headers-generic: linux-headers-generic depends on linux-headers-3.13.0-29-generic; however: Package linux-headers-3.13.0-29-generic is not installed.
dpkg: error processing package linux-headers-generic (--configure): dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-generic: linux-generic depends on linux-headers-generic (= 3.13.0.29.35); however: Package linux-headers-generic is not configured yet.
dpkg: error processing package linux-generic (--configure): dependency problems - leaving unconfigured



The disk full error is odd, because none of my disks are full. I know this because when I run df, I get the following:



Filesystem 1K-blocks      Used Available Use% Mounted on 
/dev/sda6 36178648 13162504 21155332 39% /
none 4 0 4 0% /sys/fs/cgroup
udev 3873544 12 3873532 1% /dev
tmpfs 776860 1384 775476 1% /run
none 5120 0 5120 0% /run/lock
none 3884300 25276 3859024 1% /run/shm

none 102400 68 102332 1% /run/user
/dev/sda2 124327968 42583252 81744716 35% /media/sudoer/48AEC994AEC97B48
/dev/sda3 807468724 121812996 685655728 16% /media/sudoer/New Volume


What do I do at this point? Thanks in advance.

nvidia - Unity 3d no longer works after installing 12.04



I just installed Ubuntu 12.04 by cd. Unity 3D will not work now only 2D It worked fine in 11.10 and also when I upgraded to the beta of 12.04 through update manager. I tried both Nvidia Proprietary Drivers on the list with no luck. I had many more driver choices in 11.10 and 12.04 beta but the default installed driver always worked before this install. I get a black screen and the wall paper sometimes shows for a few seconds and then goes back to the black screen using Unity 3D.



You may be affected by Bug #982485 if Unity 3D was working on the Beta, but isn't working now. It looks like it is affecting Geforce 6*** and Geforce 7*** cards. Nvidia is aware of the bug, so hopefully there will be a fix rolled out soon.



If you want Unity 3D to work in the meantime, try to add the Ubuntu-X Updates PPA and downgrade the nvidia-current package to 295.33.



(tip for GUI users: use Ctrl+Alt+F1 to get to a text mode login, then type in your login/password at the command line interface to get to a place where you can issue the following commands)




sudo add-apt-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get install nvidia-current=295.33-0ubuntu1~precise~xup1


Important notes:




  • There was a security bug in 295.33 so you have to factor this into your decision about whether or not to downgrade.


  • You will have to uncheck the nvidia-current package from the Update Manager when you upgrade your system to prevent it from re-installing version 295.40.





Whether or not you downgrade your nvidia driver, watch the bug listing (or subscribe to it) to know when the bug gets fixed so you can upgrade your driver then.


GRUB2 - Create 2nd boot entry with different kernel command line options in GRUB_CMDLINE_LINUX_DEFAULT

I want to have a separate boot menu entry at boot. The only difference is the value of GRUB_CMDLINE_LINUX_DEFAULT. The original (first) boot has empty value for GRUB_CMDLINE_LINUX_DEFAULT, and the 2nd entry has a value that is passed to the kernel.


In short, I want to have two boot menu entries which the only difference is the kernel arguments. I poked around /etc/grub.d but couldn't find a way other than gross hack in /etc/grub.d.

ati - Fglrx causes serious bug-black screen!

I downloaded newest driver from Ati site and installed it...


Now at start-up I see a black screen and message:



"Your screen,graphics card,and input device settings could not be
detected correctly.You will need to configure these yourself."



I press enter and move to next screen with message:



"What would you like to do?"



and listed below:



"Run in low graphics mode for just one session."



(it is marked) and some other options that could not possibly to mark with TAB or up,down,left,right or shift key... (no cursor). I can not login to system and can not use it! What should I do?

Sunday, October 27, 2019

14.04 - Ubuntu install not working

I've recently changed my OS on the laptop from Ubuntu 14.04 to windows 10 preview build. Now, when I'm trying to clean install the Ubuntu 14.04 back on my laptop I'm unable to do so. When I plugin my bootable USB/CD and select "install Ubuntu" it doesn't boot in. The boot doesn't load and the screen keeps flickering.


How do I fix this? How to find out what is the actual problem?

packages were automatically installed and are no longer required

I installed sendEmail on Ubuntu server 12.04 LTS based on a recommendation from http://linuxneophyte.com/sendemail-a-light-and-simple-command-line-mailer/



The package installed (not visible with dpkg but /usr/bin/sendEmail exists) and that was followed by this prompt:




The following packages were automatically installed and are no longer required:
php-mail-mime php-net-socket php-mdb2-driver-mysql php-mdb2 libpango1.0-common php5-gd
libmcrypt4 libt1-5 libhal1 php-net-smtp php5-pspell libhal-storage1 libaudiofile0
php5-mcrypt php-auth dbconfig-common tinymce php-mail-mimedecode
Use 'apt-get autoremove' to remove them.


Earlier, the above list of packages to remove included courier-ssl which I removed, but I'm not sure about the others. Should I keep these packages or remove them?

command line - How to upgrade using terminal

How can i upgrade my existing ubuntu 12.04 to 13.04 using terminal... please help me with the procedure. I am having problem regarding upgrade.

installation - ATI drivers "break" in between installing/updating Ubuntu for the first time. What can I do?

This might sound odd, but I have a very peculiar graphics driver issue. Basically, I pop the Live CD in, and "try Ubuntu". Everything works fine from GUI animation, to fullscreen flash, to even full-screen 3D graphics.



However, when I install the OS itself, and reboot into it "properly" for the first time, everything breaks. If I stick with open source, I'm unable to use the computer at all, and if I switch to any of the proprietary ATI drivers, usually the OS will be laggy, full-screen flash videos will be black, or 3D graphics will be choppy and glitchy.



It seems as if somewhere in between testing the OS out, and installing/updating it "breaks" the drivers. What can I do to keep them?




I have an ATI Radeon HD 6850 (1GB) graphics card, and I'm running a 64-bit OS.

grub2 - How to remove or hide the GRUB boot menu?


Recently I decided to use only Ubuntu and there is no Windows in my laptop. When I turn on my laptop the GRUB menu is showing but I don't need to choose OS anymore.


How can I remove or hide this?
And after removing this how could I access to recovery mode?



To not see the GRUB menu while booting:



  1. Open the /etc/default/grub file using from terminal entering: gksu gedit /etc/default/grub

  2. Change GRUB_TIMEOUT=10 to GRUB_TIMEOUT=0

  3. Save the file and quit the text editor.

  4. Run: sudo update-grub

  5. Reboot.


This will remove the time that you need to wait for the GRUB menu to disappear.


IMPORTANT: If then you need to change to Recovery mode in some instance just press ESC when Linux starts. That is between when the BIOS finishes loading all necessary stuff and the Operating System starts. Then the GRUB menu will appear giving you the change to select the recovery mode.


system installation - Can't Dual Boot Ubuntu 12.04 and Windows 7 on Sony Vaio S 15 (2012)

I just bought my dad a new laptop for fathers day, a Sony Vaio S 15 (the latest models from Sony) and he wants to dual boot Ubuntu and Windows 7. I put Ubuntu 12.04 on a USB drive and went to install it on the computer, but when I got into the partition part of the install there was no option to dual boot. Only to delete everything and install Ubuntu or 'other'. I installed using the 'other' feature by manually partitioning, however once I installed it the computer wouldn't ever go to grub. From inside windows I used Easy BCD to try and fix the boot loader so it would give the option to boot into Windows 7 or Ubuntu 12.04, but it couldn't detect ANY operating systems on the computer (not even windows).



Is it not possible to dual boot on the latest Sony Vaios, or is there a workaround for this?

Saturday, October 26, 2019

partitioning - How can I convert a drive from ext4 to NTFS without losing the data?




I have a hard drive from an Ubuntu system that contains only media files. I would like to move that drive to a Windows 10 computer without losing all of the media. Is this possible, and if so, how can it be done?



I don't want to just mount the ext4 drive in Windows. I want to convert the drive from ext4 to NTFS.



If you have sufficient unused space on the drive, create a second partition, format it to NTFS, and copy the files to the NTFS partition. You could then delete the original files and the ext4 partition, and append the space to the NTFS partition, essentially converting the entire drive from ext4 to NTFS.



If there isn't sufficient available space on the drive to do this, you could copy the files to another computer/drive, format the original drive as NTFS, and copy the files back to the newly formatted drive.


12.04 - Merge unallocated partitions


So my disk ended up being partitioned like this (in order):



  • System reserved (100MB)

  • Windows 7 (NTFS, 500GB)

  • Ubuntu (ext4, 100GB)

  • Swap (4GB)

  • Unallocated Space (400GB)


Unfortunately, the unallocated space is not next to ext4 or NTFS partitions.


I want to allocate 200GB to the Windows 7 NTFS partition, the other 200GB to the Ubuntu partitions. I think one can only merge partitions that are next to each other, not sure how to handle my case.


Any suggestions? Is there anything I should pay attention to (such as not screwing up either Windows or Ubuntu system, not screwing up GRUB).


I am using Ubuntu 12.04.



Yes, the space does need to be contiguous to merge. You will need to move a few things around, and do it in stages. I wouldn't try to do it all at once, since some steps may take a bit of time.


You will need to do it using a live CD or live USB, as you can't mess with a mounted partition.


I recommend first creating a swap drive at the end of the disk. Then, highlight the old swap drive, choose swap off, unmount that partition, and delete it.


You can move the Ubuntu partition over into the unallocated space, then merge the space before Ubuntu with Windows, and merge the space after Ubuntu with Ubuntu.


You might also consider leaving them as is, creating a data partition using NTFS, then pointing both windows and Ubuntu to this partition for Documents, pictures, music, etc. Windows 7 has a way to change the location for these directories, and you can create symbolic links in Ubuntu to point to the same place. This makes it much easier to share data with both systems, and never duplicate data.


upgrade - Ubuntu 18.04 black screen on reboot after upgrading to Linux Kernel 5.0?

My Lubuntu 18.04 (as a VirtualBox 6.0.10 virtual machine) is just upgraded to



Linux pbox 5.0.0-23-generic #24~18.04.1-Ubuntu SMP Mon Jul 29 16:12:28 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux


with an apt upgrade. After the upgrade, the VM shows a black screen with a cursor in the upper left corner, and seems to hang.




Does anyone have similar experience with the new 5.0 Linux kernel, and know how to fix the problem?



FYI, I can go to the GUI anytime after hitting Ctrl+Alt+F1 and then Ctrl+Alt+F7 without a problem. A systemd-analyze blame didn't show anything taking an excessive amount of time (3 seconds max) during reboot. But if I don't switch manually, the black green never disappears.



-- Update --



By the way, I got the new kernel via apt-get as follows:



sudo apt-get install --install-recommends linux-generic-hwe-18.04

14.04 - Why don't these packages download?



I was following this guide: http://developer.ubuntu.com/en/start/ubuntu-for-devices/porting-new-device/



and when I got to the step:





Then, install all the other packages you will need for the build by running this command:




sudo apt-get install git gnupg flex bison gperf build-essential \
zip bzr curl libc6-dev libncurses5-dev:i386 x11proto-core-dev \
libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 \
libgl1-mesa-dev g++-multilib mingw32 tofrodos \
python-markdown libxml2-utils xsltproc zlib1g-dev:i386 schedtool \
g++-4.8-multilib




apt said:



Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:


The following packages have unmet dependencies:
libgl1-mesa-glx:i386 : Depends: libglapi-mesa:i386 (= 10.1.3-0ubuntu0.4)
Recommends: libgl1-mesa-dri:i386 (>= 7.2)
unity-control-center : Depends: libcheese-gtk23 (>= 3.4.0) but it is not going to be installed
Depends: libcheese7 (>= 3.0.1) but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.


How can I fix this? Let me know if more information is needed.




EDIT:



using aptitude the solution is:



The following actions will resolve these dependencies:

Keep the following packages at their current version:
1) binutils:i386 [Not Installed]
2) cpp:i386 [Not Installed]
3) cpp-4.8:i386 [Not Installed]

4) gcc:i386 [Not Installed]
5) gcc-4.8:i386 [Not Installed]
6) libgl1-mesa-dri:i386 [Not Installed]
7) libgl1-mesa-glx:i386 [Not Installed]
8) libglapi-mesa:i386 [Not Installed]

Leave the following dependencies unresolved:
9) libc6-dev:i386 recommends gcc:i386 | c-compiler:i386
10) libgl1-mesa-glx:i386 recommends libgl1-mesa-dri:i386 (>= 7.2)



This solution leaves essentially 1 unresolved dependancy, and the dependancy is a recommendation:



 Leave the following dependencies unresolved:                   
4) libgl1-mesa-glx:i386 recommends libgl1-mesa-dri:i386 (>= 7.2)


You can try using aptitude. It has better dependency handling as far as I know.



Otherwise install the required packages before using that apt-get line.




sudo apt-get install libglapi-mesa libcheese-gtk23 libcheese7 libgl1-mesa-dri

Friday, October 25, 2019

Sanity check of an Ubuntu system after a release upgrade

Is there a way to verify the sanity/consistency/integrity of an Ubuntu system after a release upgrade, particularly if the upgrade process did not go smoothly or did not follow standard/recommended procedure?

apt - WINE not properly uninstalling

So I recently updated to WINE version 1.9.6 from version 1.6.2 (from software manager). The new version was not working, so I decided to uninstall it, and reinstall the old version, but the new version 1.9.6 seems to not be uninstalling. I've tried



sudo wine uninstall wine



sudo apt-get purge wine




sudo apt-get remove --purge wine



and all of these options with wine*, wine-1.9, and wine-1.9.6 as opposed to simply wine. Nevertheless, when I check the version of wine, it shows up as 1.9.6.



Reinstalling the old version from the software manager doesn't seem to help either. What else can I do to get rid of this version?



edit:
which wine shows /usr/local/bin/wine

kernel - How to enable boot messages to be printed on screen during boot up?




How to enable boot messages, kernel messages and other logs of various services to be printed on screen during boot up?




You'd need to remove the kernel boot parameters quiet and splash from the linux line in GRUB:




  1. Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).

  2. Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.

  3. Go down to the line starting with linux and remove the parameters quiet and splash.

  4. Now press Ctrl + x to boot.





To make this change permanent:




  1. From a terminal (or after pressing Alt + F2) run:



    gksudo gedit /etc/default/grub


    and enter your password.


  2. Find the line starting with GRUB_CMDLINE_LINUX_DEFAULT and remove the parameters quiet and splash.



  3. Save the file and close the editor.


  4. Finally, start a terminal and run:



    sudo update-grub


    to update GRUB's configuration file.



bug reporting - My Launchpad bug was marked as a duplicate of another unrelated bug. What should I do?


Some time ago I reported a bug on Launchpad. Now another user (who is not an active member of the package I filed the bug against) marked this bug as a duplicate to another bug. This is great, as it will prevent my report from expiring but the linked duplicate appears to be only remotely related, and also was marked "invalid". Therefore the duplicate state feels not correct and I commented on that.


Does the duplicate link have any negative effects on resolving the issue? Should I remove the link, or is it better to leave it as it is? What else can be done in such cases?



At a glance, I'm not sure it's unrelated. And I say that wanting to give you the benefit of the doubt. Your bug does spend some time enumerating a permission problem that is covered by the first comment on the master question:



These actions were for ConsoleKit. logind has its own rules, so you need to rewrite them to enumerate org.freedesktop.login1.suspend and org.freedesktop.login1.hibernate (see /usr/share/polkit-1/actions/org.freedesktop.login1.policy).



The rules have moved. Here's another bug report that goes over the same ground. I know you've seen this before but I want to make sure it's clear, this is the sort of code you want:


# cat /etc/polkit-1/localauthority/90-mandatory.d/disable-suspend.pkla
[Disable suspend by default]
Identity=unix-user:*
Action=org.freedesktop.login1.suspend
ResultActive=no
[Disable suspend for all sessions]
Identity=unix-user:*
Action=org.freedesktop.login1.suspend-multiple-sessions
ResultActive=no

If that's not enough (either it not working or nor suppressing the menu item, or some mix of the two), edit your bug description and make it super-extra clear that your issue is with the indicator... And then shunt it back to confirmed (or whatever it was before.


In general terms though, you have to look at the bug in question and work out whether or not the master version (or any others linked to it) actually describe or are the source of your problem. If they're not, make that as clear as possible and reopen.


boot - How can I get past the preparing to install screen in Ubuntu 15.10 installation in Live environment?

I am using a Dell Inspiron N4110 Laptop. I have a intel Core-i5 2.5 GHz Processor and 4GB RAM. It's running Windows 10. After downloading a Ubuntu iso from the official page I have created a bootable USB drive. I chose to try Ubuntu after booting from the USB and clicked the install ubuntu shortcut. But, I got stuck in the "Preparing to install" screen. I have tried installing with the third-party software box and update box unchecked.
Please help me. Let me know if you need to know any other information.

Will changing the repository in the software center affect sources.list

I have all repositories activated (main, universe, multiverse, restricted) in the software center per default. If I make changes (e.g. I would uncheck the box for multiverse) I cannot install the software from this repository anymore using software center.


Will it be possible to install the software from multiverse using "apt-get"?

How can I make the Unity 2d Shell dodge GNOME Panel when running both simultaneously?



I'm using GNOME Fallback in 12.04, and I'm running the Unity 2D Shell (WITHOUT THE UNITY 2D PANEL) and GNOME Panel. I've done this by logging in using GNOME Fallback, and then running unity-2d-shell. This is what it currently looks like:



enter image description here



The second picture is my second monitor, ignore it.




As you can see, the gnome panel is on top of the Unity 2d shell. How can I move the Unity 2d shell 28 pixels from the top of the screen (my gnome panel is 28 pixels in height)?



Edit: I'm running Compiz as well, so I can use the ccsm if anyone has any solution that would require that.



I confirm that behavior would show up only for Compiz/Dual Display combination. What I've tested so far in VBox with Ubuntu 12.04 32bit:




  • Metacity + Single Display (OK)

  • Metacity + Dual Display (OK)

  • Compiz + Single Display (OK)


  • Compiz + Dual Display (Overlapping)



One trick or work around that works for me, adding a top panel to the second display & Auto hide should be disabled for both.



In case you don't want to add a panel to 2nd display, this another hack not fully tested, it just works:




  1. Get source:




    sudo apt-get build-dep unity-2d
    apt-get source unity-2d
    cd unity-2d-5.14.0/

  2. Modify screen top



    nano shell/app/shelldeclarativeview.cpp



    void
    ShellDeclarativeView::updateShellPosition()

    {
    ...
    QRect my_screenInfo = m_screenInfo->availableGeometry();
    my_screenInfo.adjust(0,28,0,0);
    const QRect availableGeometry = my_screenInfo;
    //const QRect availableGeometry = m_screenInfo->availableGeometry();

  3. Mod Shell height



    nano shell/Shell.qml




    Item {
    id: shell
    ...
    height: declarativeView.screen.availableGeometry.height - 28

  4. Build it:



    cmake .
    make


  5. Test it



    ./shell/app/unity-2d-shell



You may like to install it then rename it to avoid mess up with official one.



    sudo make install        

sudo mv /usr/local/bin/unity-2d-shell /usr/local/bin/unity-2d-shell-mod

wireless - Cannot see my wifi [10ec:d723] when trying Ubuntu

I am having an issue with wifi; it seems when I'm trying Ubuntu without installing, it only detects connection via the ethernet cable.


I can't connect and none of the available wifi networks are detected.


$ lspci
00:00.0 Host bridge: Intel Corporation Device 5904 (rev 02)
00:02.0 VGA compatible controller: Intel Corporation Device 5916 (rev 02)
00:04.0 Signal processing controller: Intel Corporation Skylake Processor Thermal Subsystem (rev 02)
00:08.0 System peripheral: Intel Corporation Sky Lake Gaussian Mixture Model
00:14.0 USB controller: Intel Corporation Sunrise Point-LP USB 3.0 xHCI Controller (rev 21)
00:14.2 Signal processing controller: Intel Corporation Sunrise Point-LP Thermal subsystem (rev 21)
00:16.0 Communication controller: Intel Corporation Sunrise Point-LP CSME HECI (rev 21)
00:17.0 SATA controller: Intel Corporation Sunrise Point-LP SATA Controller [AHCI mode] (rev 21)
00:1c.0 PCI bridge: Intel Corporation Device 9d10 (rev f1)
00:1c.4 PCI bridge: Intel Corporation Sunrise Point-LP PCI Express Root Port (rev f1)
00:1c.5 PCI bridge: Intel Corporation Sunrise Point-LP PCI Express Root Port (rev f1)
00:1f.0 ISA bridge: Intel Corporation Device 9d4e (rev 21)
00:1f.2 Memory controller: Intel Corporation Sunrise Point-LP PMC (rev 21)
00:1f.3 Audio device: Intel Corporation Device 9d71 (rev 21)
00:1f.4 SMBus: Intel Corporation Sunrise Point-LP SMBus (rev 21)
01:00.0 Display controller: Advanced Micro Devices, Inc. [AMD/ATI] Sun XT [Radeon HD 8670A/8670M/8690M / R5 M330] (rev 83)
02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15)
03:00.0 Network controller: Realtek Semiconductor Co., Ltd. Device d723



$ lspci -knn | grep Net -A3
03:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. Device [10ec:d723]
DeviceName: Hanksville Gbe Lan Connection
Subsystem: Hewlett-Packard Company Device [103c:8319]

Thursday, October 24, 2019

drivers - system running low graphics

I've just installed Ubuntu on a fresh machine had Nothing on it just a 120gb SSD, 1TB HDD.


Once it finished installing which was pretty fast on the SSD,
I restarted my PC only to get the error System running low graphics I, of course, googled it and turns out that some AMD GPU's are having compatibility issues with Ubuntu. the fix apparently is to go to recovery mode and pressing Ctrl+Alt+F2 to get into Terminal command.


The only problem is that it's asking me to log in... sure I try to log in but when it asks for my password it wont let me type Anything.. and just keeps going.


I have no idea how to fix this... any tips? video links maybe ?

12.04 - Grub rescue rescue error on boot even after trying a "Boot Repair"

I tried to load Ubuntu 12.04 onto an old machine from a CD and the installation went fine, but I got the boot error: no such device: grub rescue.


I looked into the issue with a CD live boot (unsure of the terminology, but I selected the option to try Ubuntu Desktop) and found this forum post suggesting a Boot Repair program. I installed it from the terminal. I ran the program, it said it was fixed, and I tried to start it up no no avail. It gave me an Ubuntu Pastebin and to ask if I had any troubles.


What should I try now to fix this?


I am not very educated in programming or Linux type operating systems yet. But I would appreciate any help and will try to give as much information as necessary.


So far the only way my access desktop is using the installation disk.

boot - Problems upgrading kernel in ubuntu 14.04

I'm having issues with updating my kernel running Ubuntu 14.04 on kernel 4.4.0-45-generic. When I run apt-get update followed by apt-get upgrade, my /boot drive runs out of space. I go look at /boot and see that it has installed initrd.img-3.19.0-64-generic through initrd.img-3.19.0-73-generic, which seems unnecessary.



Based on the other files in /boot and the kernel I am running now, I think I should be on initrd.img-4.4.0-57-generic. Thus, I am unsure why upgrade is installing all of these unnecessary initrd.img (it does not install any of the other files for the older kernels).



Following the advice in several places on how to clean /boot, I manually deleted the older initrd.img files and re-run apt-get upgrade. Again, it downloads and installs the same initrd packages, runs out of space, and fails. How can I fix apt upgrade? How to I prevent it from installing old kernels? Any help would be most appreciated. In case it is useful, here is the full output from apt-get upgrade:



Reading package lists... Done
Building dependency tree

Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
linux-generic-lts-vivid linux-generic-lts-xenial
linux-headers-generic-lts-vivid linux-headers-generic-lts-xenial
linux-image-generic-lts-vivid linux-image-generic-lts-xenial
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
10 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y

Setting up initramfs-tools (0.103ubuntu4.6) ...
update-initramfs: deferring update (trigger activated)
Setting up linux-image-3.19.0-78-generic (3.19.0-78.86~14.04.1) ...
Internal Error: Could not find image (/boot/vmlinuz-3.19.0-78-generic)
dpkg: error processing package linux-image-3.19.0-78-generic (--configure):
subprocess installed post-installation script returned error exit status 2
Setting up linux-firmware (1.127.23) ...
update-initramfs: Generating /boot/initrd.img-4.4.0-45-generic
update-initramfs: Generating /boot/initrd.img-4.4.0-42-generic
update-initramfs: Generating /boot/initrd.img-4.4.0-38-generic

grep: /boot/config-4.4.0-38-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-73-generic
grep: /boot/config-3.19.0-73-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-71-generic
grep: /boot/config-3.19.0-71-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-69-generic
grep: /boot/config-3.19.0-69-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-66-generic
grep: /boot/config-3.19.0-66-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-65-generic

grep: /boot/config-3.19.0-65-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-64-generic
grep: /boot/config-3.19.0-64-generic: No such file or directory
update-initramfs: Generating /boot/initrd.img-3.19.0-61-generic
grep: /boot/config-3.19.0-61-generic: No such file or directory

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-3.19.0-61-generic with 1.
dpkg: error processing package linux-firmware (--configure):

subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-extra-3.19.0-78-generic:
linux-image-extra-3.19.0-78-generic depends on linux-image-3.19.0-78-generic; however:
Package linux-image-3.19.0-78-generic is not configured yet.

dpkg: error processing package linux-image-extra-3.19.0-78-generic (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-generic-lts-vivid:
linux-image-generic-lts-vivid depends on linux-image-3.19.0-78-generic; however:
Package linux-image-3.19.0-78-generic is not configured yet.

linux-image-generic-lts-vivid depends on linux-image-extra-3.19.0-78-generic; however:
Package linux-image-extra-3.19.0-78-generic is not configured yet.
linux-image-generic-lts-vivid depends on linux-firmware; however:
Package linux-firmware is not configured yet.

dpkg: error processing package linux-image-generic-lts-vivid (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problNo apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already

ems prevent configuration of linux-generic-lts-vivid:
linux-generic-lts-vivid depends on linux-image-generic-lts-vivid (= 3.19.0.78.60); however:
Package linux-image-generic-lts-vivid is not configured yet.

dpkg: error processing package linux-generic-lts-vivid (--configure):
dependency problems - leaving unconfigured
Setting up linux-image-4.4.0-57-generic (4.4.0-57.78~14.04.1) ...
Running depmod.
update-initramfs: deferring update (hook will be called later)
The link /initrd.img is a dangling linkto /boot/initrd.img-4.4.0-57-generic

vmlinuz(/boot/vmlinuz-4.4.0-57-generic
) points to /boot/vmlinuz-4.4.0-57-generic
(/boot/vmlinuz-4.4.0-57-generic) -- doing nothing at /var/lib/dpkg/info/linux-image-4.4.0-57-generic.postinst line 491.
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.4.0-57-generic /boot/vmlinuz-4.4.0-57-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.4.0-57-generic /boot/vmlinuz-4.4.0-57-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.4.0-57-generic /boot/vmlinuz-4.4.0-57-generic
update-initramfs: Generating /boot/initrd.img-4.4.0-57-generic

gzip: stdout: No space left on device

E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.4.0-57-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-4.4.0-57-generic.postinst line 1052.
dpkg: error processing package linux-image-4.4.0-57-generic (--configure):
subprocess installed post-installation script returned error exit status 2
No apport report written because MaxReports is reached already
dpkg: dependency problems prevent configuration of linux-image-extra-4.4.0-57-generic:
linux-image-extra-4.4.0-57-generic depends on linux-image-4.4.0-57-generic; however:
Package linux-image-4.4.0-57-generic is not configured yet.


dpkg: error processing package linux-image-extra-4.4.0-57-generic (--configure):
dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
dpkg: dependency problems prevent configuration of linux-image-generic-lts-xenial:
linux-image-generic-lts-xenial depends on linux-image-4.4.0-57-generic; however:
Package linux-image-4.4.0-57-generic is not configured yet.
linux-image-generic-lts-xenial depends on linux-image-extra-4.4.0-57-generic; however:
Package linux-image-extra-4.4.0-57-generic is not configured yet.

linux-image-generic-lts-xenial depends on linux-firmware; however:
Package linux-firmware is not configured yet.

dpkg: error processing package linux-image-generic-lts-xenial (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-generic-lts-xenial:
linux-generic-lts-xenial depends on linux-image-generic-lts-xenial (= 4.4.0.57.44); however:
Package linux-image-generic-lts-xenial is not configured yet.

dpkg: error processing package linux-generic-lts-xenial (--configure):

dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
Processing triggers for initramfs-tools (0.103ubuntu4.6) ...
update-initramfs: Generating /boot/initrd.img-4.4.0-45-generic

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.4.0-45-generic with 1.
dpkg: error processing package initramfs-tools (--configure):
subprocess installed post-installation script returned error exit status 1

No apport report written because MaxReports is reached already
Errors were encountered while processing:
linux-image-3.19.0-78-generic
linux-firmware
linux-image-extra-3.19.0-78-generic
linux-image-generic-lts-vivid
linux-generic-lts-vivid
linux-image-4.4.0-57-generic
linux-image-extra-4.4.0-57-generic
linux-image-generic-lts-xenial

linux-generic-lts-xenial
initramfs-tools
E: Sub-process /usr/bin/dpkg returned an error code (1)


EDIT1:
I tried to remove old kernels as described here.



It failed with the error message:




Errors were encountered while processing:
linux-image-extra-3.19.0-64-generic
linux-image-extra-3.19.0-65-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:


I then found a very similar issue that may be the same or similar to what I'm experiencing. Would manually removing all linux-image-3.19.* from /var/lib/dpkg/info/ be an option? I'm imagining not, but I don't know what else to do.

grub2 - Boot error > no such device: grub rescue





After an installation of Ubuntu 12.04, erasing an old partition with Ubuntu 10.10, I can't get grub to load. I can't access my Windows 7 partition either



I get the message:



> error: no such device: 58ABF29C...  

grub rescue>


I suppose my master boot record got erased/corrupted. How can I check and fix this?



Re-install your GRUB.




  1. Boot using a live cd of ubuntu.


  2. Open a terminal and run the command
    sudo fdisk -l
    It lists the complete partition table of the hard disk. In there, identify which partition you have got your linux installed on. You can identify it using the drive size you had allocated for it and looking at the last column of the output which will be extended or Linux for all of your linux partitions. The partition will most probably be something like /dev/sda5 or something. Remember this partition.



  3. Create a temporary folder in your home directory (Note: You can make the temporary folder anywhere you want. I’m using the home folder just for the sake of explanation). I’m calling it temp for now. So that temp folder’s path will be/home/ubuntu/temp`.


  4. Mount your linux partition there. That is, assuming that you found your linux partition to be /dev/sda5, you mount that at the temp folder by doing the following command



    sudo mount /dev/sda5 /home/ubuntu/temp


  5. If you want to check whether you have mounted the correct partition, go to your home folder and open temp. You will be in the / directory. In there you will find home, in which your home folder’s name will be there. Once you’ve confirmed you have mounted the correct partition, do step 6.


  6. You have to install grub by showing the system where to read the data from the hard disk at the beginning. Don’t worry, just run the following command



    sudo grub-install --root-directory=/home/ubuntu/temp /dev/sda



    The /dev/sda corresponds to your hard disk name. Replace it by whatever the command sudo fdisk -l command showed you.



  7. You’re done. You may restart your system.



Wednesday, October 23, 2019

laptop - Ubuntu compatibility with ASUS VivoBook N580VD

I was looking for a powerful Notebook and found the Asus VivoBook N580VD-DM070T. I've done some research about problems with Ubuntu, but could not find anything for this model. Does anyone have experience with Ubuntu on this model?

nvidia - Ubuntu on ThinkPad T480/T480s

is anyone running Ubuntu on a ThinkPad T480 or T480s (especially with the NVIDIa graphics card)?


What are your experiences? Is everything working?


Thank you!

uninstall - What's the name of PPA? (for ppa-purge)



I'm testing PPAs, so I commonly use ppa-purge, that restores my default versions. But I always have problem with the ppa name. What do I need to put as argument for ppa-purge?




I always used my browser to check name on launchpad, but what about when I'm without internet and I can't start X. Org server?



For xorg-edgers I know that ppa:xorg-edgers/ppa what about others? Let's say, I know that I have PPA of X-Updates. How do I find out the name of this PPA so I could use with ppa-purge, without using browser



So the name should be something like ppa:NAME/ppa? How to get this NAME?



This command will list all the PPA repositories you have configured



grep ppa /etc/apt/sources.list /etc/apt/sources.list.d/*



Alternatively, you can check the repository of a given package



apt-cache policy [package-name]

boot - Bootable USB and CD not detected

I created a bootable usb as well as a bootable cd to install ubuntu. Unfortunately, my medion PC (running windows 10) does not detect neither the usb nor the cd.
I am pretty sure that these bootable devices were properly created as I can start from them on hp computer.


I tried refind but the bootable usb and cd are not detected either.


I disabled the secure boot in the efi as described in several forums. It did not bring anything. I have not the option to use the legacy bios.


I tried other linux distributions I get the same: bootable devices are not detected. Only bootable windows installation usb or cd are detected.
Can you give me some hints?

Ubuntu 14.04 Suddenly Fails to Boot

My Ubuntu installation has decided not to work anymore. I suspect it's something graphical or to do with memory. Read on for more.



Background.




I installed Ununtu 14.04 on my laptop a few months ago and have had no problems whatsoever with it up until a few days ago. I had closed the laptop temporarily and it went into Sleep Mode. Then when I opened it again, it awakened. Cool. However, the screen remained completely blank except for when I moved the mouse or pressed a key on the keyboard, which briefly flashed my desktop wallpaper. After rollong my eyes and cursing the previous fifty years of software development, I performed a hard reset, got to GRUB2 and proceeded with loading Ubuntu. Now the boot process stalls shortly after the GRUB screen and I am left with a blank screen and a blinking cursor.



Attempts at Recovery.




  1. Loaded "Ubuntu with Linux [latest version available on laptop] (Recovery Mode)" and performed all available tasks. Interesting note: I cannot use the "failsafeX" option; selecting this option fails to load Ubuntu with limited graphics. It attempts do so, but fails and reverts back to the Recovery screen.


  2. Tried to reinstall Ubuntu with the same USB drive I used to install it in the first place. I can get to the first menu, but when I select "Install Ubuntu", it quickly crashes with the last line ending "VFS: failed to mount root fs in unknown block [2, 0]". This happens every time.


  3. In Boot Command list, removed "quiet splash" and replaced in with "nomodeset" because several people in different treads suggested this, without giving an explanation as to why it should be done. So naturally, I gave it a go. It didn't make any difference as far as I could tell.





Summary.




  1. Laptop: Lenovo T410, had Windows 7 previously installed (still exists on a separate partition), Intel CORE vPRO i5, 4Ä¢B RAM, Intel Graphics.


  2. Laptop was running fine, sent it to sleep, woke it up, couldn't log in/do anything. Rebooted it.


  3. Booted to GRUB screen, selected Ubuntu.


  4. Ubuntu fails to load. I get a flash of "Loading initial ramdisk" before I get the blank screen with the blinking cursor.


  5. Tried a few things. None worked.


  6. Stumped. Came online for help.





If anyone can shed any light over what's going on here, I would be very grateful.



EDIT:



Responses.



dadexix86.
1. I have never manually performed a filesystem check.





  1. Ubuntu does not boot with an older version of Linux. I get the same result, every time.


  2. I did not suspend it after an update. I was not running any "exotic" processes. By exotic I mean system-critical, or otherwise important to the running of the system-, processes.


  3. I have no external repositories or software.


  4. Thanks for getting back me.




anonymous2.
1. I can still boot to Windows.





  1. I have not performed a memtest. I will do so now and report back. | Memroy check completed, no errors.


  2. Thanks for getting back to me.




Android Dev.
1. No problem, homie.



ComputerGuy.
1. I don't have Nvidia graphics.





  1. I will try your suggestion and report back. | OK, I tried resetting Unity and it returned "WARNING: no DISPLAY variable set, setting it to: 0" and "ERROR: the reset option is now deprecated." So I don't know if that worked. I tried reinstalling LightDM, but I need network connectivity to do that, and I'm not able to enable this. I'm currently looking into that.



Thanks for the help so far, folks.

installation - Proper install NVIDIA drivers

i have a problem and i want to get rid of it.


I have a EVGA 480 GTX graphic card and i can't install the proprietary drivers.


I tried lots of distro, its everytime the same problem : TTY console or poor graphics ( no shadow, no mice, i can just open a term via Ctrl+Alt+T)


I need NVIDIA propietary drivers :<


Could you tell me a proper way to install nvidia drivers ?


Thank you,


Johnny

How to get dual boot (Ubuntu/Windows) option enabled?


My first disk has windows and second disk (not partition) has Ubuntu.


But the first disk was removed during ubuntu installation and plugged back after installation.


Now my system boots with only one OS depending on the disk with higher priority in the boot list.


One of the attached question talks about boot repair or about reinstalling grub-efi. Which is not the case here. My system boots perfectly but based on the drive selected.


The other attached question is valid with the given assumptions being true, which are false in my case.


Is there any way to get OS selection list at boot time?



In your case, the following should be sufficient:



  1. Boot Ubuntu with both drives installed.

  2. Open Terminal and issue the command:


    sudo update-grub

  3. Enter your password and check it detects Windows apart from Ubuntu itself.

  4. You can reboot and choose Windows in the GRUB menu.


However, this might not work if you installed both systems in a different mode (BIOS or UEFI). Anyway, a boot menu provided by the firmware can do the same work as the GRUB menu would.


mount - Cannot format USB stick

2 hours ago, I plugged in my USB stick and used "Startup Disk Creator" in order to burn an Ubuntu-iso to my stick.



Now, I cannot format my USB stick, I tried with Disks, Terminal commands, and GPart..



I get errors like "cannot umount the drive.." and a few more..
The stick isn't even reconized when I plugged in Ubuntu/Windows

Problem after update driver in Ubuntu 12.04 LTS

i had installed ubuntu 12.04 LTS on my laptop since last month and it work great and fine. But after I update my Nvidia driver in Ubunutu , The User-Login Interface had became CMD from GUI. Its fine but the problem is what should i input for the Username Part and also the password part? I had tried many times to input my CORRECT Username and also password but it keep saying that my Login Password was wrong!! Please help me!!




Image for my desktop interface after update my driver:



enter image description here

Tuesday, October 22, 2019

How do I restore the sources.list file?





I accidentally removed my /etc/apt/sources.list file. Is it hosted by Canonical somewhere so I can re-add it to the system? It's a bit of an emergency, so I hope someone can provide a quick answer.



You can boot into a Live CD (a virtual machine will suffice) and copy /etc/apt/sources.list from it. Alternatively, have a Live CD image ready and follow these instructions:




  1. Mount the CD. If you've an .iso file, mount it using:




    sudo mount -o loop ubuntu-11.04-desktop-amd64.iso /media/cdrom

  2. Mount the filesystem file from the CD:



    sudo mount -o loop /media/cdrom/casper/filesystem.squashfs /mnt

  3. Copy the sources.list file over:



    sudo cp {/mnt,}/etc/apt/sources.list


  4. Change the file permissions if necessary:



    sudo chmod 644 /etc/apt/sources.list



From my Ubuntu 11.04 Live CD:



deb http://archive.ubuntu.com/ubuntu natty main restricted

deb-src http://archive.ubuntu.com/ubuntu natty main restricted

deb http://security.ubuntu.com/ubuntu natty-security main restricted
deb-src http://security.ubuntu.com/ubuntu natty-security main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://archive.ubuntu.com/ubuntu natty-updates main restricted
deb-src http://archive.ubuntu.com/ubuntu natty-updates main restricted


## Uncomment the following two lines to add software from the 'universe'
## repository.
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
# deb http://archive.ubuntu.com/ubuntu natty universe
# deb-src http://archive.ubuntu.com/ubuntu natty universe
# deb http://archive.ubuntu.com/ubuntu natty-updates universe
# deb-src http://archive.ubuntu.com/ubuntu natty-updates universe
# deb http://security.ubuntu.com/ubuntu natty-security universe

# deb-src http://security.ubuntu.com/ubuntu natty-security universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
# deb http://archive.ubuntu.com/ubuntu natty multiverse
# deb-src http://archive.ubuntu.com/ubuntu natty multiverse
# deb http://archive.ubuntu.com/ubuntu natty-updates multiverse

# deb-src http://archive.ubuntu.com/ubuntu natty-updates multiverse
# deb http://security.ubuntu.com/ubuntu natty-security multiverse
# deb-src http://security.ubuntu.com/ubuntu natty-security multiverse


For the best download speed, you need to re-select a mirror near you:




  1. Open the Ubuntu Software Center

  2. Open Edit -> Software Sources...


  3. Click the select box next to Download from:

  4. Select a server at your choice



You might want to enable some repositories as well, like Community-maintained Open Source software (universe) and Software restricted by copyright and legal issues (multiverse)


virtualbox - Uninstalled Virtual Box without deleting the VDI



I created a VM using Virtual Box, but I gave it 25 GB, and I had 15 GB free. So I deleted it, and soon, uninstalled Virtual Box, but when I open my filesystem's properties, it is full, I mean to say about 80% of it is still in use, and the vdi file isn't anywhere. How do I free it up?



By default your VirtualBox files should be located in $HOME/VirtualBox VMs/ so if you navigate there you should easily see if there are any remaining .vdi files still in place.



If your files were in a non-default location try running the following in a Terminal window to find them:



find $HOME -iname *.vdi



And when you find the files you can manually delete them...



References:




command line - How to create a bootable Ubuntu USB flash drive from terminal?



Is there any way to create a bootable Ubuntu USB flash drive from the terminal without using any third-party applications like YUMI, Unetbootin, Startup Disk Creator, etc.



I tried to create a bootable Ubuntu flash drive with dd method,



sudo umount /dev/sdb
sudo dd if=/path/to/ubuntu.iso of=/dev/sdb bs=1M



It creates files on the USB disk, but when I try to boot the USB disk it shows an Operating System Not Found error.



You can use dd.



 sudo umount /dev/sd  


where is a letter followed by a number, look it up by running lsblk.




It will look something like



sdb      8:16   1  14.9G  0 disk 
├─sdb1 8:17 1 1.6G 0 part /media/username/usb volume name
└─sdb2 8:18 1 2.4M 0 part


I would dismount sdb1.




Then, next (this is a destructive command and wipes the entire USB drive with the contents of the iso, so be careful):



 sudo dd bs=4M if=path/to/input.iso of=/dev/sd conv=fdatasync  status=progress


where input.iso is the input file, and /dev/sd is the USB device you're writing to (run lsblk to see all drives to find out what is for your USB).



This method is fast and has never failed me.







EDIT: for those on a Mac ending up here, use lowercase for bs=4m:



sudo dd if=inputfile.img of=/dev/disk bs=4m && sync





EDIT: If USB drive does not boot (this happened to me), it is because the target is a particular partition on the drive instead of the drive. So the target needs to be /dev/sdc and not dev/sdc For me it was /dev/sdb .




Reference: https://superuser.com/a/407327 and https://askubuntu.com/a/579615/669976


software installation - How can I install Extra CMake Modules on Ubuntu 14.04 (Trusty)



I'm trying to build something from source using CMake that is intended for the current (16.04 - Xenial) build. It seems to depend on ECM which seems to be Extra CMake Modules (aka extra-cmake-modules on Xenial). It doesn't seem to be available for 14.04.



Any ideas how to get it, or instructions as to where I can download the source and build a package for Trusty, that I could install?




Edit (Brought to top)



git clone git://anongit.kde.org/extra-cmake-modules
cd extra-cmake-modules
mkdir build
cd build
cmake .. # or run : cmake -DCMAKE_INSTALL_PREFIX=/usr .. &&
make
sudo make install



You can install the latest qt version as follows:



wget http://download.qt.io/official_releases/qt/5.7/5.7.0/qt-opensource-linux-x64-5.7.0.run
chmod +x qt-opensource-linux-x64-5.7.0.run
./qt-opensource-linux-x64-5.7.0.run


Original answer




The extra-cmake-modules is available on Ubuntu 16.04 , 16.10 and 17.04 version.




No summary available for extra-cmake-modules in ubuntu utopic.




You can install it on Ubuntu 14.04 but it is not recommended , it can break your System.



You can edit your /etc/apt/sources.list then add the following line:




deb http://cz.archive.ubuntu.com/ubuntu xenial main universe


Then update your system some dependencies will be upgraded



to install it run:



sudo apt install extra-cmake-modules


usb drive - Use a ext4 USB stick as "normal" pendrive

My goal is to have a USB drive in ext4 and to use it as a normal Fat32/NTFS pendrive (or usb box drive). I would be happy to forget NTFS and Fat32 and to use this USB Drive with all pc in my local net. By the use of CHMOD and CHOWN I would create a REALLY everyone drive in ext4. Every mountpoint should be for everyone. Tons of command line rows are written but no tutorial and simple procedures to make it possible. Thanks.

apt - Archive repository for Ubuntu 12.10


Ubuntu 12.10 is not supported any more since May 2014.


Why is there no archived version at http://old-releases.ubuntu.com/ ?



Although the Files for quantal are not listed, the files have actually been moved and can be found here:


http://old-releases.ubuntu.com/ubuntu/dists/quantal


edit /etc/apt/sources.list and change 'archive.ubuntu.com' to 'old-releases.ubuntu.com'


You can do this with sed


sudo sed -i -e 's/archive.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list

then update with


sudo apt-get update && sudo apt-get dist-upgrade

Attention: you should only use the old-release archive if you have no possibility to upgrade to a newer version, because you won't get any security updates using these old archives


Monday, October 21, 2019

boot - Grub drops to shell after update

Kubuntu 19.04, updated as of May 17th.



This morning I ran updates on my Kubuntu installation, and after reboot, grub drops me to grub shell without giving me my grub menu. This has happened to me a few times over the last few months, and I end up just re-installing because I gave up trying to figure out how to fix it. But I'm at this point again, and I would like to figure out what's causing this.




Hardware:




  • AMD Ryzen 2600X


  • 16GB Ram


  • Asus B450 Motherboard


  • 1x Samsung Evo 500 GB SSD (Primary drive)


  • 1x Seagate 1TB HDD (Storage Drive)


  • No other OS's





Manually entering the following at the grub screen allows my system to boot (obfuscated the UUID) and function normally:




> insmod gzio



> insmod part_gpt



> insmod btrfs




>linux /@/boot/vmlinuz-5.0.0-15-generic root=UUID=0000000-000-000 ro
rootflags=subvol=@ quiet splash



> initrd /@/boot/initrd.img-5.0.0-15-generic



> boot




But, this is obviously annoying to have to do every reboot. I've checked my configuration files, everything looks fine, but it just seems like grub cannot read the configuration files for some reason.




The UUID for my primary drive has been obfuscated below, but I did verify that it is accurate in my configuration files.



/etc/fstab:



# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#

#
# / was on /dev/sda2 during installation
# /boot/efi was on /dev/sda1 during installation
UUID=4DD8-BE9A /boot/efi vfat umask=0077 0 1
# /home was on /dev/sda2 during installation
/swapfile none swap sw 0 0

UUID=0000000-000-000 / btrfs rw,relatime,compress=zstd,ssd,discard,space_cache,subvol=@ 0 1
UUID=0000000-000-000 /home btrfs rw,relatime,compress=zstd,ssd,discard,space_cache,subvol=@home 0 2
UUID=0000000-000-000 /var btrfs rw,relatime,compress=zstd,ssd,discard,space_cache,subvol=@var 0 2


UUID=1111111-111-111 /mnt/storage btrfs rw,relatime,compress=zstd,ssd,discard,space_cache 0 2


/boot/grub/grub.cfg



#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates

# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
set have_grubenv=true
load_env
fi
if [ "${initrdfail}" = 2 ]; then
set initrdfail=

elif [ "${initrdfail}" = 1 ]; then
set next_entry="${prev_entry}"
set prev_entry=
save_env prev_entry
if [ "${next_entry}" ]; then
set initrdfail=2
fi
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"

set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else

menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry

set boot_once=true
fi

function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function initrdfail {

if [ -n "${have_grubenv}" ]; then if [ -n "${partuuid}" ]; then
if [ -z "${initrdfail}" ]; then
set initrdfail=1
if [ -n "${boot_once}" ]; then
set prev_entry="${default}"
save_env prev_entry
fi
fi
save_env initrdfail
fi; fi

}
function recordfail {
set recordfail=1
# GRUB lacks write support for btrfs, so recordfail support is disabled.
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop

insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}

if [ x$feature_default_font_path = xy ] ; then

font=unicode
else
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 60000000-000-000
else
search --no-floppy --fs-uuid --set=root 0000000-000-000
fi

font="/@/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_CA
insmod gettext

fi
terminal_output gfxterm
if [ "${recordfail}" = 1 ] ; then
set timeout=30
else
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=1
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.

else
set timeout=1
fi
fi
if [ $grub_platform = efi ]; then
set timeout=30
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
fi
fi

### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
#set_background_image "images/tile.png";

set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
if background_color 0,0,0; then

clear
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
set gfxpayload="${1}"
if [ "${1}" = "keep" ]; then
set vt_handoff=vt.handoff=1
else

set vt_handoff=
fi
}
if [ "${recordfail}" != 1 ]; then
if [ -e ${prefix}/gfxblacklist.txt ]; then
if hwmatch ${prefix}/gfxblacklist.txt 3; then
if [ ${match} = 0 ]; then
set linux_gfx_mode=keep
else
set linux_gfx_mode=text

fi
else
set linux_gfx_mode=text
fi
else
set linux_gfx_mode=keep
fi
else
set linux_gfx_mode=text
fi

export linux_gfx_mode
menuentry 'Ubuntu' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-0000000-000-000' {
recordfail
load_video
gfxmode $linux_gfx_mode
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'

if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 0000000-000-000
else
search --no-floppy --fs-uuid --set=root 0000000-000-000
fi
linux /@/boot/vmlinuz-5.0.0-15-generic root=UUID=0000000-000-000 ro rootflags=subvol=@ quiet splash $vt_handoff
initrd /@/boot/initrd.img-5.0.0-15-generic
}
submenu 'Advanced options for Ubuntu' $menuentry_id_option 'gnulinux-advanced-0000000-000-000' {
menuentry 'Ubuntu, with Linux 5.0.0-15-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.0.0-15-generic-advanced-0000000-000-000' {

recordfail
load_video
gfxmode $linux_gfx_mode
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 0000000-000-000

else
search --no-floppy --fs-uuid --set=root 0000000-000-000
fi
echo 'Loading Linux 5.0.0-15-generic ...'
linux /@/boot/vmlinuz-5.0.0-15-generic root=UUID=0000000-000-000 ro rootflags=subvol=@ quiet splash $vt_handoff
echo 'Loading initial ramdisk ...'
initrd /@/boot/initrd.img-5.0.0-15-generic
}
menuentry 'Ubuntu, with Linux 5.0.0-15-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.0.0-15-generic-recovery-0000000-000-000' {
recordfail

load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 60000000-000-000
else
search --no-floppy --fs-uuid --set=root 0000000-000-000

fi
echo 'Loading Linux 5.0.0-15-generic ...'
linux /@/boot/vmlinuz-5.0.0-15-generic root=UUID=0000000-000-000 ro recovery nomodeset rootflags=subvol=@
echo 'Loading initial ramdisk ...'
initrd /@/boot/initrd.img-5.0.0-15-generic
}
menuentry 'Ubuntu, with Linux 5.0.0-13-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.0.0-13-generic-advanced-698b5d59-0000000-000-000' {
recordfail
load_video
gfxmode $linux_gfx_mode

insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 0000000-000-000
else
search --no-floppy --fs-uuid --set=root 0000000-000-000
fi

echo 'Loading Linux 5.0.0-13-generic ...'
linux /@/boot/vmlinuz-5.0.0-13-generic root=UUID=0000000-000-000 ro rootflags=subvol=@ quiet splash $vt_handoff
echo 'Loading initial ramdisk ...'
initrd /@/boot/initrd.img-5.0.0-13-generic
}
menuentry 'Ubuntu, with Linux 5.0.0-13-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.0.0-13-generic-recovery-0000000-000-000' {
recordfail
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi

insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 0000000-000-000
else
search --no-floppy --fs-uuid --set=root 0000000-000-000
fi
echo 'Loading Linux 5.0.0-13-generic ...'
linux /@/boot/vmlinuz-5.0.0-13-generic root=UUID=0000000-000-000 ro recovery nomodeset rootflags=subvol=@

echo 'Loading initial ramdisk ...'
initrd /@/boot/initrd.img-5.0.0-13-generic
}
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###

### END /etc/grub.d/20_linux_xen ###


### BEGIN /etc/grub.d/20_memtest86+ ###
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'System setup' $menuentry_id_option 'uefi-firmware' {
fwsetup

}
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###

if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###


/etc/default/grub




# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'

GRUB_DEFAULT=0
GRUB_TIMEOUT=1
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""


# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal

# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"


# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"


Nothing in /etc/grub/grub.d except empty (commented out) init-select.cfg



Output of update-grub:



~# update-grub
Sourcing file `/etc/default/grub'

Sourcing file `/etc/default/grub.d/init-select.cfg'
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-5.0.0-15-generic
Found initrd image: /boot/initrd.img-5.0.0-15-generic
Found linux image: /boot/vmlinuz-5.0.0-13-generic
Found initrd image: /boot/initrd.img-5.0.0-13-generic
Adding boot menu entry for EFI firmware configuration
done



Output of fdisk:



~# fdisk -l
Disk /dev/sda: 465.8 GiB, 500107862016 bytes, 976773168 sectors
Disk model: Samsung SSD 850
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 222222222-2222-2222222


Device Start End Sectors Size Type
/dev/sda1 2048 999423 997376 487M EFI System
/dev/sda2 999424 976771071 975771648 465.3G Linux filesystem


Disk /dev/sdb: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: ST31000524AS
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 33333333333-3333-3333333

Device Start End Sectors Size Type
/dev/sdb1 2048 1953519615 1953517568 931.5G Linux filesystem


Contents of /boot/efi




# find /boot/efi
/boot/efi
/boot/efi/EFI
/boot/efi/EFI/ubuntu
/boot/efi/EFI/ubuntu/grubx64.efi
/boot/efi/EFI/ubuntu/shimx64.efi
/boot/efi/EFI/ubuntu/mmx64.efi
/boot/efi/EFI/ubuntu/BOOTX64.CSV
/boot/efi/EFI/ubuntu/grub.cfg
/boot/efi/EFI/BOOT

/boot/efi/EFI/BOOT/BOOTX64.EFI
/boot/efi/EFI/BOOT/fbx64.efi
/boot/efi/EFI/BOOT/mmx64.efi


I'm not sure what else I can look at here unless someone has any suggestions?



Edit: I have a laptop that has a very similar setup to this (my desktop), and it is not having the same issue. The one notable difference that I can see is in the /boot/grub/grub.cfg file, my laptop doesn't have the "set root='hd0,gpt2'" line for the grub menuentry. Not sure if that's related or not, but it wouldn't explain why I just don't get the menu at all.

11.10 - Can&#39;t boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...