LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-24-2019, 10:21 AM   #1
Sharvin26
LQ Newbie
 
Registered: Feb 2019
Posts: 21

Rep: Reputation: Disabled
Debian os booting issue ( u-boot configuration )


I have 3 partitions (mmcblk0p1, mmcblk0p2, mmcblk0p3) on a disk.( mmcblk0 )
I am using uBoot as a bootloader.
I have 2 same variants of Debian 9 operating system image flashed on 2 partitions ( mmcblk0p2, mmcblk0p3)
Partition 1 ( mmcblk0p1 ) is the partition Where I am storing uEnv.txt ( For deciding which partition to boot from )
I am unable to boot from the Partition 3 (mmcblk0p3) When I give root=mmcblk0p3 and other configs in the uEnv.txt. It is booting from the mmcblk0p2 ( According to my understanding it should boot from mmcblk0p2).
To find out if I was doing right I configured 2 partitions only ( mmcblk0p1, mmcblk0p2 ) both with the Debian 9 OS image. When I configured the 1st Partition ( mmcblk0p1 ) to root=mmcblk0p2 and other configs in the uEnv.txt. I was able to boot to the 2nd partition (mmcblk0p2).
I am confused Why it's not booting to the partition I give when I have 3 partitions?
But works perfectly fine when I have 2 partitions and boots to whichever the partition I give.
Can anyone help me? I'm a pretty newbie to uboot and Linux ( Debian )
 
Old 02-24-2019, 08:02 PM   #2
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
According to the configuration page, you should have: root=/dev/mmcblk0p3
 
Old 02-24-2019, 08:20 PM   #3
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
Also, the /boot/grub.cfg file in each OS is likely to be configured to boot a partition based on it's UUID. I'm guessing the two OSs are from the same image file you extracted yesterday from the disk image, so...each partition has the same UUID, as such, grub will be unpredictable.
You can make it predictable by editing /etc/default/grub in both OSs to disable the use of UUID which will have grub looking for /dev/mmcblk0p2 or /dev/mmcblk0p3. By simply editing the line in the example below to remove the hash (#) at the beginning of the line. If that line don't exist in your /etc/default/grub, paste it in there. After you edit this file you need to issue command as root or sudo: update-grub. Then boot into the other OS and edit it's /etc/default/grub file the same way and issue the update-grub command again.
Code:
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
 
Old 02-24-2019, 11:18 PM   #4
Sharvin26
LQ Newbie
 
Registered: Feb 2019
Posts: 21

Original Poster
Rep: Reputation: Disabled
Debian os booting issue ( u-boot configuration )

Thank you for the response Brains

Quote:
Originally Posted by Brains View Post
According to the configuration page, you should have: root=/dev/mmcblk0p3
Sorry for that was a typing mistake in the above post. I have already configured by adding root=/dev/mmcblk0p3 in my uEnv.txt

Yes the two OSs are from the same image file ( But it is going to change in the future. One OS can be from a different image than the other one. )

I am not using grub. I am using uboot as a bootloader. ( Will the configuration be same for both as you told above?)

I couldn't find any uboot configuration under /etc/default. In my case, there is a uEnv.txt under /boot and as explained in the previous question if I have 2 partitions and I configured uEnv.txt to boot the second partition it's working.

But this is failing when I have 3 configurations as explained in the above Question.
 
Old 02-24-2019, 11:38 PM   #5
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
Quote:
Originally Posted by Sharvin26 View Post
( Will the configuration be same for both as you told above?)
Not sure, I've never dabbled with uBoot loader, I just added some information as it might be relevant. If you were to use Grub2 as the boot loader, then you would have to configure Grub to look for device rather than UUID when there are multiple matching partition UUIDs.
 
Old 02-24-2019, 11:49 PM   #6
Sharvin26
LQ Newbie
 
Registered: Feb 2019
Posts: 21

Original Poster
Rep: Reputation: Disabled
Okay got the solution needed some more configuration files in the partition to add for it to set the boot priority.
Thanks for the response.
 
  


Reply

Tags
boot, bootloader, debian, partitions, uboot



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Equivalent files in Arch configuration of services to Debian configuration... Alexvader Debian 2 10-17-2011 07:44 AM
dual boot system booting in Redhat linux but not booting in Windows XP sumitra Linux - Newbie 3 03-24-2011 09:42 AM
/boot/boot/boot/boot/boot/ muddywaters SUSE / openSUSE 1 09-10-2005 06:08 AM
booting new kernel. Booting new kernel dies with INIT: VFS issue, really mus335 Linux - General 0 04-21-2004 11:52 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration