Linux Lite Forums

Software - Support => Installing Linux Lite => Topic started by: m654321 on August 01, 2014, 11:57:59 PM

Title: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 01, 2014, 11:57:59 PM
Like a few of you, I have tried to dual boot LL 2.0 with other closely related distros, i.e. based on the Ubuntu 14.04 - when I choose LL 2.0 from the choice presented on the screen at boot-up, I get an error message that says "a filename was expected". In contrast, the previous LL 1.0.8 version does dual boot smoothly with other distros. Apparently, from reading elsewhere on this forum, it appears the problem has arisen from version 2 being adapted to dual boot more smoothly with Windows 7 or XP which has consequently made it incompatible with dual boots with other distros. Personally, I prefer running XP or Win 7 in a virtual machine, rather than dual booting because (1) it's quicker (I don't have to reboot in order to change the OS), and (2) I have been able to share files using a network link between the linux host and the MS Windows guest.

I am a newbie to Linux (post Win XP) though am becoming increasingly familiar with the use of basic command line in the terminal. I wondered if  someone could give myself and other newbies easy step-by-step instructions on how to modify the relevant root files or other files in LL 2.0 so that it is compatible with other Ubuntu 14.04 based distros in a dual boot situation.  Would it be possible to do this before you pull the plug on LL 1.0.8 support in the next few days?  I would be so grateful to anyone able to do this... 

Kind regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: Jerry on August 02, 2014, 01:09:19 AM
Hi Mike, thanks for posting. The whole approach of Linux Lite is geared towards introducing Windows people to linux. With this in mind, everything we do, every decision we make is with the Windows user in mind. I don't know of many distros that focus completely on this group of users, some are purely for linux people whilst others attempt to please both sides. I am passionate about showing people there are alternatives to proprietary operating systems. We are not 'pulling the plug on LL 1.0.8 support' the upgrade procedure is clearly documented https://www.linuxliteos.com/forums/index.php?topic=645.0

Just wanted to explain things to give you and others a better insight into the Linux Lite project. Cheers :)
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 02, 2014, 01:14:48 AM
The dual-boot problem only occurs when another OS's grub is in charge of booting computer.  Easiest way to solve the problem is to make sure LL 2.0 is in charge of booting.  You can do that in one of two ways:

1.  Install LL 2.0 last and direct grub bootloader installation to the MBR of the drive (which is normally the default on any installation).

2.  If LL 2.0 is already on system and you don't want to bother re-installing it again, you can direct a re-installation of grub using a live DVD/USB.  To do that, first determine which partition on the drive is your LL root partition, then follow instructions on this page to re-install grub while booted with LL install DVD/USB:  https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal (https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal).  If other OSs don't show on grub menu upon reboot, just boot into LL and run this in a terminal:
Code: [Select]
sudo update-grub
They'll all be on menu on subsequent boot-ups.


If you need help with any of this, post back with questions and details of your current situation:
-- What's already installed?
-- What is current partition layout?
Code: [Select]
sudo blkid
sudo parted -l
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 02, 2014, 03:29:20 AM
Many thanks Valtam and Gold Finger for both feedbacks - really helpful.

Valtam, I think your identification of Windows-users-in-transition as the target audience for LL (e.g. people like me!) is a an excellent aim.  My opinion is that those distros that try to satisfy both camps (i.e. both linux-competent & linux-newbie) risk being a bit too 'high-brow' for some of us beginners (me included), especially those without any programming background.  Thankyou also for the link for continued LL 1.0.8 support and the upgrade. Does the upgrade change the appearance or layout of 1.0.8 in any way?

Thankyou Gold Finger, for the instructions on how to dual boot LL 2.0 with another distro. Is it true that, in general, it's inadvisable to have a shared /home partition between the two distros (even if both based on the same release of Ubuntu e.g. 14.04), as the distros may interfere with each other via home with ugrades/updates etc? 

Kind regards
Mike

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: Jerry on August 02, 2014, 03:30:47 AM
Quote from: m654321

Does the upgrade change the appearance or layout of 1.0.8 in any way?


No :)
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 02, 2014, 11:28:34 AM
The /home directory(or partition) normally holds user program configuration files in addition to the user's data files.  It is possible that some of those config files may cause conflicts from one distro to the next, even if both distros have same base (Ubuntu for instance).  What I do to get around that potential problem is keep all data files on a separate partition that gets used by all distros and let each distro have their own /home.  By doing that, each distro's home only ends up containing the config files it needs along with links to the data on that separate partition.  It looks and acts like a normal setup, but the data is not physically on that /home.

Here is a tutorial describing how to do that:  https://www.linuxliteos.com/forums/index.php?topic=203.0 (https://www.linuxliteos.com/forums/index.php?topic=203.0).  When using a separate data partition like that, I don't bother making /home a separate partition -- I just let it reside on the same partition as root.  If you decide to still make /home as a separate partition, just keep in mind that it doesn't need to be very big because it's only holding config files.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 06, 2014, 10:18:20 AM
The dual-boot problem only occurs when another OS's grub is in charge of booting computer.  Easiest way to solve the problem is to make sure LL 2.0 is in charge of booting.  You can do that in one of two ways:

1.  Install LL 2.0 last and direct grub bootloader installation to the MBR of the drive (which is normally the default on any installation).

2.  If LL 2.0 is already on system and you don't want to bother re-installing it again, you can direct a re-installation of grub using a live DVD/USB.  To do that, first determine which partition on the drive is your LL root partition, then follow instructions on this page to re-install grub while booted with LL install DVD/USB:  https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal (https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal).  If other OSs don't show on grub menu upon reboot, just boot into LL and run this in a terminal:

