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.
I have 2 linux Xubuntu 14.04 partitions
GRUB shows only one partition, i cannot switch user to the second partition too, but file manager sees it right.
Try running: sudo os-prober and watch the output for an entry for sda1 then run sudo update-grub. If that doesn't work, google bootinfoscript and go to the site and download and run it then post the output, a results.txt file here.
Now my goal is to login to bigger partition and re-install there grub since it`s installed using terminal in new partition
but i cannot do this because it can`t connect to the internet by sda1 in terminal
first install is ok, the problem is that i want to login to first install (dev/sda1) using terminal and re-install GRUB but cannot do this because internet does not work when i use terminal and login within.
Code:
root@kek-G41M-ES2L:/# apt-get install --reinstall grub-pc
Czytanie list pakietów... Gotowe
Budowanie drzewa zależności
Odczyt informacji o stanie... Gotowe
0 aktualizowanych, 0 nowo instalowanych, 1 ponownie instalowanych, 0 usuwanych i 75 nieaktualizowanych.
Konieczne pobranie 173 kB archiwów.
Po tej operacji zostanie dodatkowo użyte 0 B miejsca na dysku.
Błąd http://pl.archive.ubuntu.com/ubuntu/ trusty-updates/main grub-pc amd64 2.02~beta2-9ubuntu1
Nie udało się przetłumaczyć nazwy "pl.archive.ubuntu.com"
E: Nie udało się pobrać http://pl.archive.ubuntu.com/ubuntu/pool/main/g/grub2/grub-pc_2.02~beta2-9ubuntu1_amd64.deb Nie udało się przetłumaczyć nazwy "pl.archive.ubuntu.com"
E: Nie udało się pobrać niektórych archiwów, proszę spróbować uruchomić apt-get update lub użyć opcji --fix-missing.
You are able to boot the Xubuntu on sda6 but cannot boot the Xubuntu on sda1, correct? The reason you can't boot the system on sda1 is because you don't have any Grub files on that partition. Since both systems are Xubuntu 14.04, you can simplify the process by simply copying all the files from sda6 /boot/ to the /boot directory on sda1.
Once you have done that and while still booted into sda6, run: sudo update-grub and/or sudo os-prober
If you see output for sda1, reboot and you should see an option to boot sda1, select that and if it boots, open a terminal and run: sudo update-grub then since you want to use sda1, run: sudo grub-install /dev/sda while booted into the system on sda1.
This should work but it is not a standard method and would only work since you are running two identical systems.
I copied boot files and now GRUB shows two options
one is Xubuntu
and one is Xubuntu /dev/sda1
But both are starting the same profile so i guess i need to change /dev/sda1 mounting point since now it doesn`t has one and do something with `/` mounting point in /dev/sda6.
The first thing I would do, assuming you are able to boot the Xubuntu on sda6 and what you actually want is to use sda1, is to boot to sda6 which you can do, then create a mount point for sda1 then mount sda1:
Code:
sudo mkdir /mnt/sda1
Code:
sudo mount /dev/sda1 /mnt/sda1
Then just copy the files. I haven't tried this method and am not sure it will work but I can't see why not. Nothing to lose since you can't boot it. Your previous bootinfo output showed no grub files on sda1. When you mount sda1, verify this by checking the /boot and /boot/grub directories. Also, check to see if you have a kernel (vmlinuz) file and an initrd file in /boot on sda1. If they aren't there, you will need to copy the entire /boot directory from sda6 to sda1. Make sure you copy and don't use the move command.
Quote:
When i installed new partition it forced to boot on /
and moved old partition files to the /media/
I'm not sure what you are asking but when you installed Xubuntu to sda6 and you boot to sda6, it is shown as / (root). If you were to boot to sda1, it would show itself as / (root). You can see the xubuntu files on sda1 under /media/user while booted to sda6 but if you were able to boot xubuntu on sda1, the xubuntu files on sda6 would show under /media/user. So the files on sda1 are not "moved" to /media/user but are simply available there from sda6.
After booting the Xubuntu on sda6, you copied the /boot/grub files to sda1. Is that correct? Did you verify that there was a kernel (vmlinuz file) on sda1 as well as an initrd file there in the boot directory?
Quote:
I copied boot files and now GRUB shows two options
Did you run the sudo update-grub from sda6? So you now have two entries and one of them is for sda6 and the other is for sda1, is that correct?
When you select the entry for sda1, can you boot it?
I'm not sure why you are doing that. Those are both mount points. You can access sda1 under the /media directory as shown above OR you could mount it as /mnt/sda1, don't do both. If you want to manually mount you would need the device name as below:
Code:
sudo mount /dev/sda1 /mnt/sda1
Did your Xubuntu on sda1 ever work after installing? If not, you might find it simpler to reinstall it and leave the default to install the bootloader to the master boot record; /dev/sda.
You could also simply reinstall Grub to sda1 but if you do not have a kernel and initrd, that won't help.
The Grub files are also in /usr/lib/grub/i386-pc on Xubuntu on either install and you could probably use the chroot method suggested above to install Grub on sda1 and then run sudo update-grub. Using the chroot method is a little more complicated and is explained at the link below:
Yes files in /dev/sda1 boot folder are the same like in /dev/sda6 and i did update GRUB.
I have two options in GRUB but whatever i choose it loads ``kek`` profile which is /dev/sda6
This is the full story:
/dev/sda1 was my only system partition which i used at usually and everything was working fine
next day i turned on my computer and GRUB doesn`t loaded, it was showing
Code:
/boot/grub/i386-pc/normal. mod not found
So i putted pendrive with Xubuntu distribution and in UNetbootin there wasn`t option to install only GRUB so i decided to divide one big partition and create small as possible for second Xubuntu because i needed to install GRUB with it.
And after it i was only able to boot new /dev/sda6 partition and it looks like it simply changed mounting point as seen in GParted.
Would changing /dev/sda1 to mounting point `/` and /dev/sda6 to another solve problem?
Open the file manager and go to: /media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a
Look in the /boot directory and verify that you have a grub directory. Also check to see if the other grub files are there. You show the links to the vmlinux and initrd files in the root of sda1 so verify that these files are under the /boot directory here. Also, verify that the normal.mod file is there, probably under /boot/grub/i386-pc directory.
If the files are there run from your bootable Xubuntu on sda6: sudo os-prober - watch the output then run: sudo update-grub - again, watch the output. You should see an entry for sda1 if all the correct files have been verified to be on sda1. After doing this, re-boot the computer and look for an entry for sda1. If the update-grub added an sda1 entry, it should be there and boot.
I don't know what happened to your normal.mod file but it won't boot without it.
Quote:
Would changing /dev/sda1 to mounting point `/` and /dev/sda6 to another solve problem?
I already did that and checked files before and one GRUB option is Xubuntu, second is Xubuntu /dev/sda/1.
Both are loading the same (new) profile
Code:
kek@kek-G41M-ES2L:~$ sudo os-prober
[sudo] password for kek:
/dev/sda1:Ubuntu 14.04.1 LTS (14.04):Ubuntu:linux
kek@kek-G41M-ES2L:~$ sudo update-grub
Generating grub configuration file ...
Znaleziono obraz Linuksa: /boot/vmlinuz-3.13.0-32-generic
Znaleziono obraz initrd: /boot/initrd.img-3.13.0-32-generic
Found memtest86+ image: /boot/memtest86+.elf
Found memtest86+ image: /boot/memtest86+.bin
Znaleziono Ubuntu 14.04.1 LTS (14.04) na /dev/sda1
gotowe
so that`s why i was thinking about changing mount point
The os-prober output in your last post shows an entry for sda1 is detected. What happens when you move the arrow key down to that entry on the boot menu to select and hit Enter? Does it boot? So you have checked sda1 and you have the /boot/grub and i386-pc directories with the vmlinuz and initrd files, correct. Is there a normal.mod file in i386-pc?
Quote:
Both are loading the same (new) profile
Does that mean when you select sda1 you are still on sda6? Then boot sda6 and go to the /boot/grub directory of sda1;
/media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a and delete the grub.cfg file there then do chroot as shown below. F
first from a terminal run: df -h to see if /media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a is mounted. If it is, unmount it and run:
Code:
for i in /dev /dev/pts /proc /sys /run; do sudo mount -B $i //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a$i; done
Hit the Enter key and Make sure you have deleted the grub.cfg file then run: sudo update-grub
The standard method of reinstalling grub, specifically for your partition is below. This installs Grub to the master boot record pointing to the Grub files on sda1. If you are missing a vmlinuz or initrd file it won't work. The problem with this is that if it fails, your machine is un-bootable. If you still have the installation medium you can re-install to sda6 with a similar command by replacing the UUID below for sda with the correct UUID for sda6:
kek@kek-G41M-ES2L:~$ for i in /dev /dev/pts /proc /sys /run; do sudo mount -B $i //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a$i; done
[sudo] password for kek:
mount: punkt montowania //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a/dev nie istnieje
mount: punkt montowania //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a/dev/pts nie istnieje
mount: punkt montowania //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a/proc nie istnieje
mount: punkt montowania //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a/sys nie istnieje
mount: punkt montowania //media/kek/90f4d874-9e8d-44f1-92a1-1db889e0476a/run nie istnieje
``nie istnieje`` means ``doesn`t exist``
so i dont know if im ready to do next steps
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.