Действия

QNAP: различия между версиями

Материал из lulzette's wiki

Нет описания правки
Строка 1: Строка 1:
== процессы ==
netmgr, asd.pyc, - /var/cache/netmgr/lock_timer.sh - qts pkg netmgr
== Version of D2? ==
== Version of D2? ==
/etc/hal.conf:
/etc/hal.conf:

Версия от 22:03, 3 июня 2020

процессы

netmgr, asd.pyc, - /var/cache/netmgr/lock_timer.sh - qts pkg netmgr

Version of D2?

/etc/hal.conf:

model = TS-231P

/etc/model.conf:

[System Enclosure]
VENDOR = QNAP
MODEL = TS-231P

partitions

Internal:

  • /dev/mtd3 - rootfs ?
  • /dev/mtd5 - update partition
  • /dev/mtd6 - config

Disks:

  • sda1 (md9) - config
  • sda2 (md256) - separate swap
  • sda3 - data
  • sda4 -
  • sda5 (md322) - swap on raid

/etc/platform.conf

[FIRMWARE STORAGE]
DEVICE_NODE = /dev/mtd
FS_TYPE = ubifs
UPDATE_TMP_PARTITION = 5
FS_ACTIVE_PARTITION = 3
FS_RECOVERY_PID = -1

[CONFIG STORAGE]
DEVICE_NODE = /dev/mtd
FS_TYPE = ubifs
FS_ACTIVE_PARTITION = 6

[MISC]
DISPLAY_NAME = D2

/etc/mtab

chroot

#!/bin/bash

cpath="/share/Container/container-station-data/lib/lxc/playground/rootfs"

mount --bind /dev $cpath/dev
mount --bind /sys $cpath/sys
mount --bind /proc $cpath/proc
mount --bind / $cpath/mnt

chroot $cpath

umount $cpath/dev
umount $cpath/sys
umount $cpath/proc
umount $cpath/mnt

Default Crontab

[~] # crontab -l
# m h dom m dow cmd
0 3 * * 0 /etc/init.d/idmap.sh dump
0 3 * * * /sbin/vs_refresh
0 3 * * * /sbin/clean_reset_pwd
0-59/15 * * * * /etc/init.d/nss2_dusg.sh
30 7 * * * /sbin/clean_upload_file
0-59/10 * * * * /etc/init.d/storage_usage.sh
30 3 * * * /sbin/notice_log_tool -v -R
0-59/20 3 * * * /sbin/adjust_time
*/10 * * * * /sbin/config_cache_util 0
0 23 */1 * * /sbin/qpkg_cli -U 1>/dev/null 2>/dev/null
# 0 0 * * * /usr/local/squid/sbin/squid -k rotate
21 9,21 * * * /sbin/notify_update --nc 1>/dev/null 2>&1
0 1 * * * /etc/init.d/flush_memory.sh >/dev/null 2>&1
10 02 * * * /usr/bin/power_clean -c 2>/dev/null
0 0 1 * * /sbin/hal_event --pd_self_test dev_id=0x00000002,action=2
0 0 1 * * /sbin/hal_event --pd_self_test dev_id=0x00000001,action=2
0 0 * * 1 /sbin/hal_event --pd_self_test dev_id=0x00000002,action=1
0 0 * * 1 /sbin/hal_event --pd_self_test dev_id=0x00000001,action=1
30 6 * * 1 /sbin/storage_util --disk_sequential_read_speed_test 1>/dev/null 2>&1
#0 2 * * * /sbin/qfstrim
0 2 * * 0 /usr/local/medialibrary/bin/mymediadbcmd checkRepairDB  >/dev/null 2>&1
* * * * * /var/cache/netmgr/lock_timer.sh
0 4,16 * * * /sbin/hwclock -s
4 3 * * 3 /etc/init.d/backup_conf.sh
0 12 * * * /mnt/ext/opt/LicenseCenter/bin/qlicense_tool local_check
0 0 * * * /usr/local/sbin/qsh nc.archive >/dev/null 2>&1
29 22 * * * /mnt/ext/opt/QcloudSSLCertificate/bin/ssl_agent_cli


init

rcS - init при включении

rcK - init перед выключением


/etc/daemon_mgr.conf

