[Ocfs2-users] /etc/rc.local and /etc/fstab

Sunil Mushran sunil.mushran at oracle.com
Wed Oct 28 13:51:38 PDT 2009


No, I meant...

# chkconfig --add ocfs2
# chkconfig --list ocfs2
ocfs2              0:off    1:off    2:on    3:on    4:on    5:on    6:off


McKinley, Reid wrote:
> Thanks for the reply, Sunil.
>
> Can you please provide more detail.
>
> Do you mean to include this in the rc.local ?
>  
> /etc/init.d/o2cb start ocfs2 
>
> If we include this in the rc.local, then the service will automatically
> unmount the ocfs2 fs before shutdown?
>
> Thanks again,
> Reid
>
> -----Original Message-----
> From: Sunil Mushran [mailto:sunil.mushran at oracle.com] 
> Sent: Tuesday, October 27, 2009 4:23 PM
> To: McKinley, Reid
> Cc: ocfs2-users at oss.oracle.com; Ramayani, Atul
> Subject: Re: [Ocfs2-users] /etc/rc.local and /etc/fstab
>
> Ensure you have the ocfs2 service enabled so that shutdown will
> explicitly umount the fs before shutting down the network.
>
> McKinley, Reid wrote:
>> Upon system boot, is it ok to mount OCFS2 mounts from /etc/rc.local 
>> rather than /etc/fstab ? 
>>
>>  
>>
>> Are there any downsides to using rc.local that you are aware of?
>>
>>  
>>
>> Example /etc/rc.local script:
>>
>> #!/bin/sh
>>
>> #
>>
>> # This script will be executed *after* all the other init scripts.
>>
>> # You can put your own initialization stuff in here if you don't
>>
>> # want to do the full Sys V style init stuff.
>>
>>  
>>
>> touch /var/lock/subsys/local
>>
>> modprobe hangcheck-timer hangcheck_tick=1 hangcheck_margin=10 
>> hangcheck_reboot=1
>>
>> mount -t ocfs2 -o datavolume,nointr,_netdev,noatime 
>> /dev/mapper/mpath0  /u02
>>
>> mount -t ocfs2 -o datavolume,nointr,_netdev /dev/mapper/mpath1  /u03
>>
>>  
>>
>>  
>>
>> Thanks!
>>
>> -Reid
>>
>>  
>>
>> Reid McKinley



More information about the Ocfs2-users mailing list