1 |
On Tuesday 11 December 2012 01:14:39 PM IST, J. Roeleveld wrote: |
2 |
>> Hi, |
3 |
>> |
4 |
>> I have a raid0 (kernel autodetect) array, over which I have put LVM |
5 |
>> and then there are volumes on the LVM for /var, /tmp, swap and /home. |
6 |
>> |
7 |
>> The problem is, raid0 array gets recognized, but localmount fails to |
8 |
>> mount because lvm doesn't seem to start before localmount (due to my |
9 |
>> root being on SSD, I can't watch the output of openrc easily). |
10 |
>> |
11 |
>> For now I have added this to my rc.conf - |
12 |
>> rc_localmount_before="lvm" |
13 |
> |
14 |
> In other words: "localmount" should run before "lvm" |
15 |
> |
16 |
>> rc_localmount_need="lvm" |
17 |
> |
18 |
> "localmount" requires "lvm" |
19 |
> |
20 |
>> rc_lvm_after="localmount" |
21 |
> |
22 |
> "lvm" should run after "localmount" |
23 |
> |
24 |
> Line 1 and 3 do the same. Line 2 is a contradiction. |
25 |
> |
26 |
>> This fixes the problem, but localmount still executes before lvm and |
27 |
>> terminates with operational error. Then lvm starts up and localmount |
28 |
>> runs again successfully. |
29 |
>> |
30 |
>> Any idea why this happens? |
31 |
> |
32 |
> Yes (See above) |
33 |
> |
34 |
>> The localmount script in init.d has proper depends: |
35 |
>> |
36 |
>> depend() |
37 |
>> { |
38 |
>> need fsck |
39 |
>> use lvm modules mtab |
40 |
>> after lvm modules |
41 |
>> keyword -jail -openvz -prefix -vserver -lxc |
42 |
>> } |
43 |
> |
44 |
> This should work. |
45 |
> |
46 |
> I actually have a similar setup and did not need to add the lines to rc.conf. |
47 |
> All I did was do what I was told: |
48 |
> Add "lvm" to the "boot" runlevel. |
49 |
> |
50 |
> Can you remove the lines from "rc.conf", ensure "lvm" is in the "boot" |
51 |
> runlevel (And not in any other, like "default") and then let us know if |
52 |
> you still get the error during reboot? |
53 |
> |
54 |
> If it all goes by too fast, can you press "I" during boot to get |
55 |
> interactive and then let us know: |
56 |
> 1) Which starts first, "lvm" or "localmount" |
57 |
> 2) What error messages do you see for any of the services. |
58 |
> |
59 |
> Kind regards, |
60 |
> |
61 |
> Joost Roeleveld |
62 |
> |
63 |
> |
64 |
|
65 |
Removing those lines didn't help, but I removed my stupidity there -- |
66 |
the contradicting dependency issue. |
67 |
It still doesn't start up before localmount. |
68 |
|
69 |
What I get when rc.conf is default without any manually inserted |
70 |
depends/etc: |
71 |
https://dl.dropbox.com/u/25780056/2012-12-11%2012.46.59.jpg & |
72 |
https://dl.dropbox.com/u/25780056/2012-12-11%2012.48.13.jpg |
73 |
|
74 |
My current rc.conf has this: |
75 |
|
76 |
rc_localmount_need="lvm" |
77 |
rc_localmount_after="lvm" |
78 |
rc_fsck_after="lvm" |
79 |
rc_fsck_need="lvm" |
80 |
rc_lvm_before="localmount" |
81 |
|
82 |
At least I have a usable system now and doesn't use my SSD for /var due |
83 |
to the failed LVM mount. |
84 |
But this results in one localmount failure -> lvm -> localmount success. |
85 |
|
86 |
I'm on openrc 0.11.8. |
87 |
|
88 |
-- |
89 |
Nilesh Govindarajan |
90 |
http://nileshgr.com |