DAEMON0 = hal_daemon, start, /sbin/hal_daemon -f
DAEMON1 = lvmetad, start, /sbin/lvmetad
DAEMON2 = bcclient, start, /sbin/bcclient
DAEMON3 = qwatchdogd, start, /sbin/qwatchdogd -t 1 &
DAEMON4 = netwatchdog, start, /sbin/netwatchdog -d
DAEMON5 = cs_daemon, start, /sbin/cs_daemon
DAEMON6 = cs_qdaemon, start, /sbin/cs_qdaemon &
DAEMON7 = modagent, start, /sbin/modagent
DAEMON8 = ifd, start, /usr/local/bin/ifd
DAEMON9 = nmd, start, /usr/sbin/nmd.sh
DAEMON10 = qpkgd, start, QNAP_QPKG=appcenter /sbin/qpkgd -d0 > /dev/null 2>&1 &
DAEMON11 = ql_daemon, start, QNAP_QPKG=LicenseCenter /usr/local/bin/ql_daemon -d 7 > /dev/null 2>&1
DAEMON12 = ncdb, start, QNAP_QPKG=NotificationCenter /usr/local/sbin/ncdb --defaults-file=/mnt/ext/opt/NotificationCenter/etc/nc-mariadb.conf >/dev/null 2>&1 &
DAEMON13 = ncloud, start, QNAP_QPKG=NotificationCenter /usr/local/sbin/ncloud
DAEMON14 = ncd, start, QNAP_QPKG=NotificationCenter LD_LIBRARY_PATH=/mnt/ext/opt/mariadb/lib /usr/local/sbin/ncd
DAEMON15 = qdesk_soldier, stop, QNAP_QPKG=helpdesk /sbin/qdesk_soldier
DAEMON16 = proftpd, start, QNAP_QPKG=ftp LD_PRELOAD=/usr/local/lib/libtrash.so TZ=/etc/localtime /usr/local/sbin/proftpd -n > /dev/null 2>&1 &
DAEMON17 = Qthttpd, start, QNAP_QPKG=webserver /usr/local/sbin/Qthttpd -p 80 -nor -nos -u admin -d /home/Qhttpd -c '**.*'
DAEMON18 = cupsd, start, /usr/sbin/cupsd -c /etc/config/cups/cupsd.conf
DAEMON19 = mytranscodesvr, start, QNAP_QPKG=MultimediaConsole TERMINFO='/usr/share/terminfo/' LANG='en_US.UTF-8' /usr/sbin/screen -dmS 'MYTRANSCODE' /usr/local/medialibrary/bin/mytranscodesvr -debug -db /share/CACHEDEV1_DATA/
DAEMON20 = mymedia_cli, start, QNAP_QPKG=MultimediaConsole /usr/local/medialibrary/bin/mymedia_cli -d >/dev/null 2>&1
DAEMON21 = _thttpd_, start, /usr/local/sbin/_thttpd_ -p 58080 -nor -nos -u admin -d /home/httpd -c '**.*' -h 127.0.0.1 -i /var/lock/._thttpd_.pid
DAEMON22 = php-fpm-proxy, start, /usr/local/apache/bin/php-fpm-proxy -y /etc/php-fpm-sys-proxy.conf -p /var/ -c /etc/default_config/php.ini -g /var/lock/php-fpm-proxy.pid  -R 1>/dev/null 2>/dev/null </dev/null
DAEMON23 = apache_proxy, start, /etc/init.d/thttpd.sh start_apache >/dev/null 2>&1
DAEMON24 = lpb_scheduler, start, /sbin/lpb_scheduler -d
DAEMON25 = genthd, start, /sbin/genthd&
DAEMON26 = upsutil, start, /usr/sbin/upsutil  &
DAEMON27 = ntpdated, start, /usr/sbin/ntpdated
DAEMON28 = sshd, start, /usr/sbin/sshd -f /etc/config/ssh/sshd_config -p 22
DAEMON29 = crond, start, /usr/sbin/crond -l 9 -c /tmp/cron/crontabs
DAEMON30 = rfsd, start, /sbin/rfsd -f /etc/rfsd.conf
DAEMON31 = syslog_maild, stop, QNAP_QPKG=rsyslog /sbin/syslog_maild -d
DAEMON32 = gen_bandwidth, start, /sbin/gen_bandwidth -r -i 5 &
DAEMON33 = klogd.sh, start, /etc/init.d/klogd.sh start &
DAEMON34 = qNoticeEngined, start, /sbin/qNoticeEngined
DAEMON35 = qShield, start, /sbin/qShield
DAEMON36 = qsyslogd, start, QNAP_QPKG=syslog /sbin/qsyslogd
DAEMON37 = qLogEngined, start, QNAP_QPKG=syslog /sbin/qLogEngined
DAEMON38 = qsnapman, start, /usr/bin/qsnapman >/dev/null &
DAEMON39 = qstorman, start, /usr/bin/qstorman >/dev/null &
DAEMON40 = qsyncman, start, QNAP_QPKG=rtrr /usr/bin/qsyncman 1>/dev/null 2>&1
DAEMON41 = porter, start, QNAP_QPKG=myQNAPcloud /usr/local/bin/porter -d 7 > /dev/null
DAEMON42 = qsnapman-alive, start, /usr/bin/qsnapman-alive >/dev/null &
DAEMON43 = pn_daemon, start, QNAP_QPKG=myQNAPcloud /usr/local/bin/pn_daemon -d 7 > /dev/null 2>&1
DAEMON44 = qsnapman-smart, start, /usr/bin/qsnapman-smart >/dev/null &
DAEMON45 = qsnapman-recyc, start, /usr/bin/qsnapman-recyc >/dev/null &
DAEMON46 = upnpcd, start, /sbin/upnpcd -i 300 &
DAEMON47 = upnpd, stop, /sbin/upnpd br0 br0
DAEMON48 = upsd, start, /usr/sbin/upsd -u admin

