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 |
47 |
>> rc.conf. |
48 |
>> All I did was do what I was told: |
49 |
>> Add "lvm" to the "boot" runlevel. |
50 |
>> |
51 |
>> Can you remove the lines from "rc.conf", ensure "lvm" is in the "boot" |
52 |
>> runlevel (And not in any other, like "default") and then let us know if |
53 |
>> you still get the error during reboot? |
54 |
>> |
55 |
>> If it all goes by too fast, can you press "I" during boot to get |
56 |
>> interactive and then let us know: |
57 |
>> 1) Which starts first, "lvm" or "localmount" |
58 |
>> 2) What error messages do you see for any of the services. |
59 |
>> |
60 |
>> Kind regards, |
61 |
>> |
62 |
>> Joost Roeleveld |
63 |
>> |
64 |
>> |
65 |
> |
66 |
> Removing those lines didn't help, |
67 |
|
68 |
What is the end-result without the lines? |
69 |
|
70 |
|
71 |
> but I removed my stupidity there -- |
72 |
> the contradicting dependency issue. |
73 |
> It still doesn't start up before localmount. |
74 |
> |
75 |
> What I get when rc.conf is default without any manually inserted |
76 |
> depends/etc: |
77 |
> https://dl.dropbox.com/u/25780056/2012-12-11%2012.46.59.jpg & |
78 |
> https://dl.dropbox.com/u/25780056/2012-12-11%2012.48.13.jpg |
79 |
> |
80 |
> My current rc.conf has this: |
81 |
> |
82 |
> rc_localmount_need="lvm" |
83 |
> rc_localmount_after="lvm" |
84 |
> rc_fsck_after="lvm" |
85 |
> rc_fsck_need="lvm" |
86 |
> rc_lvm_before="localmount" |
87 |
> |
88 |
> At least I have a usable system now and doesn't use my SSD for /var due |
89 |
> to the failed LVM mount. |
90 |
> But this results in one localmount failure -> lvm -> localmount success. |
91 |
> |
92 |
> I'm on openrc 0.11.8. |
93 |
|
94 |
I use an older version still. |
95 |
In rc.conf, I only set the "need" lines for init-scripts I created myself. |
96 |
I never used the other lines. |
97 |
|
98 |
Do you have /usr on / ? Or on a seperate partition? |
99 |
|
100 |
Which metadata version did you use for the software raid setup? |
101 |
|
102 |
Can you add "mdadm" to the boot-runlevel? |
103 |
|
104 |
-- |
105 |
Joost |