Linux boot文件损坏

本文最后更新于:2021-04-05

人作死,就会死

本来只是想加一块硬盘,但是关机之前 pacman -Syu,而且不小心强制关机,以及不清楚操作了什么,boot文件似乎坏掉了…

2020/07/29 更新
前两天设置BIOS的时候,发现有点问题
F10无法保存BIOS更改,按一下界面就冻住了,只能强制关机
开机再进BIOS,又回到原来的设置
网上说是主板上的电池没电,今天买了个CMOS用的纽扣电池,换上去还真好了
祸不单行

开机进入grub命令行

开机直接进入一个

1
grub >    

这样的命令行
上面有一块文字 “grub2 is …”
还提示 Tab 列出所有命令

一脸懵,超出我的技术水平了….

尝试修理

查一下,英文的找了几篇,没找到比较好用的,可能是关键词不对
中文找到一个 zhihu - manjaro+win10双系统修复grub的艰辛过程
照着试试

ls (hd0,msdos1)/ 还能看到根目录下的文件,主目录的文件也都在
放了一半心,至少数据都在

看起来只是grub坏了,按照教程试着修复

  • 第一种方法不成功,最后输入normal没有反应,输入boot提示需要指定核心之类的,去网上找教程,指定一下参数还是启动不了
  • 第二种方法也不成功,报教程里说的 error: cannot find a device for /boot (is /dev mounted?). 错误,教程给出的方法不管用
    去网上找,Trying to reinstall GRUB 2, cannot find a device for /boot (is /dev mounted?) 额外挂载了sys``dev``proc目录,但还是不能安装grub,又有其他错误(但是我忘记是什么错误提示了,没有记下来

弃疗

总之,尝试了一晚上加半个上午,菜鸡放弃修复grub,重装系统了事
(主力电脑不能开机,笔记本又是新系统,翻墙软件都还没装,拿bing查资料修grub,太难了,后面想办法给笔记本上了梯子
((本来想写一写详细的失败过程,但是拖延症发作,写的时候发现细节差不多忘光了


2020/08/03 更新

突然找到一个文件,自己都忘记了
当时用live manjaro尝试修理的时候,把命令行输出全部复制下来了,虽然不知道有没有用
贴上来,说不定以后就能发现是哪里出问题了
(应该不是什么难题吧,可是我现在太菜了,不会修

参考的两个教程

Trying to reinstall GRUB 2, cannot find a device for /boot (is /dev mounted?)
grub-install: error: cannot find EFI directory. (Reinstalling Grub Boot Loader Windows 10/Kali Linux Dual Boot with Dual Hard Drive)

bash shell

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
 [[email protected] ~]$ manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
--> mount: [/mnt/mnt/Avalon/]
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# ls /home/mori/
Avalon Documents Music Pictures Softwares Videos gdindex.js goindex.js package-lock.json
Desktop Downloads Penguin Public Templates dependencies.md go my_anime_list.md 'to buy.md'
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# ls /boot/grub/
fonts grub.cfg grubenv themes x86_64-efi
[[email protected] /]# ls /boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
[[email protected] /]# mount /dev/nvme0n1p2 /mnt
[[email protected] /]# mount /dev/nvme0n1p1 /mnt
[[email protected] /]# cd /mnt
[[email protected] mnt]# ls
EFI
[[email protected] mnt]# chroot /mnt
chroot: failed to run command '/bin/sh': No such file or directory
[[email protected] mnt]# chr
chroot chrt
[[email protected] mnt]# chroot /mnt
chroot: failed to run command '/bin/sh': No such file or directory
[[email protected] mnt]# ls /bin/sh
/bin/sh
[[email protected] mnt]# chroot --help
Usage: chroot [OPTION] NEWROOT [COMMAND [ARG]...]
or: chroot OPTION
Run COMMAND with root directory set to NEWROOT.

--groups=G_LIST specify supplementary groups as g1,g2,..,gN
--userspec=USER:GROUP specify user and group (ID or name) to use
--skip-chdir do not change working directory to '/'
--help display this help and exit
--version output version information and exit

If no command is given, run '"$SHELL" -i' (default: '/bin/sh -i').

GNU coreutils online help: <https://www.gnu.org/software/coreutils/>
Report any translation bugs to <https://translationproject.org/team/>
Full documentation <https://www.gnu.org/software/coreutils/chroot>
or available locally via: info '(coreutils) chroot invocation'
[[email protected] mnt]# [wd
bash: [wd: command not found
[[email protected] mnt]# pwd
/mnt
[[email protected] mnt]# ls
EFI
[[email protected] mnt]# sudo chroot /mnt
chroot: failed to run command '/bin/bash': No such file or directory
[[email protected] mnt]# ls /bin/*sh
/bin/alsa-info.sh /bin/ceph-crash /bin/lav2avi.sh /bin/ppmflash /bin/toolstash
/bin/alsabat-test.sh /bin/chsh /bin/lavtc.sh /bin/rescan-scsi-bus.sh /bin/uim-sh
/bin/anytovcd.sh /bin/clash /bin/ldns-nsec3-hash /bin/rsh /bin/unix-lpr.sh
/bin/avahi-publish /bin/cpufreq-bench_plot.sh /bin/lprsetup.sh /bin/sh /bin/virsh
/bin/bash /bin/findssl.sh /bin/mbedtls_crypt_and_hash /bin/slsh /bin/winpr-hash
/bin/bssh /bin/gettext.sh /bin/mbedtls_udp_proxy_wrapper.sh /bin/spirv-lesspipe.sh /bin/wiper.sh
/bin/c_rehash /bin/gvmap.sh /bin/nettle-hash /bin/ssh /bin/zsh
/bin/capsh /bin/jemalloc.sh /bin/pax11publish /bin/tclsh
[[email protected] mnt]# ls /bin/bash
/bin/bash
[[email protected] mnt]# ls -al /bin/bash
-rwxr-xr-x 1 root root 928016 Jul 11 00:57 /bin/bash
[[email protected] mnt]# ls
EFI
[[email protected] mnt]# tail /var/log/pacman.log
[2020-07-22T19:40:45+0800] [ALPM-SCRIPTLET] -> at next boot.
[2020-07-22T19:40:45+0800] [ALPM-SCRIPTLET]
[2020-07-22T19:40:45+0800] [ALPM-SCRIPTLET]
[2020-07-22T19:40:45+0800] [ALPM] running 'texinfo-install.hook'...
[2020-07-22T19:40:45+0800] [ALPM] running 'thunderbird-post.hook'...
[2020-07-22T19:40:45+0800] [ALPM] running 'update-ca-trust.hook'...
[2020-07-22T19:40:46+0800] [ALPM] running 'update-desktop-database.hook'...
[2020-07-22T19:40:46+0800] [ALPM] running 'update-mime-database.hook'...
[2020-07-22T19:40:46+0800] [ALPM] running 'update-vlc-plugin-cache.hook'...
[2020-07-22T19:40:47+0800] [ALPM] running 'xorg-mkfontscale.hook'...
[[email protected] mnt]# ls -lh /var/log/pacman.log
-rw-r--r-- 1 root root 406K Jul 22 19:40 /var/log/pacman.log
[[email protected] mnt]# vi /var/log/pacman.log
[[email protected] mnt]# cat /var/log/pacman.log | grep -i bash
[2020-03-02T11:39:34+0800] [ALPM] upgraded bashrc-manjaro (5.0.011-2 -> 5.0.016-1)
[2020-03-02T11:39:34+0800] [ALPM] upgraded bash (5.0.011-2 -> 5.0.016-1)
[2020-03-02T11:39:39+0800] [ALPM] upgraded bash-completion (2.9-1 -> 2.10-1)
[2020-06-08T21:15:40+0800] [ALPM] upgraded bashrc-manjaro (5.0.016-1 -> 5.0.017-1)
[2020-06-08T21:15:40+0800] [ALPM] upgraded bash (5.0.016-1 -> 5.0.017-1)
[2020-06-08T21:15:43+0800] [ALPM] upgraded bash-completion (2.10-1 -> 2.10-2)
[2020-07-22T19:39:17+0800] [ALPM] upgraded bashrc-manjaro (5.0.017-1 -> 5.0.018-1)
[2020-07-22T19:39:17+0800] [ALPM] upgraded bash (5.0.017-1 -> 5.0.018-1)
[[email protected] mnt]# cd /
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# fsck
fsck from util-linux 2.35.2
e2fsck 1.45.6 (20-Mar-2020)
/dev/nvme0n1p2 is mounted.
e2fsck: Cannot continue, aborting.


[[email protected] /]# umount /dev/nvme0np1
umount: /dev/nvme0np1: no mount point specified.
[[email protected] /]# pwd
/
[[email protected] /]# mount
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
/dev/nvme0n1p1 on /boot/efi type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/sda1 on /root type ext4 (rw,relatime)
/dev/sdb1 on /mnt/Penguin type ext4 (rw,relatime,stripe=8191)
/dev/sdc2 on /mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] /]# umount
umount umount.ecryptfs umount.ecryptfs_private umount.nfs umount.nfs4 umount.udisks2
[[email protected] /]# umount /dev/nvme0n1p1
[[email protected] /]# umount /dev/nvme0n1p2
[[email protected] /]# mount
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
/dev/nvme0n1p1 on /boot/efi type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/sda1 on /root type ext4 (rw,relatime)
/dev/sdb1 on /mnt/Penguin type ext4 (rw,relatime,stripe=8191)
/dev/sdc2 on /mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
[[email protected] /]# fsck
fsck from util-linux 2.35.2
e2fsck 1.45.6 (20-Mar-2020)
/dev/nvme0n1p2 is mounted.
e2fsck: Cannot continue, aborting.


[[email protected] /]# cd
[[email protected] ~]# ls
Desktop Documents Downloads Music Pictures Public Templates Videos lost+found timeshift
[[email protected] ~]# pwd
/root
[[email protected] ~]# ls Videos/
[[email protected] ~]# ll
bash: ll: command not found
[[email protected] ~]# ls -;
ls: cannot access '-': No such file or directory
[[email protected] ~]# ls -l
total 52
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Desktop
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Documents
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Downloads
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Music
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Pictures
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Public
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Templates
drwxr-xr-x 2 root root 4096 Mar 3 22:14 Videos
drwx------ 2 root root 16384 Mar 3 09:46 lost+found
drwxr-xr-x 9 root root 4096 Jul 22 14:03 timeshift
[[email protected] ~]# manjaro-chroor --help
bash: manjaro-chroor: command not found
[[email protected] ~]# exit
--> umount: [/mnt/mnt/Avalon/]
--> umount: [/mnt/mnt/Penguin]
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
--> umount: [/mnt]
[[email protected] ~]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/sdd1 on /run/miso/bootmnt type iso9660 (ro,relatime,nojoliet,check=s,map=n,blocksize=2048,iocharset=default)
cowspace on /run/miso/cowspace type tmpfs (rw,relatime,size=262144k,mode=755)
overlay_root on /run/miso/overlay_root type tmpfs (rw,relatime,size=37024496k,mode=755)
/dev/loop0 on /run/miso/sfs/livefs type squashfs (ro,relatime)
/dev/loop1 on /run/miso/sfs/mhwdfs type squashfs (ro,relatime)
/dev/loop2 on /run/miso/sfs/desktopfs type squashfs (ro,relatime)
/dev/loop3 on /run/miso/sfs/rootfs type squashfs (ro,relatime)
overlay on / type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup2 on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=29,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=2428)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/nvme0n1p2 on /run/media/manjaro/798f587b-983a-478e-aca8-60524844eaa2 type ext4 (rw,nosuid,nodev,relatime,uhelper=udisks2)
[[email protected] ~]$ umount /dev/nvme0n1p1
umount: /dev/nvme0n1p1: must be superuser to unmount.
[[email protected] ~]$ sudo umount /dev/nvme0n1p1
umount: /dev/nvme0n1p1: not mounted.
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
[[email protected] ~]$ fsck /dev/nvme0n1p2
fsck from util-linux 2.35.1
e2fsck 1.45.6 (20-Mar-2020)
fsck.ext2: Permission denied while trying to open /dev/nvme0n1p2
You must have r/w access to the filesystem or be root
[[email protected] ~]$ cd /dev/nvme0n1p2
bash: cd: /dev/nvme0n1p2: Not a directory
[[email protected] ~]$ fsck --help

Usage:
fsck [options] -- [fs-options] [<filesystem> ...]

Check and repair a Linux filesystem.

Options:
-A check all filesystems
-C [<fd>] display progress bar; file descriptor is for GUIs
-l lock the device to guarantee exclusive access
-M do not check mounted filesystems
-N do not execute, just show what would be done
-P check filesystems in parallel, including root
-R skip root filesystem; useful only with '-A'
-r [<fd>] report statistics for each device checked;
file descriptor is for GUIs
-s serialize the checking operations
-T do not show the title on startup
-t <type> specify filesystem types to be checked;
<type> is allowed to be a comma-separated list
-V explain what is being done

-?, --help display this help
--version display version

See the specific fsck.* commands for available fs-options.
For more details see fsck(8).
[[email protected] ~]$ sudo fsck /dev/nvme0n1p2
fsck from util-linux 2.35.1
e2fsck 1.45.6 (20-Mar-2020)
/dev/nvme0n1p2: clean, 724071/31244288 files, 93382485/124949570 blocks
[[email protected] ~]$ sudo fsck /dev/nvme0n1p1
fsck from util-linux 2.35.1
fsck.fat 4.1 (2017-01-24)
/dev/nvme0n1p1: 6 files, 70/76646 clusters
[[email protected] ~]$ sudo fsck /dev/nvme0n1p1
fsck from util-linux 2.35.1
fsck.fat 4.1 (2017-01-24)
/dev/nvme0n1p1: 6 files, 70/76646 clusters
[[email protected] ~]$ sudo fsck /dev/nvme0n1p2
fsck from util-linux 2.35.1
e2fsck 1.45.6 (20-Mar-2020)
/dev/nvme0n1p2: clean, 724071/31244288 files, 93382485/124949570 blocks
[[email protected] ~]$ man fsck
[[email protected] ~]$ manjaro-chroot
==> ERROR: Can't create chroot on non-directory
[[email protected] ~]$ manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
--> mount: [/mnt/mnt/Avalon/]
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# ^C
[[email protected] /]# exit
--> umount: [/mnt/mnt/Avalon/]
--> umount: [/mnt/mnt/Penguin]
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
--> umount: [/mnt]
[[email protected] ~]$ sudo manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
--> mount: [/mnt/mnt/Avalon/]
[[email protected] /]# mount /dev/nvme0n1p
nvme0n1p1 nvme0n1p2
[[email protected] /]# mount /dev/nvme0n1p2 /mnt
[[email protected] /]# mount /dev/nvme0n1p1^Cmnt
[[email protected] /]# ls /mnt/
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# mount /dev/nvme0n1p1 /mnt/boot
[[email protected] /]# cd /mnt/
[[email protected] mnt]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] mnt]# chroot /mnt
sh-5.0# grub-install /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /boot/grub (is /dev mounted?).
sh-5.0# exit
exit
[[email protected] mnt]# mount | tail -l
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] mnt]# chroot /mnt
sh-5.0# sudo grub-install --root-directory=/mnt/boot /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /mnt/boot/boot/grub (is /dev mounted?).
sh-5.0# sudo grub-install --root-directory=/sys^Cdev/nvme0n1p1
sh-5.0# ls /sys/
sh-5.0# sudo grub-install --root-directory=/sys /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /sys/boot/grub (is /dev mounted?).
sh-5.0# ls /mnt/
Avalon Penguin boot timeshift
sh-5.0# exit
exit
[[email protected] mnt]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] mnt]# pwd
/mnt
[[email protected] mnt]# ls boot/
EFI grub
[[email protected] mnt]# chroot /mnt
sh-5.0# grub-install /dev/nvme0n1p1/
Installing for i386-pc platform.
grub-install: error: cannot find a device for /boot/grub (is /dev mounted?).
sh-5.0# umount /dev/nvme0n1p1
umount: /dev/nvme0n1p1: umount failed: No such file or directory.
sh-5.0# ls /dev/
null
sh-5.0# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
sh-5.0# ls /home/
blkid.md mori tele
sh-5.0# ls /mnt/
Avalon Penguin boot timeshift
sh-5.0# ls /mnt/boot/
boot
sh-5.0# ls /mnt/boot/boot/
grub
sh-5.0# ls /mnt/boot/boot/grub/
fonts grubenv i386-pc themes
sh-5.0# exit
exit
[[email protected] mnt]# mount | tail -l
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] mnt]# pwd
/mnt
[[email protected] mnt]# exit
--> umount: [/mnt/mnt/Avalon/]
--> umount: [/mnt/mnt/Penguin]
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
--> umount: [/mnt]
umount: /mnt/mnt/Avalon: no mount point specified.
umount: /mnt/mnt/Penguin: no mount point specified.
umount: /mnt: target is busy.
[[email protected] ~]$ mount | tail -l
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/sdb1 on /mnt/mnt/Penguin type ext4 (rw,relatime,stripe=8191)
/dev/sdc2 on /mnt/mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
/dev/nvme0n1p2 on /mnt/mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt/mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] ~]$ umount /dev/nvme0n1p1
umount: /mnt/mnt/boot: must be superuser to unmount.
[[email protected] ~]$ sudo umount /dev/nvme0n1p1
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
[m[email protected] ~]$ mount | tail -;
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/sdb1 on /mnt/mnt/Penguin type ext4 (rw,relatime,stripe=8191)
/dev/sdc2 on /mnt/mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
[[email protected] ~]$ sudo manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
mount: /mnt: /dev/nvme0n1p2 already mounted on /mnt.
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
mount: /mnt/mnt/Penguin: /dev/sdb1 already mounted on /mnt/mnt/Penguin.
--> mount: [/mnt/mnt/Avalon/]
Mount is denied because the NTFS volume is already exclusively opened.
The volume may be already mounted, or another software may use it which
could be identified for example by the help of the 'fuser' command.
[[email protected] /]# exit
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
[[email protected] ~]$ ls /mnt/
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] ~]$ ls /mnt/mnt/
Avalon boot Penguin timeshift
[[email protected] ~]$ mount | tail -;
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/sdb1 on /mnt/mnt/Penguin type ext4 (rw,relatime,stripe=8191)
/dev/sdc2 on /mnt/mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
[[email protected] ~]$ umount /dev/sdb1
umount: /mnt/mnt/Penguin: must be superuser to unmount.
[[email protected] ~]$ sudo umount /dev/sdb1
[[email protected] ~]$ sudo umount /dev/sdc2
[[email protected] ~]$ umount /dev/sdb1
umount: /dev/sdb1: must be superuser to unmount.
[[email protected] ~]$ mount | tail -;
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
[[email protected] ~]$ mount | tail -;
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
[[email protected] ~]$ mount | tail -;
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /etc/pacman.d/gnupg type tmpfs (rw,relatime,mode=755)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=4936596k,mode=700,uid=1000,gid=1000)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
[[email protected] ~]$ sudo manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
--> mount: [/mnt/mnt/Avalon/]
[[email protected] /]# mount | tail -l
/dev/sdc2 on /mnt/Avalon type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
[[email protected] /]# mount /dev/nvme0n1p2 /^C
[[email protected] /]# ls /mnt/
Avalon Penguin boot timeshift
[[email protected] /]# ls /mnt/boot/
boot
[[email protected] /]# ls /mnt/boot/boot/
grub
[[email protected] /]# ls -l /mnt/boot/boot/
total 4
drwxr-xr-x 5 root root 4096 Jul 23 00:39 grub
[[email protected] /]# mount /dev/nvme0n1p
nvme0n1p1 nvme0n1p2
[[email protected] /]# mount /dev/nvme0n1p2 /mnt
[[email protected] /]# ls /mnt/boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
[[email protected] /]# mount /dev/nvme0n1p1 /mnt/boot
[[email protected] /]# ls /mnt/boot/
EFI grub
[[email protected] /]# cd /mnt/
[[email protected] mnt]# chroot /mnt
sh-5.0# exit
exit
[[email protected] mnt]# mount | tail -l
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] mnt]# chroot /mnt
sh-5.0# grub-install /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /boot/grub (is /dev mounted?).
sh-5.0# grub-install --root/directory=/mnt/boot /dev/nvme0n1p1
grub-install: unrecognized option '--root/directory=/mnt/boot'
Try 'grub-install --help' or 'grub-install --usage' for more information.
sh-5.0# grub-install --root-directory=/mnt/boot /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /mnt/boot/boot/grub (is /dev mounted?).
sh-5.0# grub-install --root-directory=/mnt /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /mnt/boot/grub (is /dev mounted?).
sh-5.0# umount /dev/nvme0n1p1
umount: /dev/nvme0n1p1: umount failed: No such file or directory.
sh-5.0# exit
exit
[[email protected] mnt]# umount /dev/nvme0n1p1
[[email protected] mnt]# chroot /mnt
sh-5.0# ls /mnt/
Avalon Penguin boot timeshift
sh-5.0# exit
exit
[[email protected] mnt]# ls /mnt
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] mnt]# ls /mnt/boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
[[email protected] mnt]# chroot /mnt
sh-5.0# grub-install /dev/nvme0n1p1
Installing for i386-pc platform.
grub-install: error: cannot find a device for /boot/grub (is /dev mounted?).
sh-5.0# exit
exit
[[email protected] mnt]# mount /dev/nvme0n1p2 /mnt
mount: /mnt: /dev/nvme0n1p2 already mounted on /.
[[email protected] mnt]# mount | tail -l
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
[[email protected] mnt]# ls /
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] mnt]# mount /dev/nvme0n1p1 /mnt/boot/
[[email protected] mnt]# chroot /mnt
sh-5.0# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
sh-5.0# ls boot/
EFI grub
sh-5.0# ls /dev/
null
sh-5.0# ls /mnt/
Avalon/ Penguin/ boot/ timeshift/
sh-5.0# ls mnt/boot/
boot grub
sh-5.0# ls mnt/boot/boot/
grub
sh-5.0# grub-install boot/
Installing for i386-pc platform.
grub-install: error: cannot find a device for /boot/grub (is /dev mounted?).
sh-5.0# ls boot/grub/
fonts grubenv i386-pc themes
sh-5.0# grub-install --root-directory=/mnt/mnt/boot boot/
Installing for i386-pc platform.
grub-install: error: cannot find a device for /mnt/mnt/boot/boot/grub (is /dev mounted?).
sh-5.0# grub-install --root-directory=/mnt/mnt/ boot/
Installing for i386-pc platform.
grub-install: error: cannot find a device for /mnt/mnt/boot/grub (is /dev mounted?).
sh-5.0# exit
exit
[[email protected] mnt]# mount --bind /dev/nvme0n1p1 /mnt/boot/
mount: /mnt/boot: mount(2) system call failed: Not a directory.
[[email protected] mnt]# exit
--> umount: [/mnt/mnt/Avalon/]
--> umount: [/mnt/mnt/Penguin]
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
--> umount: [/mnt]
umount: /mnt/mnt/Avalon: no mount point specified.
umount: /mnt/mnt/Penguin: no mount point specified.
umount: /mnt: target is busy.
[[email protected] ~]$ sudo umount /dev/nvme0n1p1
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
[[email protected] ~]$ sudo umount /dev/scb1
umount: /dev/scb1: no mount point specified.
[[email protected] ~]$ sudo umount /dev/sdc2
[[email protected] ~]$ sudo umount /dev/sdb1
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
[[email protected] ~]$ manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
--> mount: [/mnt/mnt/Avalon/]
[[email protected] /]# ls /mnt/
Avalon Penguin boot mnt timeshift
[[email protected] /]# ls /mnt/mnt/
boot
[[email protected] /]# ls /mnt/mnt/boot/
boot grub
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# mount --bind /dev/nvme0n1p2 /mnt
mount: /mnt: mount(2) system call failed: Not a directory.
[[email protected] /]# ls /mnt/
Avalon Penguin boot mnt timeshift
[[email protected] /]# mount --bind /dev/nvme0n1p2 /mnt/
mount: /mnt: mount(2) system call failed: Not a directory.
[[email protected] /]# mount /dev/nvme0n1p2 /mnt/
[[email protected] /]# ls /dev/
autofs dri hidraw3 loop0 nvme0 rtc sg1 tty11 tty23 tty35 tty47 tty59 udmabuf vcsa vcsu6
block drm_dp_aux0 hidraw4 loop1 nvme0n1 rtc0 sg2 tty12 tty24 tty36 tty48 tty6 uhid vcsa1 vfio
bsg drm_dp_aux1 hpet loop2 nvme0n1p1 sda sg3 tty13 tty25 tty37 tty49 tty60 uinput vcsa2 vga_arbiter
btrfs-control drm_dp_aux2 hugepages loop3 nvme0n1p2 sda1 shm tty14 tty26 tty38 tty5 tty61 urandom vcsa3 vhci
bus fb0 hwrng loop4 nvram sdb snapshot tty15 tty27 tty39 tty50 tty62 usb vcsa4 vhost-net
char fd initctl loop5 parport0 sdb1 snd tty16 tty28 tty4 tty51 tty63 userio vcsa5 vhost-vsock
console full input loop6 port sdc stderr tty17 tty29 tty40 tty52 tty7 vcs vcsa6 zero
core fuse kfd loop7 ppp sdc1 stdin tty18 tty3 tty41 tty53 tty8 vcs1 vcsu zfs
cpu gpiochip0 kmsg mapper psaux sdc2 stdout tty19 tty30 tty42 tty54 tty9 vcs2 vcsu1
cpu_dma_latency gpiochip1 kvm mem ptmx sdd tty tty2 tty31 tty43 tty55 ttyS0 vcs3 vcsu2
cuse hidraw0 lightnvm mqueue pts sdd1 tty0 tty20 tty32 tty44 tty56 ttyS1 vcs4 vcsu3
disk hidraw1 log net random sdd2 tty1 tty21 tty33 tty45 tty57 ttyS2 vcs5 vcsu4
dma_heap hidraw2 loop-control null rfkill sg0 tty10 tty22 tty34 tty46 tty58 ttyS3 vcs6 vcsu5
[[email protected] /]# mount --rbind /dev /mnt/dev
[[email protected] /]# mount --rbind /proc /mnt/proc
[[email protected] /]# mount --rbind /sys /mnt/sys
[[email protected] /]# chroot /mnt/
sh-5.0# ls /dev/
autofs dri hidraw3 loop0 nvme0 rtc sg1 tty11 tty23 tty35 tty47 tty59 udmabuf vcsa vcsu6
block drm_dp_aux0 hidraw4 loop1 nvme0n1 rtc0 sg2 tty12 tty24 tty36 tty48 tty6 uhid vcsa1 vfio
bsg drm_dp_aux1 hpet loop2 nvme0n1p1 sda sg3 tty13 tty25 tty37 tty49 tty60 uinput vcsa2 vga_arbiter
btrfs-control drm_dp_aux2 hugepages loop3 nvme0n1p2 sda1 shm tty14 tty26 tty38 tty5 tty61 urandom vcsa3 vhci
bus fb0 hwrng loop4 nvram sdb snapshot tty15 tty27 tty39 tty50 tty62 usb vcsa4 vhost-net
char fd initctl loop5 parport0 sdb1 snd tty16 tty28 tty4 tty51 tty63 userio vcsa5 vhost-vsock
console full input loop6 port sdc stderr tty17 tty29 tty40 tty52 tty7 vcs vcsa6 zero
core fuse kfd loop7 ppp sdc1 stdin tty18 tty3 tty41 tty53 tty8 vcs1 vcsu zfs
cpu gpiochip0 kmsg mapper psaux sdc2 stdout tty19 tty30 tty42 tty54 tty9 vcs2 vcsu1
cpu_dma_latency gpiochip1 kvm mem ptmx sdd tty tty2 tty31 tty43 tty55 ttyS0 vcs3 vcsu2
cuse hidraw0 lightnvm mqueue pts sdd1 tty0 tty20 tty32 tty44 tty56 ttyS1 vcs4 vcsu3
disk hidraw1 log net random sdd2 tty1 tty21 tty33 tty45 tty57 ttyS2 vcs5 vcsu4
dma_heap hidraw2 loop-control null rfkill sg0 tty10 tty22 tty34 tty46 tty58 ttyS3 vcs6 vcsu5
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
sh-5.0# mount /dev/nvme0n1p
nvme0n1p1 nvme0n1p2
sh-5.0# mount /dev/nvme0n1p1 /^C
sh-5.0# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
sh-5.0# ls /dev/nvme0n1p1
/dev/nvme0n1p1
sh-5.0# ls /dev/nvme0n1p1/
ls: cannot access '/dev/nvme0n1p1/': Not a directory
sh-5.0# mount /dev/nvme0n1p1 ^C
sh-5.0# ls boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
sh-5.0# mount /dev/nvme0n1p1/ /
mount: /: special device /dev/nvme0n1p1/ does not exist (a path prefix is not a directory).
sh-5.0# mount /dev/nvme0n1p1 /
sh-5.0# ls boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p1 on / type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
sh-5.0# ls /
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
sh-5.0# ls boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
sh-5.0# ls mnt/
Avalon Penguin boot mnt timeshift
sh-5.0# ls mnt/boot/
boot grub
sh-5.0# ls mnt/boot/boot/
grub
sh-5.0# ls mnt/mnt/
boot
sh-5.0# ls mnt/mnt/boot/
boot grub
sh-5.0# grub-install /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# ls /boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
sh-5.0# mount /dev/nvme0n1p1 /boot
sh-5.0# ls /boot/
EFI grub
sh-5.0# grub-install /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# exit
exit
[[email protected] /]# mount | tail -l
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
udev on /mnt/dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /mnt/dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /mnt/dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /mnt/proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /mnt/sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /mnt/sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p1 on /mnt type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] /]# umount /dev/nvme0n1p2
umount: /dev/nvme0n1p2: umount failed: Invalid argument.
[[email protected] /]# mount | tail -l
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
udev on /mnt/dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /mnt/dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /mnt/dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /mnt/proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /mnt/sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /mnt/sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p1 on /mnt type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
[[email protected] /]# umount /dev/nvme0n1p1
umount: /mnt/boot: no mount point specified.
[[email protected] /]# umount /dev/nvme0n1p2
umount: /dev/nvme0n1p2: umount failed: Invalid argument.
[[email protected] /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# ls boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
[[email protected] /]# ls mnt/
EFI grub
[[email protected] /]# exit
--> umount: [/mnt/mnt/Avalon/]
--> umount: [/mnt/mnt/Penguin]
--> umount: [/mnt/root]
--> umount: [/mnt/boot/efi]
--> umount: [/mnt]
umount: /mnt/mnt/Avalon: no mount point specified.
umount: /mnt/mnt/Penguin: no mount point specified.
umount: /mnt: target is busy.
[[email protected] ~]$ sudo umount /dev/nvme0n1p2
umount: /dev/nvme0n1p2: umount failed: Invalid argument.
[[email protected] ~]$ sudo umount /dev/nvme0n1p1
umount: /mnt/mnt/boot: no mount point specified.
[[email protected] ~]$ sudo umount /dev/sdb1
umount: /mnt/mnt/Penguin: no mount point specified.
[[email protected] ~]$ sudo umount /dev/sdc2
umount: /mnt/mnt/Avalon: no mount point specified.
[[email protected] ~]$ ls /mnt/mnt/
EFI grub
[[email protected] ~]$ manjaro-chroot -a
==> Mounting (ManjaroLinux) [/dev/nvme0n1p2]
--> mount: [/mnt]
mount: /mnt: /dev/nvme0n1p2 already mounted on /mnt.
--> mount: [/mnt/boot/efi]
--> mount: [/mnt/root]
--> mount: [/mnt/mnt/Penguin]
mount: /mnt/mnt/Penguin: mount point does not exist.
--> mount: [/mnt/mnt/Avalon/]
Mount is denied because the NTFS volume is already exclusively opened.
The volume may be already mounted, or another software may use it which
could be identified for example by the help of the 'fuser' command.
[[email protected]aro /]# ls
bin desktopfs-pkgs.txt etc lib lost+found none proc rootfs-pkgs.txt sbin srv tmp var
boot dev home lib64 mnt opt root run snap sys usr
[[email protected] /]# ls boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
[[email protected] /]# ls /mnt/
EFI grub
[[email protected] /]# mount | tail -l
/dev/sda1 on /root type ext4 (rw,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
[[email protected] /]# ls /mnt/
EFI grub
[[email protected] /]# chroot /mnt
chroot: failed to run command '/bin/sh': No such file or directory
[[email protected] /]# mount /dev/nvme0n1p2 /mnt
[[email protected] /]# mount /dev/nvme0n1p1 /mnt/boot/
[[email protected] /]# mount --rbind /dev /mnt/dev
[[email protected] /]# mount --rbind /proc /mnt/proc
[[email protected] /]# mount --rbind /sys /mnt/sys
[[email protected] /]# chroot /mnt
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
sh-5.0# ls /boot/
EFI grub
sh-5.0# grub-install /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# grub-install --root-direcotry=/mnt/mnt/boot/ /dev/nvme0n1p1
grub-install: unrecognized option '--root-direcotry=/mnt/mnt/boot/'
Try 'grub-install --help' or 'grub-install --usage' for more information.
sh-5.0# grub-install --root-directory=/mnt/mnt/boot/ /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# mount /dev/nvme0n1p1 /boot
mount: /boot: /dev/nvme0n1p1 already mounted on /boot.
sh-5.0# mount /dev/nvme0n1p1 /boot/
mount: /boot: /dev/nvme0n1p1 already mounted on /boot.
sh-5.0# ls /boot/
EFI grub
sh-5.0# exit
exit
[[email protected] /]# mount | tail -l
tmp on /tmp type tmpfs (rw,nosuid,nodev)
overlay on /etc/resolv.conf type overlay (rw,relatime,lowerdir=/run/miso/sfs/livefs:/run/miso/sfs/mhwdfs:/run/miso/sfs/desktopfs:/run/miso/sfs/rootfs,upperdir=/run/miso/overlay_root/upper,workdir=/run/miso/overlay_root/work,index=off)
/dev/nvme0n1p2 on /mnt type ext4 (rw,relatime)
/dev/nvme0n1p1 on /mnt/boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
udev on /mnt/dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /mnt/dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /mnt/dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /mnt/proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /mnt/sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /mnt/sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
[[email protected] /]# chroot /mnt
sh-5.0# grub-install --root-directory=/mnt/boot/ /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# grub-install --root-directory=/mnt/boot /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# ls /boot/
EFI grub
sh-5.0# mount /dev/nvme0n1p1 /boot/efi
sh-5.0# ls boot/
EFI grub
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p1 on /boot/EFI type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
sh-5.0# grub-install /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# grub-install --root-directory=/mnt/boot/efi /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# grub-install --root-directory=/mnt/boot/EFI /dev/nvme0n1p1
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
sh-5.0# umount /dev/nvme0n1p1
sh-5.0# ls /boot/
EFI grub
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
sh-5.0# umount /dev/nvme0n1p1
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
sh-5.0# ls /boot/
amd-ucode.img efi grub initramfs-5.4-x86_64-fallback.img initramfs-5.4-x86_64.img linux54-x86_64.kver memtest86+ vmlinuz-5.4-x86_64
sh-5.0# ls /boot/efi/
sh-5.0# mount /dev/nvme0n1p
nvme0n1p1 nvme0n1p2
sh-5.0# mount /dev/nvme0n1p1 /boot/efi
sh-5.0# mount | tail -l
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=24624776k,nr_inodes=6156194,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
shm on /dev/shm type tmpfs (rw,nosuid,nodev,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (ro,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p1 on /boot/efi type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
sh-5.0# grub-install /dev/nvme0n1p1
Installing for x86_64-efi platform.
Installation finished. No error reported.
sh-5.0#

本博客所有文章除特别声明外,均采用 CC BY-NC-ND 4.0协议 。转载请注明出处!