View previous topic :: View next topic |
Author |
Message |
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 34
|
Posted: Fri Jun 05, 2020 5:07 pm Post subject: [Solved] /home failed to mount randomly during startup |
|
|
Hi, I've encountered a problem during startup these days.
When booting, usually, my desktop environment pops up, and everything works well. But sometimes, I only see a shell and startx doesn't work. I can login but all my configs for command line environment don't show up. I found that in these cases, /home failed to mount, while /usr mounted successfully (/usr is on a separated hard drive, while /home and / are on another hard drive). When I reboot, sometimes the problem disappear (at least for a while). I wonder what could be causing this weird problem.
Thanks for reading this topic.
----- Update -----
/etc/fstab
[/url]
Last edited by AprilGrimoire on Sun Jun 07, 2020 6:30 am; edited 2 times in total |
|
Back to top |
|
|
Banana Veteran
Joined: 21 May 2004 Posts: 1407 Location: Germany
|
|
Back to top |
|
|
toralf Developer
Joined: 01 Feb 2004 Posts: 3925 Location: Hamburg
|
Posted: Fri Jun 05, 2020 6:24 pm Post subject: Re: /home failed to mount randomly during startup |
|
|
AprilGrimoire wrote: | .../home failed to mount, while /usr mounted successfully (/usr is on a separated hard drive, while /home and / are on another hard drive)... | Without any more detailed info nobody can help you, so at least the /etc/fstab entries are needed IMO. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54315 Location: 56N 3W
|
Posted: Fri Jun 05, 2020 6:53 pm Post subject: |
|
|
AprilGrimoire,
Welcome to Gentoo.
I suspect you have a race condition and sometimes you loose.
Please post the output of _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 34
|
Posted: Sat Jun 06, 2020 2:54 am Post subject: |
|
|
NeddySeagoon wrote: | AprilGrimoire,
Welcome to Gentoo.
I suspect you have a race condition and sometimes you loose.
Please post the output of |
Thanks, it's
Code: |
lrwxrwxrwx 1 root root 19 Jun 6 10:46 /dev/vg1/usr -> /dev/mapper/vg1-usr
lrwxrwxrwx 1 root root 20 Jun 6 10:46 /dev/vg2/home -> /dev/mapper/vg2-home
lrwxrwxrwx 1 root root 20 Jun 6 10:46 /dev/vg2/root -> /dev/mapper/vg2-root
lrwxrwxrwx 1 root root 20 Jun 6 10:46 /dev/vg2/swap -> /dev/mapper/vg2-swap
|
|
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54315 Location: 56N 3W
|
Posted: Sat Jun 06, 2020 8:53 am Post subject: |
|
|
AprilGrimoire,
You do indeed have a race.
fstab uses /dev/vg2/home, which is a symbolic link to /dev/vg2/home -> /dev/mapper/vg2-home which may be a symbolic link to something else and so on.
These symbolic links are created by dynamically by udev as /dev is in RAM (DEVTMPFS in the kernel)
The race is between udev creating the symbolic links and localmount trying to use them. When udev wins, it works.
The news item Code: | 2016-11-04-important_fstab_and_localmount_update | applies here.
That only cites /dev/disk/by-* symbolic links but its the same issue.
Either do what that news item suggest or follow the symlink chain to the real /dev node and use the real /dev node in fstab.
Do that eveywhere, not just for /home. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 34
|
Posted: Sun Jun 07, 2020 6:30 am Post subject: |
|
|
NeddySeagoon wrote: | AprilGrimoire,
You do indeed have a race.
fstab uses /dev/vg2/home, which is a symbolic link to /dev/vg2/home -> /dev/mapper/vg2-home which may be a symbolic link to something else and so on.
These symbolic links are created by dynamically by udev as /dev is in RAM (DEVTMPFS in the kernel)
The race is between udev creating the symbolic links and localmount trying to use them. When udev wins, it works.
The news item Code: | 2016-11-04-important_fstab_and_localmount_update | applies here.
That only cites /dev/disk/by-* symbolic links but its the same issue.
Either do what that news item suggest or follow the symlink chain to the real /dev node and use the real /dev node in fstab.
Do that eveywhere, not just for /home. |
Thanks, i think that solved the problem. |
|
Back to top |
|
|
|