Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
Grub downgraded after adding new OS
Grub downgraded after adding new OS
Hello,
I installed Kali Linux on my laptop which was already running Debian Wheezy and Win7.
Sadly Kali downgraded my Grub version to 1.99 from 2.0.
If i login to Wheezy the grub controls don't detect Kali.
If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
I installed Kali Linux on my laptop which was already running Debian Wheezy and Win7.
Sadly Kali downgraded my Grub version to 1.99 from 2.0.
If i login to Wheezy the grub controls don't detect Kali.
If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
Re: Grub downgraded after adding new OS
Can you explain how you are "detecting"? What grub controls? Explain what commands/tools you are using and how you are using them please.TheDonger wrote:If i login to Wheezy the grub controls don't detect Kali.
If i boot Kali it detects it all
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
Have you read http://docs.kali.org/introduction/shoul ... kali-linux ?
and post the result.
I wonder if "os-prober" cannot detect the linux distributions installed in a partition which is overly mounted by another partition.
In my debian wheezy, also it could not detect the debian installed on a partition, for example /dev/sda1, after
Boot debian and execute with root privilege:Is Kali Linux Right For You?
As the distribution developers, one would likely expect us to recommend that everyone use Kali Linux. The fact of the matter is however, that Kali is a Linux distribution specifically geared towards professional penetration testing and security auditing and as such, it is NOT a recommended distribution for those unfamiliar with Linux.
In addition, misuse of security tools within your network, particularly without permission, may cause irreparable damage and result in significant consequences.
If you are looking for a Linux distribution to learn the basics of Linux and need a good starting point, Kali Linux is not the ideal distribution for you. You may want to begin with Ubuntu or Debian instead.
Code: Select all
os-prober
df
for a in $(blkid|grep \ TYPE=\"ext|cut -d: -f1);do mount -t auto $a /mnt -o ro;if [ -e /mnt/boot ];then echo $a;ls /mnt/boot;umount -l /mnt;fi;done
I wonder if "os-prober" cannot detect the linux distributions installed in a partition which is overly mounted by another partition.
In my debian wheezy, also it could not detect the debian installed on a partition, for example /dev/sda1, after
Code: Select all
mount -t ext4 /dev/sda1 /mnt
mount -t ext4 /dev/sda2 /mnt
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
You are not stuck with the Kali grub. If you want the Debian grub back, then just login to Debian, open a terminal window, and:
Obviously, if your disk isn't sda, then you need to replace sda in the command above.
This will give you your Debian grub back. Whether it will detect and add a entry for Kali I don't know. Never tried Kali. But if not, it's better to add a manual entry for Kali....
Code: Select all
sudo grub-install /dev/sda
This will give you your Debian grub back. Whether it will detect and add a entry for Kali I don't know. Never tried Kali. But if not, it's better to add a manual entry for Kali....
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
"grub-install" does not invoke "update-grub" thus does not invoke "os-prober".
To the OP, TheDonger,
Have you executed "update-grub" on debian?
Do you know that debian wheezy uses grub2 version 1.99-27+deb7u2 now?
https://packages.debian.org/wheezy/grub-common
To the OP, TheDonger,
Have you executed "update-grub" on debian?
Do you know that debian wheezy uses grub2 version 1.99-27+deb7u2 now?
https://packages.debian.org/wheezy/grub-common
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
The question was if he had to stick with the Kali grub that currently handles the grub on his PC. The answer is NO, he can get his Debian grub back, by installing it as I described....
There is no point in running "update-grub" in his Debian install, before he has installed the Debian-grub. Which has been overwritten by the Kali-grub. So you see, he first has to do grub-install from his Debian-install, and then run "update-grub" if it isn't invoked by grub-install. But many times it is...
Anyway, to make sure, then just:
Happy?
There is no point in running "update-grub" in his Debian install, before he has installed the Debian-grub. Which has been overwritten by the Kali-grub. So you see, he first has to do grub-install from his Debian-install, and then run "update-grub" if it isn't invoked by grub-install. But many times it is...
Anyway, to make sure, then just:
Code: Select all
sudo grub-install /dev/sda && sudo update-grub
Re: Grub downgraded after adding new OS
If Kali detects it all, does it matter?TheDonger wrote:If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
+1.phenest wrote:If Kali detects it all, does it matter?TheDonger wrote:If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
Furthermore, on grub2 installed by kali linux, the OP can use the config file /boot/grub/grub.cfg in debian wheezy by a Grub2 command "configfile".
Furthermore, without installation of grub2 on debian wheezy, "update-grub" can include a menuentry in /boot/grub/grub.cfg.
Maybe the OP misunderstands something or ... I misunderstand what the OP wrote, possibly because of bad English communication of mine and the OP.
If the debian grub2 can not detect kali and if the kali grub2 can detect all the linux (kali and debian), why should the OP install debian grub2 onto the MBR? I cannot understand the reason.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
Perhaps because he intends to keep Debian, while Kali are just visiting his computer? It makes sense to use your main install as the "master-grub". Lot's of people are distro-hopping and multibooting, but they usually have one main OS/distro, and of course, they want that install to handle grub for all the others. Let's say that the OP get's tired of kali in a day or two, and removes it. Then he suddenly has a unbootable system, and then need to fire up Debian in live mode, to write grub to mbr.
So there are many reasons why someone wants a perticular install to handle the grub, but the most important one, is because he wants to. That's the linux way. We don't settle with whatever is the easiest solution in the moment, but we make it work like we want it to..., and really, nobody should have to defend themselves for wanting one solution instead of another. That kind of mentality doesn't belong in Linux. There are no right way, no best way. Just the way you want to do it.
So there are many reasons why someone wants a perticular install to handle the grub, but the most important one, is because he wants to. That's the linux way. We don't settle with whatever is the easiest solution in the moment, but we make it work like we want it to..., and really, nobody should have to defend themselves for wanting one solution instead of another. That kind of mentality doesn't belong in Linux. There are no right way, no best way. Just the way you want to do it.
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
Thank you for your nice guess!ew-linux wrote:Perhaps because he intends to keep Debian, while Kali are just visiting his computer?
(snip by kiyop)
Let's say that the OP get's tired of kali in a day or two, and removes it.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
Not a guess. I simply don't question why anyone wants to do something. But the odds of any unskilled user keeping Kali for a long period of time, are rather slim...kiyop wrote:Thank you for your nice guess!ew-linux wrote:Perhaps because he intends to keep Debian, while Kali are just visiting his computer?
(snip by kiyop)
Let's say that the OP get's tired of kali in a day or two, and removes it.
Re: Grub downgraded after adding new OS
Then you should. Knowing the reason will help provide the best solution. What if the OP doesn't want to remove Kali (they haven't mentioned it)? They may not realise that it's ok to leave it as it is. It can save a lot of frustration on the OP's part.ew-linux wrote:I simply don't question why anyone wants to do something.
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
I don't want to communicate with a person who is not logical.ew-linux wrote:Not a guess.kiyop wrote:Thank you for your nice guess!ew-linux wrote:Perhaps because he intends to keep Debian, while Kali are just visiting his computer?
(snip by kiyop)
Let's say that the OP get's tired of kali in a day or two, and removes it.
+1.phenest wrote:Then you should. Knowing the reason will help provide the best solution. What if the OP doesn't want to remove Kali (they haven't mentioned it)? They may not realise that it's ok to leave it as it is. It can save a lot of frustration on the OP's part.ew-linux wrote:I simply don't question why anyone wants to do something.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
make a backup first because there is no guarantee this will work without error.TheDonger wrote:Hello,
I installed Kali Linux on my laptop which was already running Debian Wheezy and Win7.
Sadly Kali downgraded my Grub version to 1.99 from 2.0.
If i login to Wheezy the grub controls don't detect Kali.
If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
boot debian
update grub
chroot into kali and purge grub
exit out of kali chroot
update grub again
reboot
with your fingers crossed and your backup ready
there are other ways
ie: liveCD - which you should also have ready along with a recent full backup,
fix the mbr manually - not recommended
In memory of Ian Ashley Murdock (1973 - 2015) founder of the Debian project.
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
Do not do the following, which llivv suggested in the former post of him/her:
If you dare to carry out the above, execute "grub-install /dev/sda" or so in order to install grub code onto the MBR of /dev/sda or so by debian, before rebooting debian.
I do not know if kali linux is so clever that purging grub restores the original debian grub2 code which had been installed onto the MBR before kali's grub code was installed, or not. I guess no.
There are many possibilities. As the OP has not given enough information, we should ask the OP to give more information.
Now it seems that he can boot kali linux and debian with grub(2) kali linux installed and that debian grub cannot detect kali linux, although the OP may misunderstand the situation. Thus, I think that it is better not to remove grub2 kali linux installed.
After grub2 of debian become able to detect kali linux and generate a menuentry for kali linux, the OP can safely install grub2 code on debian to take over the control of the boot process.
The above may result in the disaster ew-linux expected.llivv wrote:make a backup first because there is no guarantee this will work without error.
boot debian
update grub
chroot into kali and purge grub
exit out of kali chroot
update grub again
reboot
If you dare to carry out the above, execute "grub-install /dev/sda" or so in order to install grub code onto the MBR of /dev/sda or so by debian, before rebooting debian.
I do not know if kali linux is so clever that purging grub restores the original debian grub2 code which had been installed onto the MBR before kali's grub code was installed, or not. I guess no.
There are many possibilities. As the OP has not given enough information, we should ask the OP to give more information.
Now it seems that he can boot kali linux and debian with grub(2) kali linux installed and that debian grub cannot detect kali linux, although the OP may misunderstand the situation. Thus, I think that it is better not to remove grub2 kali linux installed.
After grub2 of debian become able to detect kali linux and generate a menuentry for kali linux, the OP can safely install grub2 code on debian to take over the control of the boot process.
Last edited by kiyop on 2014-04-15 11:57, edited 2 times in total.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
It would be nice if him/her replied. I disilike replying to thin air.kiyop wrote:Do not do the following, which llivv suggested in the former post of him/her:
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
Re: Grub downgraded after adding new OS
disaster?
if gurb doesn't detect kali
oh no! reinstall kali time.
I'd probably do that - reinstall kali - anyways, but not before Debians grub was working properly.
maybe the OP will learn how not to install two grubs to the mbr on the same system. A good lesson to learn.
imo anyways.
it is the mbr and not the gpt right? oh god.....
if gurb doesn't detect kali
oh no! reinstall kali time.
I'd probably do that - reinstall kali - anyways, but not before Debians grub was working properly.
maybe the OP will learn how not to install two grubs to the mbr on the same system. A good lesson to learn.
imo anyways.
it is the mbr and not the gpt right? oh god.....
In memory of Ian Ashley Murdock (1973 - 2015) founder of the Debian project.
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
It is not sure that the OP wants to reinstall (and/or uninstall) kali.llivv wrote:disaster?
if gurb doesn't detect kali
oh no! reinstall kali time.
I'd probably do that - reinstall kali - anyways, but not before Debians grub was working properly.
The kali may contain the OP's elaborate settings
Do not assume that the OP wants to do what you would want to do.
The OP just posted:
TheDonger wrote:Hello,
I installed Kali Linux on my laptop which was already running Debian Wheezy and Win7.
Sadly Kali downgraded my Grub version to 1.99 from 2.0.
If i login to Wheezy the grub controls don't detect Kali.
If i boot Kali it detects it all
Is there a way for me to go back to the Debian Wheezy Grub? Or am i stuck with the Kali Grub now?
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/
Re: Grub downgraded after adding new OS
reread : http://forums.debian.net/viewtopic.php? ... 03#p537401kiyop wrote: It is not sure that the OP wants to reinstall (and/or uninstall) kali.
The kali may contain the OP's elaborate settings
Do not assume that the OP wants to do what you would want to do.
where is the disaster?
In memory of Ian Ashley Murdock (1973 - 2015) founder of the Debian project.
- kiyop
- Posts: 3983
- Joined: 2011-05-05 15:16
- Location: Where persons without desire to improve themselves fear to tread, in Japan
- Been thanked: 3 times
Re: Grub downgraded after adding new OS
If kali's grub is removed, the grub code on the MBR cannot find the necessary files in /boot/grub directory of kali.
Then, the OP may be unable to boot OS. (I would be able to boot.)
Thus, the OP may reinstall kali, which may delete kali's setting.
Thus, as I mentioned, the OP need not remove grub of kali. The first thing to do is not to remove grub of kali, but to continue using grub of kali and found a good way to enable grub of debian to recognize kali.
Then, the OP may be unable to boot OS. (I would be able to boot.)
Thus, the OP may reinstall kali, which may delete kali's setting.
Thus, as I mentioned, the OP need not remove grub of kali. The first thing to do is not to remove grub of kali, but to continue using grub of kali and found a good way to enable grub of debian to recognize kali.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/
http://kiyoandkei.bbs.fc2.com/