/etc/inittab

# /etc/inittab
#
# Copyright (C) 2001 Erik Andersen <andersen@codepoet.org>
#
# Note: BusyBox init doesn't support runlevels.  The runlevels field is
# completely ignored by BusyBox init. If you want runlevels, use
# sysvinit.
#
# Format for each entry: <id>:<runlevels>:<action>:<process>
#
# id        == tty to run on, or empty for /dev/console
# runlevels == ignored
# action    == one of sysinit, respawn, askfirst, wait, and once
# process   == program to run

# Startup the system
#null::sysinit:/bin/mount -o remount,rw /
#null::sysinit:/bin/mount -t proc proc /proc
#null::sysinit:/bin/mount -a

#null::sysinit:/bin/hostname -F /etc/hostname
#null::sysinit:/sbin/ifconfig lo 127.0.0.1 up
#null::sysinit:/sbin/route add -net 127.0.0.0 netmask 255.0.0.0 lo
null::sysinit:/sbin/hwclock --hctosys

# now run any rc scripts
::sysinit:/etc/init.d/rcS

# Set up a couple of getty's
tty1::respawn:/sbin/getty 115200 ttyS0

# Put a getty on the serial port
#ttyS0::respawn:/sbin/getty -L ttyS0 115200 vt100

# Logging junk
null::sysinit:/bin/touch /var/log/messages
#null::respawn:/sbin/syslogd -n -m 0
#null::respawn:/sbin/klogd -n
#tty3::respawn:/usr/bin/tail -f /var/log/messages

# Stuff to do for the 3-finger salute
::ctrlaltdel:/sbin/reboot

# Stuff to do before rebooting
#null::shutdown:/usr/bin/killall klogd
#null::shutdown:/usr/bin/killall syslogd
null::shutdown:/etc/init.d/rcK


/etc/rcS.d/

lrwxrwxrwx    1        45 May 24 19:32 QS100helpdesk -> /mnt/HDA_ROOT/update_pkg/helpdesk/helpdesk.sh*
lrwxrwxrwx    1        28 May 24 19:32 QS101LicenseCenter -> /etc/init.d/LicenseCenter.sh*
lrwxrwxrwx    1        32 May 24 19:34 QS101MultimediaConsole -> /etc/init.d/MultimediaConsole.sh*
lrwxrwxrwx    1        17 May 24 19:32 QS101NotificationCenter -> /etc/init.d/nc.sh*
lrwxrwxrwx    1        35 May 24 19:32 QS101QcloudSSLCertificate -> /etc/init.d/QcloudSSLCertificate.sh*
lrwxrwxrwx    1        22 May 24 19:33 QS102SSDLaboratory -> /etc/init.d/ssd_lab.sh*
lrwxrwxrwx    1        40 May 24 19:32 QS103ResourceMonitor -> /mnt/ext/opt/ResourceMonitor/qpkg_res.sh*
lrwxrwxrwx    1        55 May 24 19:32 QS104PhotoStation -> /share/CACHEDEV1_DATA/.qpkg/PhotoStation/qpkg_photos.sh*
lrwxrwxrwx    1        51 May 24 19:32 QS105QVPN -> /share/CACHEDEV1_DATA/.qpkg/QVPN/etc/init.d/qvpn.sh*
lrwxrwxrwx    1        29 May 24 19:32 QS106netmgr -> /mnt/ext/opt/netmgr/netmgr.sh*
lrwxrwxrwx    1        66 May 24 19:32 QS109container-station -> /share/CACHEDEV1_DATA/.qpkg/container-station/container-station.sh*
lrwxrwxrwx    1        21 May 24 19:33 QS150Qboost -> /etc/init.d/qboost.sh*
lrwxrwxrwx    1        23 May 24 19:32 QS200helpdesk -> /etc/init.d/helpdesk.sh*
lrwxrwxrwx    1        18 May 24 22:27 S30mountall -> ../init.d/mountall*
lrwxrwxrwx    1        26 May 24 22:27 S31init_hardware -> ../init.d/init_hardware.sh*
lrwxrwxrwx    1        26 May 24 22:27 S32init_mac_addr -> ../init.d/init_mac_addr.sh*
lrwxrwxrwx    1        20 May 24 22:27 S33sysinit -> ../init.d/sysinit.sh*
lrwxrwxrwx    1        27 May 24 22:27 S34shutdown_check -> ../init.d/shutdown_check.sh*
lrwxrwxrwx    1        22 May 24 22:27 S35init_disk -> ../init.d/init_disk.sh*
lrwxrwxrwx    1        25 May 24 22:27 S40init_network -> ../init.d/init_network.sh*
lrwxrwxrwx    1        21 May 24 22:27 S42hostname -> ../init.d/hostname.sh*
lrwxrwxrwx    1        20 May 24 22:27 S45network -> ../init.d/network.sh*
lrwxrwxrwx    1        17 May 24 22:27 S45vlan -> ../init.d/vlan.sh@
lrwxrwxrwx    1        22 May 24 22:27 S46iSCSItrgt -> ../init.d/iscsitrgt.sh*
lrwxrwxrwx    1        22 May 24 22:27 S46iscsiinit -> ../init.d/iscsiinit.sh*
lrwxrwxrwx    1        17 May 24 22:27 S55urandom -> ../init.d/urandom*
lrwxrwxrwx    1        20 May 24 22:27 S56mariadb -> ../init.d/mariadb.sh*
lrwxrwxrwx    1        26 May 24 22:27 S56start_service -> ../init.d/start_service.sh*
lrwxrwxrwx    1        22 May 24 22:27 S57init_qpkg -> ../init.d/init_qpkg.sh*
lrwxrwxrwx    1        17 May 24 22:27 S57ldap -> ../init.d/ldap.sh*
lrwxrwxrwx    1        17 May 24 22:27 S58dbus -> ../init.d/dbus.sh*
lrwxrwxrwx    1        21 May 24 22:27 S58nsswitch -> ../init.d/nsswitch.sh*
lrwxrwxrwx    1        20 May 24 22:27 S58printer -> ../init.d/printer.sh*
lrwxrwxrwx    1        20 May 24 22:27 S59Qthttpd -> ../init.d/Qthttpd.sh*
lrwxrwxrwx    1        15 May 24 22:27 S62GQ -> ../init.d/GQ.sh@
lrwxrwxrwx    1        18 May 24 22:27 S62cupsd -> ../init.d/cupsd.sh*
lrwxrwxrwx    1        17 May 24 22:27 S62ntpd -> ../init.d/ntpf.sh*
lrwxrwxrwx    1        16 May 24 22:27 S62smb -> ../init.d/smb.sh*
lrwxrwxrwx    1        30 May 24 22:27 S64MediaService -> ../init.d/StartMediaService.sh*
lrwxrwxrwx    1        16 May 24 22:27 S65btd -> ../init.d/btd.sh@
lrwxrwxrwx    1        19 May 24 22:27 S65thttpd -> ../init.d/thttpd.sh*
lrwxrwxrwx    1        17 May 24 22:27 S66ImRd -> ../init.d/ImRd.sh*
lrwxrwxrwx    1        23 May 24 22:27 S66wfm_thttpd -> ../init.d/wfm_thttpd.sh*
lrwxrwxrwx    1        16 May 24 22:27 S67ftp -> ../init.d/ftp.sh*
lrwxrwxrwx    1        18 May 24 22:27 S70crond -> ../init.d/crond.sh*
lrwxrwxrwx    1        17 May 24 22:27 S72logo -> ../init.d/logo.sh*
lrwxrwxrwx    1        22 May 24 22:27 S73ntpclient -> ../init.d/ntpclient.sh*
lrwxrwxrwx    1        20 May 24 22:27 S75stunnel -> ../init.d/stunnel.sh*
lrwxrwxrwx    1        21 May 24 22:27 S77recycled -> ../init.d/recycled.sh*
lrwxrwxrwx    1        19 May 24 22:27 S78qraid1 -> ../init.d/qraid1.sh*
lrwxrwxrwx    1        16 May 24 22:27 S83ups -> ../init.d/ups.sh*
lrwxrwxrwx    1        22 May 24 22:27 S84bluetooth -> ../init.d/bluetooth.sh*
lrwxrwxrwx    1        18 May 24 22:27 S85login -> ../init.d/login.sh*
lrwxrwxrwx    1        20 May 24 22:27 S89bonjour -> ../init.d/bonjour.sh*
lrwxrwxrwx    1        16 May 24 22:27 S89wsd -> ../init.d/wsd.sh*
lrwxrwxrwx    1        24 May 24 22:27 S90twonkymedia -> ../init.d/twonkymedia.sh*
lrwxrwxrwx    1        23 May 24 22:27 S92lunportman -> ../init.d/lunportman.sh*
lrwxrwxrwx    1        14 May 24 22:27 S95snmp -> ../init.d/snmp*
lrwxrwxrwx    1        21 May 24 22:27 S98init_nas -> ../init.d/init_nas.sh*
lrwxrwxrwx    1        18 May 24 22:27 S99atalk -> ../init.d/atalk.sh*
lrwxrwxrwx    1        48 May 24 22:27 S99cloudinstall_report_complete_daemon -> ../init.d/cloudinstall_report_complete_daemon.sh*
lrwxrwxrwx    1        23 May 24 22:27 S99init_iTune -> ../init.d/init_iTune.sh@
lrwxrwxrwx    1        19 May 24 22:27 S99mysqld -> ../init.d/mysqld.sh*
lrwxrwxrwx    1        13 May 24 22:27 S99nfs -> ../init.d/nfs*
lrwxrwxrwx    1        19 May 24 22:27 S99porter -> ../init.d/porter.sh*
lrwxrwxrwx    1        27 May 24 22:27 S99qanalytic -> ../init.d/qanalytic_init.sh*
lrwxrwxrwx    1        24 May 24 22:27 S99qcloud -> ../init.d/qcloud_init.sh*
lrwxrwxrwx    1        21 May 24 22:27 S99qsnapman -> ../init.d/qsnapman.sh*
lrwxrwxrwx    1        21 May 24 22:27 S99qstorman -> ../init.d/qstorman.sh*
lrwxrwxrwx    1        21 May 24 22:27 S99qsyncman -> ../init.d/qsyncman.sh*
lrwxrwxrwx    1        17 May 24 22:27 S99sdmd.sh -> ../init.d/sdmd.sh*
lrwxrwxrwx    1        24 May 24 22:27 S99sync_action.sh -> ../init.d/sync_action.sh*
lrwxrwxrwx    1        22 May 24 22:27 S99z_antivirus -> ../init.d/antivirus.sh*