I tried the above, and used the instructions in the link, but sadly I couldn't get this to work.  In my dual boot system (LL 2.0 with zorin 9, both are ubuntu 14.04), only zorin showed up on grub screen.  So I mounted LL 2.0 using the Terminal within the live DVD of zorin 9 (and a subsequent attempt with LL live DVD), deleted/removed Grub from LL's sda (i.e. using sudo apt-get remove grub; sudo apt-get purge grub; sudo apt-get autoremove), and then reinstalled it according to your instructions.  This had the effect of grub now showing both distros listed, but when I choose LL it went to the LL's start up screen but hung indefinitely at this screen. A forced restart by pressing the Ctrl-Alt-Del keys produced the same again.  LL 1.0.8 dual boots very smoothly with zorin 9 - no issues whatsoever. By the way I ensured that LL 2 had the bootloader - on my laptop the first distro that is set up carries the flag boot, not the second as you mentioned in point (1) above. If I load LL 2 last, zorin 9 has the boot flag instead.  I tried redirecting the bootloader to LL using Gparted when I set up LL 2 last (instead of first), using the Gparted option to do this, but this didn't work either.

Shall I still send you a screenshot from Gparted or an output from the terminal (i.e. from sudo blkid). It would be great to dual boot LL 2.0 with another distro, instead of using LL 1.0.8 with another distro, as the more up to date LL version is significantly better.  Anyway, hopefully this one can be cracked... thanks for your continued support on this one.

Kind regards
Mike

 
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 06, 2014, 12:08:58 PM
See quote in post above - I tried the above, and used the instructions in the link, but sadly I couldn't get this to work.  In my dual boot system (LL 2.0 with zorin 9, both are ubuntu 14.04), only zorin showed up on grub screen.  So I mounted LL 2.0 using the Terminal within the live DVD of zorin 9 (and a subsequent attempt with LL live DVD), deleted/removed Grub from LL's sda (i.e. using sudo apt-get remove grub; sudo apt-get purge grub; sudo apt-get autoremove), and then reinstalled it according to your instructions.  This had the effect of grub now showing both distros listed, but when I choose LL it went to the LL's start up screen but hung indefinitely at this screen. A forced restart by pressing the Ctrl-Alt-Del keys produced the same again.  LL 1.0.8 dual boots very smoothly with zorin 9 - no issues whatsoever. By the way I ensured that LL 2 had the bootloader - on my laptop the first distro that is set up carries the flag boot, not the second as you mentioned in point (1) above. If I load LL 2 last, zorin 9 has the boot flag instead.  I tried redirecting the bootloader to LL using Gparted when I set up LL 2 last (instead of first), using the Gparted option to do this, but this didn't work either.

Shall I still send you a screenshot from Gparted or an output from the terminal (i.e. from sudo blkid). It would be great to dual boot LL 2.0 with another distro, instead of using LL 1.0.8 with another distro, as the more up to date LL version is significantly better.  Anyway, hopefully this one can be cracked... thanks for your continued support on this one.

Kind regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 06, 2014, 02:45:32 PM
Shall I still send you a screenshot from Gparted or an output from the terminal (i.e. from sudo blkid).

