Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
make install error no space left on device
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Baillis_The_Cremey
n00b
n00b


Joined: 05 Dec 2017
Posts: 13

PostPosted: Mon Dec 11, 2017 5:48 am    Post subject: make install error no space left on device Reply with quote

I was having some issues with my modules exporting symbols already owned by the kernel so I checked uname and realized that I was running an old kernel rather than the one I had just rebuilt. I realized I had forgotten to mount /boot. After mounting it:
Code:

# make install
sh ./arch/x86/boot/install.sh 4.12.12-gentoo arch/x86/boot/bzImage \
   System.map "/boot"
cat: write error: No space left on device
make[1]: *** [arch/x86/boot/Makefile:191: install] Error 1
make: *** [arch/x86/Makefile:290: install] Error 2


Code:

# df -i
Filesystem       Inodes  IUsed    IFree IUse% Mounted on
/dev/sda4      61014016 510833 60503183    1% /
devtmpfs        1007582    434  1007148    1% /dev
tmpfs           1007979    535  1007444    1% /run
shm             1007979      3  1007976    1% /dev/shm
cgroup_root     1007979      8  1007971    1% /sys/fs/cgroup
none            1007979      6  1007973    1% /run/user/1000
/dev/sda1           256     14      242    6% /boot
/dev/sda2             0      0        0     - /boot/EFI


It appears that I have plenty of inodes free. I know my boot areas are kind of weird but I've been booting fine for a while and updating my kernel has seemed to be working for some time. Nothing of importance seems to be showing up in dmesg, other than
Code:
[ 2411.266520] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)
from when I mounted /boot, I'm guessing.

The issue is the actual space on the discs. When I created the partitions, I expected the kernel to go to the /boot/EFI partition which /dev/sda2 is mounted on. The gentoo handbook seemed to recommend jusst a small amount of space for the grub bootloader to latch onto at the beginning of the drive. Looking around the internet afterwards, the general consensus seemed to be that the gentoo handbook was sort of off for UEFI systems, and that only one boot partition was needed; by the time I found this out I had already gotten my computer to boot and been using it for a month or two.
According to df -i and df -h, I have plenty of space on /boot/EFI but no inodes, and no space but plenty of inodes on /boot.
Code:

# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda4       916G   39G  831G   5% /
devtmpfs         10M     0   10M   0% /dev
tmpfs           788M  1.2M  787M   1% /run
shm             3.9G  4.0K  3.9G   1% /dev/shm
cgroup_root      10M     0   10M   0% /sys/fs/cgroup
none            3.9G     0  3.9G   0% /run/user/1000
/dev/sda1       987K  944K  3.0K 100% /boot
/dev/sda2       127M   24M  103M  19% /boot/EFI


How can I fix this? What can i safely delete?
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5959

PostPosted: Mon Dec 11, 2017 5:52 am    Post subject: Reply with quote

That sda1 filesystem is far too tiny to be usable as /boot/. You'll have to delete and repartition sda1 and sda2 into saner proportions, or just stop using a separate partition for /boot/ entirely and put everything in /boot/EFI/.
Back to top
View user's profile Send private message
Baillis_The_Cremey
n00b
n00b


Joined: 05 Dec 2017
Posts: 13

PostPosted: Mon Dec 11, 2017 5:10 pm    Post subject: Reply with quote

Ant P. wrote:
That sda1 filesystem is far too tiny to be usable as /boot/. You'll have to delete and repartition sda1 and sda2 into saner proportions, or just stop using a separate partition for /boot/ entirely and put everything in /boot/EFI/.


Yeah I was definitely thinking that I might have to do that at some point. But when looking in my filesystem, I found that when unmounted, /boot/EFI contains just a bzImage file, but when mounted it is empty. When I mount the /boot/EFI directory, it has in it another copy of what is inside the mounted /boot directory, but with the older versions of the kernel where the /boot directory contains the one I want to be running. I will try to make a tree of my boot partition:

Code:
/boot/--EFI--EFI--grub--grubx64.efi
      |    |
      |    |-grub--[bunch of grub stuff like fonts and themes]
      |    |
      |    |-config-4.12.12-gentoo
      |    |
      |    |-System.map-4.12.12-gentoo
      |    |
      |    |--vmlinuz-4.12.12-gentoo <- the one I'm running
      |
      |-grub
      |
      |-vmlinuz-4.12.12-gentoo <- the new one I want to be running


Could you give me an example of what this is supposed to look like? Is there any point in having things in these directories while they are unmounted? Can I delete everything in the unmounted /boot/EFI and /boot?
Back to top
View user's profile Send private message
Baillis_The_Cremey
n00b
n00b


Joined: 05 Dec 2017
Posts: 13

PostPosted: Mon Dec 11, 2017 6:25 pm    Post subject: Reply with quote

Because of the folder structure, I tried mounting the partition that I normally mount to /boot/EFI to /boot, and then did
Code:
make install
. It installed properly and now I am booting fine. I edited my fstab to reflect this, and now I get a error on startup that says "wrong file system" or something like that. I'm wondering if maybe that is a good thing and that I do need the ext4 partition on the beginning of the disk for grub. Here is my fstab:
Code:

/dev/sda2               /boot           vfat            rw,default,noatime      1 2
/dev/sda3               none            swap            sw                      0 0
/dev/sda4               /               ext4            rw,noatime              0 1


and (parted) print shows:
Code:

Number  Start   End     Size    File system     Name  Flags
 1      1049kB  3146kB  2097kB  ext4            grub  bios_grub
 2      3146kB  137MB   134MB   fat32           boot  boot, esp
 3      137MB   674MB   537MB   linux-swap(v1)  swap
 4      674MB   1000GB  1000GB  ext4            root


What should be in my fstab file to reflect this? do I really need the /dev/sda1 partition? How would I safely expand the /dev/sda2 partition into the /dev/sda1 partition if I wanted to?
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5959

PostPosted: Mon Dec 11, 2017 8:58 pm    Post subject: Reply with quote

You're booting from UEFI, so you definitely don't need that bios_grub partition. Might be a good idea to delete it to avoid confusion but it's not necessary.

Also since you're using UEFI it'd be a good idea to use PARTLABEL= or PARTUUID= in /etc/fstab instead of raw device names. Run blkid and it should tell you what to use.
Back to top
View user's profile Send private message
Baillis_The_Cremey
n00b
n00b


Joined: 05 Dec 2017
Posts: 13

PostPosted: Mon Dec 11, 2017 11:36 pm    Post subject: Reply with quote

Ant P. wrote:
You're booting from UEFI, so you definitely don't need that bios_grub partition. Might be a good idea to delete it to avoid confusion but it's not necessary.

Also since you're using UEFI it'd be a good idea to use PARTLABEL= or PARTUUID= in /etc/fstab instead of raw device names. Run blkid and it should tell you what to use.


Do I have to move anything out of harm's way before removing the first partition? Also do you have any idea what the "wrong file system" error is? Is it just because the bios_grub partition? I assumed that the file system "belongs to" the disk, not the directory, and that I could change the place a disk mounts to without regard to the file system.
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5959

PostPosted: Tue Dec 12, 2017 1:50 am    Post subject: Reply with quote

If you want to be sure nothing's going to break, delete /dev/sda1 first then re-run the EFI grub installer command.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum