Bug 36985 - Сервис template без бита execute
Summary: Сервис template без бита execute
Status: CLOSED NOTABUG
Alias: None
Product: Sisyphus
Classification: Development
Component: service (show other bugs)
Version: unstable
Hardware: all Linux
: P3 major
Assignee: placeholder@altlinux.org
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-06 09:30 MSK by Speccyfighter
Modified: 2019-07-08 11:18 MSK (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Speccyfighter 2019-07-06 09:30:15 MSK
Сабж:

# rpm -qpvl service-0.5.29-alt1.1.i586.rpm | grep template
-rw-r--r--    1 root    root             1355 мар 16  2018 /etc/rc.d/init.d/template

# grep chkconfig: /etc/rc.d/init.d/template
# chkconfig: - 90 10


Вследствие этого:

# chkconfig --list template
ошибка чтения информации о сервисе template: Нет такого файла или каталога

# chkconfig --add template
ошибка чтения информации о сервисе template: Нет такого файла или каталога


Временный обход ошибки:

# chmod a+x /etc/rc.d/init.d/template
Comment 1 Alexey Gladkov 2019-07-06 13:45:28 MSK
Это не бага. Это не сервис, а шаблон для него.
Comment 2 Speccyfighter 2019-07-06 17:01:11 MSK
(В ответ на комментарий №1)
> Это не бага. Это не сервис, а шаблон для него.

Этот шаблон мешал глобальной обработке сервисов

# grep chkconfig: /etc/rc.d/init.d/* | \
> grep -v storage-group | sort | \
> cut -f1 -d ':' | \
> cut -f5 -d '/' | \
>        while read line; \
>               do chkconfig $line reset; \
>        done
ошибка чтения информации о сервисе template: Нет такого файла или каталога


и пришлось его исключать:

# sysv-reset-services
# Script to reset all System V services to default state
# Run as root
#
grep chkconfig: /etc/rc.d/init.d/* | \
grep -v nm-group | sort | \
cut -f1 -d ':' | \
cut -f5 -d '/' | \
       while read line; \
           do \
               if [ -x "/etc/rc.d/init.d/$line" ]; then \
                       chkconfig $line reset; \
               fi; \
       done
Comment 3 Michael Shigorin 2019-07-07 15:37:20 MSK
Насколько понимаю, ровно так и задумано.
Comment 4 Speccyfighter 2019-07-08 11:18:28 MSK
Было бы лучше, если бы этот пример/шаблон лежал скажем где-нибудь например в документации, а не рядом с боевыми сервисами.