Yes, go ahead and post a screenshot from GParted showing the partitions on the drive.  (This post (https://www.linuxliteos.com/forums/index.php?topic=487.0) describes how to post a screenshot and terminal output if you need that info.)

Sounds like you can not boot into LL 2.0 at this point and the drive currently has only Zorin and LL on it.  Is that correct?  If not, tell us how many OSs are on the drive, which ones they are, and which ones you are able to boot into currently?

If you can boot into LL 2.0, then go ahead and do that.  If not, boot into Zorin and run the commands below.  (Let us know which distro you ran the commands from.)

Code: [Select]
lsblk
sudo blkid -c /dev/null
sudo parted -l
sudo os-prober

Just in case we can't tell from screenshot and command output, if you are currently sharing one /home partition between both OSs, let us know that.

I am pretty sure we can get this to work and that you probably just made a slight error in your prior attempt.  Also, just so you know, the boot flag shown in GParted is not something to worry about.  It's my understanding that, unless you have a very ancient BIOS,  Linux just ignores the boot flag.  (I could be wrong, but fairly certain I read that somewhere before.)
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 07, 2014, 08:39:53 AM
A big thank you for your continued support gold_finger.
Re: zorin/LL dual boot: sda1 = zorin 9; sda2 = LL 2.0. 
Below is the output copied/pasted from terminal, which I did from zorin (though LL now shows listed in grub screen, clicking on it produces an error message about a filename being expected)

zorin9@zorin9-X71Q:~$ lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda           8:0   0  74.5G  0 disk
├─sda1   8:1    0  37.3G  0 part /
└─sda2   8:2    0  37.3G  0 part
sdb      8:16   0 931.5G  0 disk
├─sdb1   8:17   0     1K  0 part
├─sdb2   8:18   0   9.5G  0 part [SWAP]
└─sdb5   8:21   0   922G  0 part /mnt/DATA
sr0     11:0    1  1024M  0 rom 

zorin9@zorin9-X71Q:~$ sudo blkid -c /dev/null
[sudo] password for zorin9:
/dev/sda1: UUID="ddb72935-02d6-49ea-973b-053d68e104bb" TYPE="ext4"
/dev/sda2: UUID="fcde3e47-a512-482f-9ac7-00506968b433" TYPE="ext4"
/dev/sdb2: UUID="5147c0ce-be05-47ab-be26-c623dff3d701" TYPE="swap"
/dev/sdb5: UUID="fc6ae4e0-1269-4163-a832-72df39c54914" TYPE="ext4"

zorin9@zorin9-X71Q:~$ sudo os-prober
  No volume groups found
/dev/sda2:Linux Lite 2.0 (14.04):Ubuntu:linux
zorin9@zorin9-X71Q:~$

Below is a blow-by-blow account of the dual distro set up...

Setting up a dual boot system for two distros (Linux Lite OS 2.0 with Zorin OS 9, both 64-bit)
On the first hard drive Zorin was installed, followed by LL.  On a second internal hard drive, a separate DATA partition was created to share files between the two distros, together with a separate swap file partition.
1. Set-up DVD for Zorin placed in DVD reader
2. “Install Zorin” option chosen
3. “download updates while installing” chosen
4. “something else” chosen
5. “new partition table” for sda (80 GB) and sdb (1 TB) chosen
6. The partition table ... the 80GB drive was partitioned into two parts.  The first, sda1, for installing Zorin was made a primary partition, while sda2 (for LL) was left as free space.

Device         Type   Mount point   Format           Size               Used            System
/dev/sda   
/dev/sda1        ext4      /                    Yes                   39998 MB     unknown
free space                                                                 40026 MB
/dev/sdb
/dev/sdb5        ext4     /mnt/DATA  Yes                  989999 MB    15745 MB
/dev/sdb2        swap                                                10203 MB             0 MB

7. Zorin files then copied from DVD and installed - username chosen = zorin9. Set up for zorin then completed.
8. Set-up DVD for LL placed in DVD reader
9. “execute LL”  chosen
10. “download updates while installing” chosen
11. “something else” chosen
12. Click on free space under /dev/sda
13. Click “+” and choose new partition for the free space, now made into sda2
14. Appearance of new partition table...
/mnt/DATA was retyped for sdb5 but format option NOT chosen.
Primary partition was chosen for sda2 with mount point at “/” chosen

Device      Type   Mount point   Format           Size               Used            System
/dev/sda   
/dev/sda1            ext4                                            39998 MB    10746 MB   Zorin OS 9 (9)
/dev/sda2            ext4      /                Yes                   40026 MB     unknown
/dev/sdb
/dev/sdb5            ext4     /mnt/DATA  Yes                 989999 MB    15745 MB
/dev/sdb2          swap                                                 10203 MB             0 MB

15. On the partition table window, the device shown for boot loader installation is given as:
/dev/sda      ATA FUJITSU MHW2080B (80 GB)   
However the option for boot loader installation on /dev/sda2 (which is the LL 2.0 partition) is the one chosen.


16. page shows that the default option this will be installed on.
However the option to change this to /dev/sda2 is chosen
17. LL  files then copied from DVD and installed - username chosen = ll2 (lower case LL!). Set up for LL then completed
18. Computer rebooted: Zorin appears on the grubscreen, but not LL.
19. Click on option for Zorin and the OS loads.
Appearance of partition table from Zorin using Gparted...
Device      Type       Mount point   Size               Used            Unused     Flags
/dev/sda   
/dev/sda1         ext4        /                  37.25 GB      10.01 GB      27.24 GB   boot
/dev/sda2         ext4                          37.28 GB        3.65 GB      33.63 GB
/dev/sdb
/dev/sdb1         extended                   922.01 GB         -                      -
/dev/sdb5         ext4     /mnt/DATA    922.01 GB       14.66 GB     907.34 GB
/dev/sdb2         linux swap                     9.50 GB         4.00 KB         9.50 GB

20. After installing updates for Zorin a message regarding Debconf on zorin9-X71Q presents the following...
Configuring grub-pc
What do you want to do about modified configuration file grub?
Install the package maintainer’s version?
Keep the local version currently installed?
Show the difference between the two versions?
Show a side-by-side difference between the versions?
Show a 3-way difference between available versions?
Do a 3-way merge between available versions (experimental)?
Start a new shell to examine the situation?

I choose the first option in this list.

On rebooting LL and zorin appear as choices in grub screen but when LL chosen, a black screen is presented with an underlined message shown as “error: filename expected. Press any key to continue. . .”   though Zorin continues to reboot normally.

Please let me know if you need any other information.
Many thanks indeed for you time on this.
Kind regards
Mike

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 07, 2014, 12:14:46 PM
m654321,

Thanks for the detailed response.  This should be an easy fix!  However, now that I see how thorough you are, I'm worried that you may not have made some minor error before and the problem is more difficult than I first thought.  We'll soon find out.  Follow steps below and everything should end up working.  If it doesn't then we've got a more difficult problem than I thought.

*  Boot computer with live Linux Lite DVD (not Zorin DVD)

*  When up and running, open a terminal

*  Mount the LL2 root partition on the HDD to the live environment
Code: [Select]
sudo mount /dev/sda2 /mnt
*  Install grub to the MBR of sda drive
Code: [Select]
sudo grub-install --boot-directory=/mnt/boot /dev/sda
*  Unmount the LL2 root partition
Code: [Select]
sudo umount /dev/sda2
*  Close terminal, shutdown live DVD and remove from tray.

*  Boot computer normally again and you should have LL2 grub menu show up with LL2 being first (default) choice and Zorin further down list.  (LL2 is now in charge of booting the computer.)  It's possible that it may either boot straight into LL2 without giving boot menu, or show boot menu without Zorin on it.  If either of those two things happens, then let computer boot into LL2, open a terminal and run command to update grub.  That should add Zorin to menu and cause grub menu to show on next reboot.
Code: [Select]
sudo update-grub

Let us know if this worked.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 07, 2014, 02:17:16 PM
Great news !! It w-o-r-k-s ....

....just to be certain of this (after entering in the terminal what you suggested in the above post, I logged off & rebooted into both LL & zorin at least a couple of times.  I discovered that I didn't even need to remount LL.  I think it didn't work before as the command "sudo umount /dev/sda2" was missing.

Gold_finger, I assume you are one of the development team at LL - is that correct?  I really appreciate how helpful you have been.  To express my gratitude I've just made a donation to the LL cause... keep up the excellent work!

Kind regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 07, 2014, 09:52:56 PM
m654321,

Glad to here all worked out well.

Quote from: m654321
Gold_finger, I assume you are one of the development team at LL - is that correct?  I really appreciate how helpful you have been.  To express my gratitude I've just made a donation to the LL cause... keep up the excellent work!
Yes, but only in a minor way.  Valtam is the mastermind behind LL development.  So far, I've only contributed content to the Help Manual, but am not involved in coding of system.  (Am trying to learn some programming and maybe I'll get to the point where I can contribute in that way also in the future.)  On behalf of LL, thank you very much for the donation -- it's much appreciated.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 12, 2014, 11:50:59 AM
Gold_Finger, you said re. shared data partition...
Quote
Here is a tutorial describing how to do that:  https://www.linuxliteos.com/forums/index.php?topic=203.0.  When using a separate data partition like that, I don't bother making /home a separate partition -- I just let it reside on the same partition as root.  If you decide to still make /home as a separate partition, just keep in mind that it doesn't need to be very big because it's only holding config files.

The above was to do with creating a separate /mnt/DATA partition to share between zorin & LL. I did this - it worked well using the symlink method.  However I have two internal hard drives on my laptop and would like to organize partitions in such a way as to increase efficiency in the way the two operating systems work.  The core of each OS will go on sda, while the /mnt/DATA and separate home partitions (i.e. zorin6/home and ll2/home) will go on sdb.

My question is this -  ...when I create the links from zorin & LL to /mnt/DATA, I assume should use the UUIDs of the separate home partitions on sdb, rather than the UUIDs of the core of the operating systems on sda? Also if I run a virtual machine (e.g. using Oracle Virtualbox to run Windows XP), will this automatically be installed on /mnt/DATA, or will it appear in zorin/home or ll/home?

PS. Yes, I found the config files on the separate home partitions for both zorin and LL only took up between 60 and 70 MB of disk space.

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 12, 2014, 06:50:18 PM
Quote from: m654321
Also if I run a virtual machine (e.g. using Oracle Virtualbox to run Windows XP), will this automatically be installed on /mnt/DATA, or will it appear in zorin/home or ll/home?
I'm going to answer this first.

Virtual Box creates two things in your home folder -- configuration related files and a place where it stores your VMs (Virtual Machines).

If you want the VMs to be saved on your DATA partition (good idea), you will need to create a folder on the DATA partition for them first ("VBox_VMs" for example).  Then copy everything in /home/username/Virtualbox VMs over to /mnt/DATA/VBox_VMs.  ("VBox_VMs" is just my example -- you can be name it whatever you want.  Would be best to not have spaces in the name.)  Once you've copied that over, open VirtualBox and change the default location that it looks to for those VMs.

*  From main VBox window, click File -> Preferences
*  Under General -> Default Machine Folder fill-in the location where you want those VMs to be stored.  In your case, that will be something like /mnt/DATA/VBox_VMs.  (Mine reads differently because I use the bind method instead of symlinks.)
(http://ibin.co/1WsNFhopeFkT)

*  Click OK when done.
*  Shutdown VBox and restart it.

I can't remember if the machines you have automatically show as available right away or if you need to "add" them back to main interface window.  If you don't see them, click Machine -> Add.  That will open the new folder location that you set for it to look in and list your VMs.  Highlight the one you want and hit Open.

Once you confirm that everything works, go ahead and delete that original folder, /home/username/VirtualBox VMs.

If you want to create a symlink to that new folder location in /home/username follow same format as you did to create the other symlinks:
Code: [Select]
ln -s /mnt/DATA/VBox_VMs /home/username

If you want the VMs to be save in your /home partition, then you'll need to take that into account when choosing a size for the /home partitions.  It will need to be much bigger in order to accomodate the size of the virtual drives you'll be making.  However, it doesn't make a whole lot of sense to put them in /home.  If you have them on the DATA partition, you can keep and re-use them when installing new OSs and you can also use the same VMs in both LL and Zorin rather than duplicating them in each OS's /home.



Quote from: m654321
However I have two internal hard drives on my laptop and would like to organize partitions in such a way as to increase efficiency in the way the two operating systems work.  The core of each OS will go on sda, while the /mnt/DATA and separate home partitions (i.e. zorin6/home and ll2/home) will go on sdb.

My question is this -  ...when I create the links from zorin & LL to /mnt/DATA, I assume should use the UUIDs of the separate home partitions on sdb, rather than the UUIDs of the core of the operating systems on sda?

I'm assuming you are asking about how entries should look in /etc/fstab file.  Answer is "No".  The UUIDs of the home partitions are not involved in the symlinking process.

With regard to anything on the DATA partition that you are symlinking to, the line for mounting the DATA partition does not change no matter where you are symlinking to.  You still have just one line with the UUID of the DATA partition for auto-mounting it on boot (not counting a comment line you may want to describe the mounting line).  Basically, when you're done each OS will have lines for mounting:

If you are planning to re-install both OSs so they each have a separate /home partition, the install process will automatically create fstab lines for the partitions you designate when installing.  When selecting partitions and setting mount points during the install process, if you also select the DATA partition and assign it the mount point "/mnt/DATA", that too will be automatically entered into the fstab file.  Just remember not to check the box to format that DATA partition if you've already got things on it.  (If you prefer, you can just set up the DATA partition after the installation and manually add the entry needed in fstab.)

If the DATA partition is brand new (not the same one you have already started using), you will need take ownership of the mount point after booting into each distro.
Code: [Select]
sudo chown -R your-username:your-username /mnt/DATA
If you are using same DATA partition that you've already setup, you shouldn't need to do that unless you have changed your username to a different one than what you have now.  That's because in Linux the permissions are set on the filesystem itself and stay with it until you change it again.  You could move that drive to a different computer and as long both computers have you setup with the same username and UID#, you will be able to access and use the files on that DATA partition immediately without needing to use a root password.

If you are planning to add a new /home partition after-the-fact to each installation -- that is a different situation and can be a bit complicated.  I've not done that myself, so here are a couple of links that get into those details:

https://help.ubuntu.com/community/Partitioning/Home/Moving (https://help.ubuntu.com/community/Partitioning/Home/Moving)
http://www.howtogeek.com/116742/ (http://www.howtogeek.com/116742/)

(Not sure if old symlinks will still work or not.  You might need to redo them.) 

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 16, 2014, 01:40:43 AM
Gold_finger, many thanks for the above, which I will try in the next few days while I still have some vacation left...!
A more basic problem with my laptop has presented itself in the last couple of days. I'm unsure whether it's a hardware issue and whether it can be resolved using the terminal.

For some reason. that I'm unable to fathom, the internal drives sda and sdb are not working together in a coordinated way. I'll just clarify this. Earlier this month, to maximise efficiency of operation, I put the core part of the distro OS on sda, and the /home, /mnt/DATA, and swap on sdb.  It worked very well and I noticed, as you'd expect, a much crisper snappier response from the computer with open/closing files etc.  However, this doesn't happen any longer. The entirety of the OS has to be installed on either sda or sda - no sharing of parts of the OS between sda & sdb works any more as I just get a blank (black) screen on boot up (i.e. no grub screen appears) and it just stays like that with the cursor blinking indefinitely. Curiously, the laptop will run two distros separately, that is one installed entirely on sda, the other on sdb and will show both of these listed on the grub screen at boot up.

The only thing that has changed with my set-up was that I bought a USB games steering wheel for my young son so that he could play supertuxkart. A few days later (after he began playing with this) the laptop cut out one day and powered off. The 3A fuse in the plug had blown and was replaced. I also noticed flicker with the graphics after this at the beginning of a game but it disappeared once the game was underway.  At the time, with the steering wheel set-up, I was only using an OS installed entirely on sda.  However since then I have lost coordinated operation between sda and sdb as described in the first para above.  I don't know whether the two are linked and whether I can retrieve normal sda/sdb shared OS operation as before through the use of the terminal.

I'd be grateful for any views or ideas you might have on this. I'm hoping it is not time to fork out for a new laptop...

Kind regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 16, 2014, 06:46:49 AM
Sounds like something got changed by accident on the system.  If both HDDs work without problem when installing one OS in entirety to each, then would guess that nothing wrong with them.  Sounds like you have re-installed that way for now -- correct?  Before you changed to one OS per HDD, did you have problem booting into both OSs from grub menu or just into LL?

I can't think of any reason why booting and performance would get messed up simply by attaching a game wheel.

Do you remember if you performed any updates recently in LL 2.0?  If so, there may have been an update that asked you whether to replace a couple of config files with new versions or keep existing ones.  The right answer to that is to keep the existing configs.  Maybe you replaced them and that somehow caused the problem.  Here's a long post describing what I'm talking about:  https://www.linuxliteos.com/forums/index.php?topic=632.0 (https://www.linuxliteos.com/forums/index.php?topic=632.0).

Have you tried re-installing with partitions spread over both drives again?

I'm really not sure what the problem is.  My setup is similar to yours except I don't use a /home partition.  I have root partitions and a data partition on one drive; swap and a couple of other partitions on another drive.  Below I've attached output showing my drives with mount points and also a copy of my fstab file.

Code: [Select]
bill@Gold:~$ lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 298.1G  0 disk
├─sda1   8:1    0    25G  0 part
├─sda2   8:2    0     1K  0 part
├─sda3   8:3    0 223.1G  0 part /mnt/DATA
└─sda5   8:5    0    25G  0 part /
sdb      8:16   0 596.2G  0 disk
├─sdb1   8:17   0     9G  0 part [SWAP]
├─sdb2   8:18   0   230G  0 part
├─sdb3   8:19   0     1K  0 part
├─sdb5   8:21   0    40G  0 part /mnt/ISOs
├─sdb6   8:22   0    40G  0 part
└─sdb7   8:23   0   200G  0 part /mnt/VBoxHDs
sr0     11:0    1  1024M  0 rom 
bill@Gold:~$ cat /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).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda5 during installation
UUID=a9222190-0805-47ef-a2e2-e98b19d84b54 /               ext4    errors=remount-ro 0       1
# swap was on /dev/sdb1 during installation
UUID=c4933327-f314-42ee-8b4a-ec3e48a0ded5 none            swap    sw              0       0
# Mount DATA partition
UUID=ceee2524-7df2-4d21-a1f7-9e7e55c722cc /mnt/DATA ext4 defaults 0 2
# Mount ISOs partition
UUID=15443ba5-bdd0-4f0d-ae19-420022a7aab7 /mnt/ISOs ext4 defaults 0 0
# Mount VBoxHDs partition
UUID=3e68db3c-2acd-4718-812e-93e10bf63cf5 /mnt/VBoxHDs ext4 defaults 0 0

If you haven't tried re-doing the installs across both HDDs and have the time to do it, try again and make sure your fstab file ends up similar to mine (different UUIDs ofcourse).

If by chance you currently still have this setup
Code: [Select]
zorin9@zorin9-X71Q:~$ lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda           8:0   0  74.5G  0 disk
├─sda1   8:1    0  37.3G  0 part /
└─sda2   8:2    0  37.3G  0 part
sdb      8:16   0 931.5G  0 disk
├─sdb1   8:17   0     1K  0 part
├─sdb2   8:18   0   9.5G  0 part [SWAP]
└─sdb5   8:21   0   922G  0 part /mnt/DATA
sr0     11:0    1  1024M  0 rom 

and can not boot into your installed LL, boot up with your live LL DVD.  Then open a terminal and post back output of following commands:

Code: [Select]
sudo mount /dev/sda2 /mnt
cat /mnt/etc/issue
cat /mnt/etc/lsb-release
cat /mnt/etc/fstab
sudo umount /mnt

Maybe those will give a clue as to what's going wrong.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 17, 2014, 08:19:42 AM
Many thanks for your reply above - I will give this a go...

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 19, 2014, 02:06:43 AM
Gold_finger, the good news is that sda & sdb are now working cooperatively, with the OS files spread out between the two physical drives. With your help, I appear to have solved the problem I mentioned about failure to boot-up, following the LL's OS files being shared between the two hard drives.

The problem I had appears to be due to be me incorrectly using 'Y' in response to being asked to upgrade to the maintainer's newer version, instead of using the correct default option of 'N'. It now explains a lot of the instability I have experienced generally, since I  came over to linux in  April 2014.

I recommend that, within the installation guide, or even as a banner on LL's website home page, the use of default option of  'N' should be very clearly highlighted. I wonder how many newbies to linux have been tripped up with this inadvertent error?  In the link you sent me about this issue, I thought very much the same way as the person in that forum posting who had this very same problem - I assumed (wrongly) that the maintainer's version was Valtam's Linux Lite - the idea of a throwback to Ubuntu never occurred to me.

I have a question on the size for separate  /home/username  partitions for  LL & the other distro in a dual-boot set-up. Since all my usual folders will be in the separate DATA partition, I will, as you pointed out, only need small /home/username partitions. I noticed the files in the separate home appeared to take up around 60-70 MB, following a fresh install, so I set the size for each of the separate home partitions at 250 MB.  This appeared too small, as subsequently some items were missing on panel bar following boot-up.  Another time I used 1.8 GB, and this seemed to be okay. Maybe I should go for 5GB for as a safe bet, as I assumeg the amount of space taken up by config files in /home will increase over time. I have 1TB for sdb, so space is not an issue here.  What do you think?

Also when I create the separate home partitions, should they be named  /home/username  or  /home/username/    (slash also after 'username')
I know you don't use separate  /home  partitions, but I have found that the response of LL appears to be noticeably crisper/snappier with them, so would quite like to continue with this as long as it continues to work (!).
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 19, 2014, 05:05:00 AM
Glad you got it sorted out.

The problem I had appears to be due to be me incorrectly using 'Y' in response to being asked to upgrade to the maintainer's newer version, instead of using the correct default option of 'N'....

I recommend that, within the installation guide, or even as a banner on LL's website home page, the use of default option of  'N' should be very clearly highlighted.

Will look into possible better emphasis in Help Manual.


I have a question on the size for separate  /home/username  partitions for  LL & the other distro in a dual-boot set-up.

Also when I create the separate home partitions, should they be named  /home/username  or  /home/username/    (slash also after 'username')

Size?  2-5GB should be fine, but may vary depending on your exact setup and how you do things.  If you kept the "Desktop" folder in /home/username and you tend to temporarily save/put things on the desktop, keep that in mind as possible guide for the size of /home.  Eg. If you try to download a large 4GB ISO file to the Desktop (instead of Downloads folder on the Data partition), but only made /home 2GB -- the download will fail due to lack of space.

Naming?  You should not be creating the partition as "/home/username" -- partition should just have mount point of "/home".  (Trailing "/" makes no difference -- "/home" and "/home/" mean same thing.)  The system will put all users' home directories under /home automatically, giving you /home/username.  Eg.  If computer is used by two people -- "me" and "you" -- then directories "/home/me" and "/home/you" will be created in "/home" for each user.  (NOTE:  You may want to increase size of /home partition if you will have more than one user on the computer.)
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 21, 2014, 02:55:57 AM
Many thanks gold_finger for this very helpful information.

You mentioned you used the 'binding method' for file sharing on a separate DATA partition. Is 'binding' more advantageous to 'symlinking'?  Though the latter appears to work for me, I might try the former now my confidence with Linux is growing... 

Is it easy to undo the symlinks, which I assume is necessary before proceeding with binding?

Regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 21, 2014, 09:39:42 AM
I used symlinks myself for a while and they worked fine.  Then, out of curiosity (like you), I tried doing it with bind -- which works well also.  Originally I learned how to use bind from this post:  http://forums.linuxmint.com/viewtopic.php?f=42&t=74321 (http://forums.linuxmint.com/viewtopic.php?f=42&t=74321).  (His options #2 and #3 are best for what you want to do.  I happened to pick option #3 in case you're interested.)  In that post, the author states this about advantage of using bind vs. symlinks:
Quote
I should note that another way to accomplish all this is simply to create a symbolic link from one location to the next. However, I live in a very networked environment with a combination of Windows, Macs, and Linux machines so I use Samba and the Samba client cannot follow symbolic links without modifying config files which Samba does not recommend.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 24, 2014, 03:38:29 PM
In the end I simplified things and used more or less the partition system you have, i.e. without separate /home partitions
I have a question about 'binding' - I think I've made a mistake somewhere.

This is the content the upstart job, copied & pasted from the file "bind-home.conf" that I set up...

# Remount partitions with bind
#
description "Bind DATA Partition Subdirectories to My Home Directory"

start on stopped mountall

script
mount --bind /mnt/DATA/Documents /home/m-ll2/Documents
mount --bind /mnt/DATA/Downloads /home/m-ll2/Downloads
mount --bind /mnt/DATA/Linux ISOs /home/m-ll2/Linux ISOs
mount --bind /mnt/DATA/Music /home/m-ll2/Music
mount --bind /mnt/DATA/Photos family /home/m-ll2/Photos family
mount --bind /mnt/DATA/Photos general /home/m-ll2/Photos general
mount --bind /mnt/DATA/Pictures /home/m-ll2/Pictures
mount --bind /mnt/DATA/Public /home/m-ll2/Public
mount --bind /mnt/DATA/Templates /home/m-ll2/Templates
mount --bind /mnt/DATA/TV /home/m-ll2/TV
mount --bind /mnt/DATA/Videos /home/m-ll2/Videos
mount --bind /mnt/DATA/VirtualBox VMs /home/m-ll2/VirtualBox VMs
mount --bind /mnt/DATA/Wallpapers /home/m-ll2/Wallpapers
end script

After I've created the upstart job, should I be doing anything else, e.g. with the terminal? I have just rebooted after saving & closing the above file. I get this message in the terminal whenever I open, save and close the above file....(gedit:2270): IBUS-WARNING **: The owner of /home/m-ll2/.config/ibus/bus is not root! ...maybe there is a problem here.


What should I see when I reboot & open the  '/home'  folder? I don't see the DATA folder , when I open the File Manager.

The 13 folders in the above .conf file have been created in the subfolder 'DATA' within the folder 'mnt', as I saw them under file system  (there is also an additional one called lost+found there).

Many thanks for any help on this.
Regards
Mike

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 24, 2014, 08:37:38 PM
What should I see when I reboot & open the  '/home'  folder? I don't see the DATA folder , when I open the File Manager.

The 13 folders in the above .conf file have been created in the subfolder 'DATA' within the folder 'mnt', as I saw them under file system  (there is also an additional one called lost+found there).

You won't see the DATA folder in /home/m-ll2.  You bound the 13 sub-folders of DATA to your home, but you didn't bind the DATA folder itself to home.

The "lost+found" is normal.  It will be automatically generated to allow you to use the Trash function on the partition.


Your "bind-home.conf" file looks good except for a few lines.  The lines I have in red below are most likely not currently working properly:
mount --bind /mnt/DATA/Documents /home/m-ll2/Documents
mount --bind /mnt/DATA/Downloads /home/m-ll2/Downloads
mount --bind /mnt/DATA/Linux ISOs /home/m-ll2/Linux ISOs
mount --bind /mnt/DATA/Music /home/m-ll2/Music
mount --bind /mnt/DATA/Photos family /home/m-ll2/Photos family
mount --bind /mnt/DATA/Photos general /home/m-ll2/Photos general
mount --bind /mnt/DATA/Pictures /home/m-ll2/Pictures
mount --bind /mnt/DATA/Public /home/m-ll2/Public
mount --bind /mnt/DATA/Templates /home/m-ll2/Templates
mount --bind /mnt/DATA/TV /home/m-ll2/TV
mount --bind /mnt/DATA/Videos /home/m-ll2/Videos
mount --bind /mnt/DATA/VirtualBox VMs /home/m-ll2/VirtualBox VMs
mount --bind /mnt/DATA/Wallpapers /home/m-ll2/Wallpapers

Having spaces in the names of your files and/or folders can cause problems when you try to run commands like those in the bind-home.conf file.  For example, when the system tries to run the command mount --bind /mnt/DATA/Linux ISOs /home/m-ll2/Linux ISOs, it will interpret that as you trying to bind /mnt/DATA/Linux to a place called ISOs because of the space that it encounters between the two words.

You have a choice to make.  Either rename those folders in both /mnt/DATA and /home/m-ll2 and change their respective lines in bind-home.conf file; or either "escape" the spaces or quote the folder names with spaces in them in your bind-home.conf file.

Eg. To change the names, simply use a ".", "-", or "_" in place of the spaces.  Change Linux ISOs to Linux_ISOs, for example.

Eg.  If you keep the spaces in the names, you need to remember to either escape the spaces by putting a backslash character before each space in the name, or put the entire name within quote marks when running commands on those files.  Example of escaping same file as above would be Linux\ ISOs.  Or quote the whole thing, "Linux ISOs"

Personally, I find it much easier to not have names with spaces and just use ".", "-", or "_" in place of a space.  That way I don't have to remember to escape or quote things.

NOTE:  If you change the name of "VirtualBox VMs" folder to "VirtualBox_VMs", you will need to follow my instructions here (https://www.linuxliteos.com/forums/index.php?topic=685.msg4050#msg4050) to tell the VirtualBox program its new default machine folder.  Otherwise it will keep looking for things in "VirtualBox VMs", which will no longer exist.



After I've created the upstart job, should I be doing anything else, e.g. with the terminal?

No need to do any more with terminal.  The bind-home.conf file should be saved (as root) to the /etc/init directory.  To check ownership of the file, open a terminal and enter:
Code: [Select]
ls -l /etc/init
You'll get a long output of lines.  Scroll back to beginning of the output to find the line for bind-home.conf and make sure it shows that it is owned by root (you'll see "root  root" on the line).  Output should look similar to mine shown here:
(http://ibin.co/1Xynznohp6UF)


I have just rebooted after saving & closing the above file. I get this message in the terminal whenever I open, save and close the above file....(gedit:2270): IBUS-WARNING **: The owner of /home/m-ll2/.config/ibus/bus is not root! ...maybe there is a problem here.

I'm not sure what that error message is.  I'm assuming you installed gedit and are using that instead of leafpad.  Exactly how did you try opening the bind-home.conf file?  Through the file manager, or with a terminal command?

If you used a terminal command, did you use sudo gedit /etc/init/bind-home.conf or gksu gedit /etc/init/bind-home.conf?  When you open GUI programs (like the text editor) as root, you should use gksu instead of sudo.  Maybe that is what caused the error message.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 25, 2014, 01:30:45 AM
Gold_finger, as you suggested, I filled up the gaps in the folder names in the bind-home.conf file (with hyphen), as well as in the /mnt/DATA and /home/m-ll2 folders. Following reboot, right-clicking on any of the folders in /home/m-ll2 indicates 924GB free so they appear to me to have all bound successfully to /mnt/DATA on the 1TB drive at sdb. I assume that's a correct asumption.  The only other thing on sdb is the swap partition (I abandoned a separate '/home' for each OS and have adopted the system that you more or less use. 

I ran the command 'ls -l /etc/init' in terminal and got the following output for bind-home.conf. I appear to have ownership by 'root' but, the file seems to have been duplicated, the difference being the tilde symbol following the second entry (see below). Should the second entry be deleted. How should I do this??

-rw-r--r-- 1 root root  864 Aug 25 05:56 bind-home.conf
-rw-r--r-- 1 root root  864 Aug 25 05:49 bind-home.conf~

You ask me a few things. I installed gedit and used this to create the upstart file, though think I might have used leafpad initially, so may still have an erroneous leafpad file floating out there (!) I did use sudo to open and edit the bind-home.conf file (I used terminal, not file manager) but now realize my error (thanks to your advice) and am now using gksu.

Many thanks for your continued support.
Regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 25, 2014, 06:30:58 PM
Excellent!  Sounds like you've got it all working right now.  Good job!  :D

I ran the command 'ls -l /etc/init' in terminal and got the following output for bind-home.conf. I appear to have ownership by 'root' but, the file seems to have been duplicated, the difference being the tilde symbol following the second entry (see below). Should the second entry be deleted. How should I do this??

-rw-r--r-- 1 root root  864 Aug 25 05:56 bind-home.conf
-rw-r--r-- 1 root root  864 Aug 25 05:49 bind-home.conf~

When you see a file with a tilde at the end, that is just a backup copy.  You can keep or delete it -- it's up to you.  Sometimes the text editor may have it set under its preferences to save a backup copy of files that get edited.  Maybe either gedit or leafpad has that set right now (probably gedit).  You can disable that by just unchecking that preference.

Nothing wrong with installing gedit -- it's just another text editor with a few more features than leafpad.  You can keep and use both of them on the system -- they won't conflict with each other.

EDIT:  I just thought of something that I forgot to ask you before.  Did you have any Virtual Machines created in VirtualBox before you bound the "VirtualBox_VMs" folder to the DATA partition?  If you did, you won't be able to see those anymore.  They will still exist, but you won't be able to access them with the bind in effect.  I can give you instructions on how to find them and transfer them to the DATA partition if you run into that problem.  Let me know if you need to do that.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on August 27, 2014, 03:01:11 AM
Quote
EDIT:  I just thought of something that I forgot to ask you before.  Did you have any Virtual Machines created in VirtualBox before you bound the "VirtualBox_VMs" folder to the DATA partition?  If you did, you won't be able to see those anymore.  They will still exist, but you won't be able to access them with the bind in effect.  I can give you instructions on how to find them and transfer them to the DATA partition if you run into that problem.  Let me know if you need to do that.

I did have a couple of virtual machines before but I saved them both to  my external drive in their VirtualBox folder, before doing a clean install of the OSes, followed by binding to DATA partition.  By doing that I seem to have saved myself some extra work, judging from your above comment. 

Yes, I'm really pleased I've got this far with linux, being a complete newbie in April (from Win XP) and without any prior programming experience. I am getting into it, though have to admit I don't always understand what I'm doing, though with time everything will become clearer (as it already is), bit-by-bit. Many thanks for all your careful advice gold_finger, though suspect I'll be in touch again sometime...

Regards
Mike

Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on August 28, 2014, 11:56:36 AM
Alright then, you're all set.

Go ahead and mark the post as solved.  I think there might be a way to put green check mark on post to signify that it is solved, but don't know exactly where that would be.  If can't find that, go to very first post on the thread, click "Modify" button, then just add <SOLVED> to the Subject title.
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: m654321 on September 01, 2014, 10:05:04 AM
Gold_finger, just one small question before I hit the 'solve' button (I found the 'topic solved' button at the bottom of the last post on the LHS of the screenview :P) ...

My question...
When I boot  LL 2.0, in either a dual- or multi-boot system (all Linux based), it mounts the partition or partitions (e.g. '40 GB Volume' shown below an icon of the drive) for the other OS or OS-es on the top left-hand side of the desktop screen.  With the system I have, both Zorin OS and Elementary OS, do not do this. Is there something I can do to prevent these automounting on the screen?

Summarizing for the record...
The binding to a separate DATA partition worked really well for the dual boot system with LL2 and Zorin 9. Just for the record, I extended this to include the permissible maximum of four OSes on sda (i.e. I installed LL2.0, Zorin6, Zorin9 & Elementary (Luna) on sda - all Ubuntu based), and used sdb for the shared DATA partition and common Swap partition. When installing the different OSes one-by one, I used the 'something else' option at setup, to partition the drives. All the partitions were set up as 'logical partitions', though this probably doesn't matter as I did not exceed 4 partitions on either sda or sdb. 

Kind regards
Mike
Title: Re: Dual Booting LL 2.0 with other Ubuntu (14.04) based distros
Post by: gold_finger on September 01, 2014, 03:57:17 PM
When I boot  LL 2.0, in either a dual- or multi-boot system (all Linux based), it mounts the partition or partitions (e.g. '40 GB Volume' shown below an icon of the drive) for the other OS or OS-es on the top left-hand side of the desktop screen.  With the system I have, both Zorin OS and Elementary OS, do not do this. Is there something I can do to prevent these automounting on the screen?
I don't think the other partitions are actually being mounted.  You are probably just seeing icons for them placed on the desktop.  If you double-click the icons, then they will be mounted.  If you open the file manager and look along left-hand side you will see those partitions listed, but you should notice that they are slightly grayed out -- meaning they are not mounted.  If you click them, then they will be mounted.

If you don't want to see their icons on the desktop, just open Menu -> Settings Manager -> Desktop -> Icons (tab) and uncheck "Removable Devices".

(http://ibin.co/1YrtruYe3wUt)