Install grub to MBR, NO config files in linux distro partition
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Install grub to MBR, NO config files in linux distro partition
After going through the install wiki and doing it like it said, I thought I was installing grub to my MBR. Now I have found out some of grub's files are located on my Arch / partition. Im wondering if there is a way to have all my grub files stored on my MBR.
It seems like all the google searches for install grub to MBR return the same thing, some grub files to MBR but then still the grub conf files in your /boot/.... of linux install.
What I would like is:
All grub files to MBR
os-prober to MBR
Able to have all partition erased on disk and still boot to grub
able to issue mkconfig command and point it to proper location - MBR - to create grub.conf file.
So say I have grub installed to MBR, totally empty paritions, then install arch linux, I dont install a bootloader with it, then I restart and get into grub. I use grub terminal to boot into my arch. Then from arch I will issue a mkconfig command and use os-prober to automatically write my grub.conf file (which should be in my mbr partition, not in /boot/......)
I understand grub cannot write from its own terminal, only read...otherwise I would say to just run mkconfig command straight from grub boot menu....but i dont think that will be possible.
Im not sure if this is really unusual, not possible, or will cause many problems, your thoughts/ideas and help is appreciated.
Im wondering if there is a way to have all my grub files stored on my MBR.
No. In general terms, the mbr is 512 bytes in size. On the systems I am currently using, the grub directory ranges in size from 330kb to 4MB. So almost all of the grub files are on your system or boot partition.
I think what you actually want is a separate boot or grub partition which can be easily done. There are a number of tutorials on this so doing an online search should turn up a number of results. Make sure you use a tutorial for the correct Grub.
on my last Arch install i used a 100 Meg /boot partition to install grub into
------------
"/boot" -- 100meg to 1gig ( RHEL6 only needs 100 meg , but fedora needed 1 gig - preupgrade)
"/" -- 12 to 18 gig
"/home" -- BIG - say 25 gig to 100 gig
EXTENDED
/DATA -- the rest of the drive or a second drive
------------
on my last Arch install i used a 100 Meg /boot partition to install grub into
yea, that's the usual, frequently recommended procedure. 100M may be scarce if you'd like to keep multiple kernels.
But yancek mentioned to use a separate GRUB partition. Is that the same? Did he just phrase it inaccurately?
Quote:
Originally Posted by John VV
"/home" -- BIG - say 25 gig to 100 gig
EXTENDED
/DATA -- the rest of the drive or a second drive
Usually, the /home partition is relatively small on my systems. Either I leave /home inside the root file system, or I allow for a separate partition of about 2..4GB. After all, in my typical use, /home just holds the user-specific configuration data. A mess. I hardly ever care to look there.
The actual everyday working data ends up in /data, which takes the remaining available space as you suggested.
But yancek mentioned to use a separate GRUB partition. Is that the same? Did he just phrase it inaccurately?
Post #2 at the link below by 'Herman' mentions it. There is a link to a post written by Steve Litt on creating a separate Grub paartition also, second link below. Both are in regard to Grub Legacy but there is no reason I can think of why it would not work with Grub2 with appropriate modifications. It would be a lot simpler to create a separate boot partition.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.