Magellan Linux

Annotation of /mcore-src/trunk/mcore-tools/dracut/mcored/run-mcored.sh.in

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2326 - (hide annotations) (download)
Fri Jul 11 13:09:42 2014 UTC (9 years, 10 months ago) by niro
Original Path: mcore-src/trunk/mcore-tools/dracut/run-mcored.sh.in
File size: 789 byte(s)
-only remount if the filesystem is ro and be more verbose
1 niro 2042 #!/bin/sh
2    
3 niro 2326 need_remount=0
4    
5 niro 2297 if [ -x @@SBINDIR@@/sslsvd -a -x @@SBINDIR@@/mcored -a -f @@CONFDDIR@@/mcored ]
6 niro 2042 then
7 niro 2298 if getargbool 1 rd.mcored && getargbool 0 rd.neednet && NEEDNET=1
8 niro 2071 then
9 niro 2297 # print ip config
10 niro 2326 echo "Current ip settings:"
11     echo "$(ip addr)"
12     [ -w / ] || need_remount=1
13     if [[ ${need_remount} = 1 ]]
14     then
15     # remont /sysroot writeable
16     echo "Remount /sysroot writeable"
17     mount -oremount,rw /sysroot
18     fi
19 niro 2297 # start mcored
20 niro 2323 echo "Starting mcore daemon"
21 niro 2297 export MROOT=/sysroot
22     . @@CONFDDIR@@/mcored
23     @@SBINDIR@@/sslsvd -U ${SSL_USER} -/ ${CHROOT_DIR} \
24     -Z ${SSL_CERT} -K ${SSL_KEY} \
25     0 6666 @@SBINDIR@@/mcored
26 niro 2326 if [[ ${need_remount} = 1 ]]
27     then
28     # remount sysroot read-only
29     echo "Remount /sysroot read-only"
30     mount -oremount,ro /sysroot
31     fi
32 niro 2071 fi
33 niro 2042 fi