Raspbian에서 비대화형 키오스크를 만들고 있습니다. 데스크톱 관리자, 다양한 그래픽 서비스 등 내가 원하지 않는 모든 것을 제거했습니다. 스크립트는 기능을 숨기는 줄과 Chromium을 차단하는 다른 12개 이상의 줄로 시작되었습니다. 다양한 팝업의 스팸.
systemd용 유닛 파일도 만들었습니다.
명령줄에서 실행하면 제대로 작동합니다. 그것은 처음부터 훌륭하게 작동했습니다 systemctl start chromium.service
. 하지만 내 인생에서는 부팅시 자동으로 시작되도록 할 수 없습니다.
먼저, 유닛 파일은 다음과 같습니다 /etc/systemd/system/chromium.service
.
[Unit]
Description=Start X and Chromium in kiosk mode
After=getty.target
[Service]
Type=idle
User=pi
ExecStart=/home/pi/start-chromium
[Install]
WantedBy=graphical.target
그래픽 대상이 기본값입니다.
root@raspberrypi:/home/pi# ls -l /etc/systemd/system/default.target
lrwxrwxrwx 1 root root 36 lut 24 17:00 /etc/systemd/system/default.target -> /lib/systemd/system/graphical.target
이미 활성화됨:
root@raspberrypi:/home/pi# ls -l /etc/systemd/system/graphical.target.wants/
lrwxrwxrwx 1 root root 36 lut 24 16:28 chromium.service -> /etc/systemd/system/chromium.service
시작 메시지는 그래픽 대상에 도달했음을 보여줍니다. 사용자 정의 서비스는 getty와 graphic.target 사이에 있어야 합니다.
[ OK ] Started Terminate Plymouth Boot Screen.
Starting Getty on tty1...
[ OK ] Started Getty on tty1.
Starting Serial Getty on ttyAMA0...
[ OK ] Started Serial Getty on ttyAMA0.
[ OK ] Reached target Login Prompts.
[ OK ] Started LSB: Start NTP daemon.
[ OK ] Reached target Multi-User System.
[ OK ] Reached target Graphical Interface.
Starting Update UTMP about System Runlevel Changes...
[ OK ] Started Update UTMP about System Runlevel Changes.
그러나 사용자 정의 서비스는 로그 어디에도 표시되지 않습니다.
-- The start-up result is done.
lut 24 14:06:03 raspberrypi systemd[1]: Starting Getty on tty1...
-- Subject: Unit [email protected] has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit [email protected] has begun starting up.
lut 24 14:06:03 raspberrypi systemd[1]: Started Getty on tty1.
-- Subject: Unit [email protected] has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit [email protected] has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:03 raspberrypi systemd[1]: Starting Serial Getty on ttyAMA0...
-- Subject: Unit [email protected] has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit [email protected] has begun starting up.
lut 24 14:06:03 raspberrypi systemd[1]: Started Serial Getty on ttyAMA0.
-- Subject: Unit [email protected] has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit [email protected] has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:03 raspberrypi systemd[1]: Starting Login Prompts.
-- Subject: Unit getty.target has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit getty.target has begun starting up.
lut 24 14:06:03 raspberrypi systemd[1]: Reached target Login Prompts.
-- Subject: Unit getty.target has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit getty.target has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:03 raspberrypi ntpd[492]: ntpd [email protected] Mon Nov 2 04:29:47 UTC 2015 (1)
lut 24 14:06:03 raspberrypi ntpd[499]: proto: precision = 0.833 usec
lut 24 14:06:03 raspberrypi ntp[464]: Starting NTP server: ntpd.
lut 24 14:06:03 raspberrypi systemd[1]: Started LSB: Start NTP daemon.
-- Subject: Unit ntp.service has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit ntp.service has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:03 raspberrypi systemd[1]: Starting Multi-User System.
-- Subject: Unit multi-user.target has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit multi-user.target has begun starting up.
lut 24 14:06:03 raspberrypi systemd[1]: Reached target Multi-User System.
-- Subject: Unit multi-user.target has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit multi-user.target has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:03 raspberrypi systemd[1]: Starting Graphical Interface.
-- Subject: Unit graphical.target has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit graphical.target has begun starting up.
lut 24 14:06:03 raspberrypi systemd[1]: Reached target Graphical Interface.
-- Subject: Unit graphical.target has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
편집하다:
root@raspberrypi:/home/pi# journalctl -u chromium
-- Logs begin at śro 2016-02-24 14:05:59 UTC, end at czw 2016-02-25 09:11:23 UTC. --
root@raspberrypi:/home/pi# systemctl status chromium
● chromium.service - Start X and Chromium in kiosk mode
Loaded: loaded (/etc/systemd/system/chromium.service; enabled)
Active: inactive (dead)
(이것은 스크립트가 모든 프로세스를 백그라운드로 보내는 것을 끝내도록 할 것인지, 아니면 마지막에 기다릴 것인지( &
마지막 명령에서 제거 ) chromium-browser
변경되지 않습니다 .
내가 무엇을 놓치고 있나요?
편집 2: 로그 수준은 Loglevel=debug입니다. 13:32:45 주변에 Chromium에 관한 항목이 몇 개 있지만 나에게는 아무것도 공개되지 않습니다.
lut 24 14:06:15 raspberrypi systemd[520]: pam_unix(systemd-user:session): session opened for user pi by (uid=0)
lut 24 14:06:15 raspberrypi systemd[520]: Executing: /lib/systemd/systemd --user
lut 24 14:06:15 raspberrypi systemd[520]: Starting Paths.
-- Subject: Unit UNIT has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has begun starting up.
lut 24 14:06:15 raspberrypi systemd[520]: Reached target Paths.
-- Subject: Unit UNIT has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[520]: Starting Timers.
-- Subject: Unit UNIT has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has begun starting up.
lut 24 14:06:15 raspberrypi systemd[520]: Reached target Timers.
-- Subject: Unit UNIT has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[520]: Starting Sockets.
-- Subject: Unit UNIT has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has begun starting up.
lut 24 14:06:15 raspberrypi systemd[520]: Reached target Sockets.
-- Subject: Unit UNIT has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[520]: Starting Basic System.
-- Subject: Unit UNIT has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has begun starting up.
lut 24 14:06:15 raspberrypi systemd[520]: Reached target Basic System.
-- Subject: Unit UNIT has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[520]: Starting Default.
-- Subject: Unit UNIT has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has begun starting up.
lut 24 14:06:15 raspberrypi systemd[520]: Reached target Default.
-- Subject: Unit UNIT has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit UNIT has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[520]: Startup finished in 66ms.
-- Subject: System start-up is now complete
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- All system services necessary queued for starting at boot have been
-- successfully started. Note that this does not mean that the machine is
-- now idle as services might still be busy with completing start-up.
--
-- Kernel start-up required KERNEL_USEC microseconds.
--
-- Initial RAM disk start-up required INITRD_USEC microseconds.
--
-- Userspace start-up required 66978 microseconds.
lut 24 14:06:15 raspberrypi systemd[1]: Got notification message for unit [email protected]
lut 24 14:06:15 raspberrypi systemd[1]: [email protected]: Got notification message from PID 520 (READY=1...)
lut 24 14:06:15 raspberrypi systemd[1]: [email protected]: got READY=1
lut 24 14:06:15 raspberrypi systemd[1]: [email protected] changed start -> running
lut 24 14:06:15 raspberrypi systemd[1]: Job [email protected]/start finished, result=done
lut 24 14:06:15 raspberrypi systemd[1]: Started User Manager for UID 1000.
-- Subject: Unit [email protected] has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit [email protected] has finished starting up.
--
-- The start-up result is done.
lut 24 14:06:15 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=JobRemoved cookie=109 reply_cookie=0 error=n/a
lut 24 14:06:15 raspberrypi systemd[1]: Sent message type=method_call sender=n/a destination=org.freedesktop.DBus object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=RemoveMatch cookie=110 reply_cookie=0 error=n/a
lut 24 14:06:15 raspberrypi systemd[1]: [email protected]: got STATUS=Startup finished in 66ms.
lut 24 14:06:15 raspberrypi systemd[1]: Got notification message for unit [email protected]
lut 24 14:06:15 raspberrypi systemd[1]: [email protected]: got STATUS=Startup finished in 66ms.
lut 24 14:06:15 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/user_401000_2eservice interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=111 reply_cookie=0 error=n/a
lut 24 14:06:15 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/user_401000_2eservice interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=112 reply_cookie=0 error=n/a
lut 24 14:06:15 raspberrypi systemd[1]: [email protected]: Got notification message from PID 520 (READY=1...)
lut 24 14:06:16 raspberrypi dhcpcd[415]: eth0: carrier acquired
lut 24 14:06:16 raspberrypi kernel: IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
lut 24 14:06:16 raspberrypi kernel: smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0x45E1
lut 24 14:06:16 raspberrypi dhcpcd[415]: DUID 00:01:00:01:1e:4c:e0:00:b8:27:eb:8e:4a:e3
lut 24 14:06:16 raspberrypi dhcpcd[415]: eth0: IAID eb:8e:4a:e3
lut 24 14:06:16 raspberrypi ntpd_intres[512]: host name not found: 0.debian.pool.ntp.org
lut 24 14:06:16 raspberrypi ntpd_intres[512]: host name not found: 1.debian.pool.ntp.org
lut 24 14:06:16 raspberrypi ntpd_intres[512]: host name not found: 2.debian.pool.ntp.org
lut 24 14:06:16 raspberrypi ntpd_intres[512]: host name not found: 3.debian.pool.ntp.org
lut 24 14:06:16 raspberrypi dhcpcd[415]: eth0: using static address 192.168.0.79/24
lut 24 14:06:16 raspberrypi dhcpcd[415]: eth0: adding route to 192.168.0.0/24
lut 24 14:06:16 raspberrypi dhcpcd[415]: eth0: adding default route via 192.168.0.222
lut 24 14:06:16 raspberrypi avahi-daemon[400]: Joining mDNS multicast group on interface eth0.IPv4 with address 192.168.0.79.
lut 24 14:06:16 raspberrypi avahi-daemon[400]: New relevant interface eth0.IPv4 for mDNS.
lut 24 14:06:16 raspberrypi avahi-daemon[400]: Registering new address record for 192.168.0.79 on eth0.IPv4.
lut 24 14:06:16 raspberrypi systemd[1]: Accepted new private connection.
lut 24 14:06:16 raspberrypi systemd[1]: Got message type=method_call sender=n/a destination=org.freedesktop.systemd1 object=/org/freedesktop/systemd1/unit/nscd_2eservice interface=org.freedesktop.DBus.Properties member=GetAll cookie=1 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Failed to load configuration for nscd.service: No such file or directory
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=method_return sender=n/a destination=n/a object=n/a interface=n/a member=n/a cookie=1 reply_cookie=1 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Collecting nscd.service
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=2 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=113 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=3 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=114 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Got disconnect on private connection.
lut 24 14:06:16 raspberrypi systemd[1]: Accepted new private connection.
lut 24 14:06:16 raspberrypi systemd[1]: Got message type=method_call sender=n/a destination=org.freedesktop.systemd1 object=/org/freedesktop/systemd1/unit/unbound_2eservice interface=org.freedesktop.DBus.Properties member=GetAll cookie=1 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Failed to load configuration for unbound.service: No such file or directory
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=method_return sender=n/a destination=n/a object=n/a interface=n/a member=n/a cookie=1 reply_cookie=1 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Collecting unbound.service
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=2 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=115 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=3 reply_cookie=0 error=n/a
lut 24 14:06:16 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=116 reply_cookie=0 error=n/a
lut 24 14:06:17 raspberrypi systemd[1]: Got disconnect on private connection.
lut 24 14:06:17 raspberrypi dhcpcd[415]: eth0: soliciting an IPv6 router
lut 24 14:06:19 raspberrypi ntpd[506]: Listen normally on 4 eth0 192.168.0.79 UDP 123
lut 24 14:06:19 raspberrypi ntpd[506]: Listen normally on 5 eth0 fe80::ba27:ebff:fe8e:4ae3 UDP 123
lut 24 14:06:19 raspberrypi ntpd[506]: peers refreshed
lut 24 14:06:21 raspberrypi ntpd_intres[512]: DNS 0.debian.pool.ntp.org -> 94.154.96.7
lut 24 14:06:21 raspberrypi ntpd_intres[512]: DNS 1.debian.pool.ntp.org -> 195.46.37.22
lut 24 14:06:21 raspberrypi ntpd_intres[512]: DNS 2.debian.pool.ntp.org -> 193.106.216.30
lut 24 14:06:21 raspberrypi ntpd_intres[512]: DNS 3.debian.pool.ntp.org -> 194.177.4.2
lut 25 13:26:13 raspberrypi systemd[1]: Time has been changed
-- Subject: Time change
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The system clock has been changed to REALTIME microseconds after January 1st, 1970.
lut 25 13:26:13 raspberrypi systemd[520]: Time has been changed
-- Subject: Time change
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The system clock has been changed to REALTIME microseconds after January 1st, 1970.
lut 25 13:26:13 raspberrypi systemd[1]: Set up TFD_TIMER_CANCEL_ON_SET timerfd.
lut 25 13:26:13 raspberrypi systemd[1]: systemd-tmpfiles-clean.timer: time change, recalculating next elapse.
lut 25 13:26:13 raspberrypi systemd[1]: systemd-tmpfiles-clean.timer: Monotonic timer elapses in 14min 26.563229s.
lut 25 13:26:13 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/systemd_2dtmpfiles_2dclean_2etimer interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=117 reply_cookie=0 error=n/a
lut 25 13:26:13 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/systemd_2dtmpfiles_2dclean_2etimer interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=118 reply_cookie=0 error=n/a
lut 25 13:26:13 raspberrypi systemd[1]: Got notification message for unit systemd-journald.service
lut 25 13:26:13 raspberrypi systemd[1]: systemd-journald.service: Got notification message from PID 105 (WATCHDOG=1...)
lut 25 13:26:13 raspberrypi systemd[1]: systemd-journald.service: got WATCHDOG=1
lut 25 13:26:13 raspberrypi systemd[1]: Got notification message for unit systemd-journald.service
lut 25 13:26:13 raspberrypi systemd[1]: systemd-journald.service: Got notification message from PID 105 (WATCHDOG=1...)
lut 25 13:26:13 raspberrypi systemd-journal[105]: Forwarding to syslog missed 159 messages.
-- Subject: One or more messages could not be forwarded to syslog
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- One or more messages could not be forwarded to the syslog service
-- running side-by-side with journald. This usually indicates that the
-- syslog implementation has not been able to keep up with the speed of
-- messages queued.
lut 25 13:26:13 raspberrypi systemd[1]: systemd-journald.service: got WATCHDOG=1
lut 25 13:26:14 raspberrypi dhcpcd[415]: eth0: no IPv6 Routers available
lut 25 13:26:33 raspberrypi systemd[1]: Got notification message for unit systemd-logind.service
lut 25 13:26:33 raspberrypi systemd[1]: systemd-logind.service: Got notification message from PID 396 (WATCHDOG=1...)
lut 25 13:26:33 raspberrypi systemd[1]: systemd-logind.service: got WATCHDOG=1
lut 25 13:26:33 raspberrypi systemd[1]: Got notification message for unit systemd-logind.service
lut 25 13:26:33 raspberrypi systemd[1]: systemd-logind.service: Got notification message from PID 396 (WATCHDOG=1...)
[...lots of these...]
lut 25 13:32:30 raspberrypi systemd[1]: systemd-logind.service: Got notification message from PID 396 (WATCHDOG=1...)
lut 25 13:32:30 raspberrypi systemd[1]: systemd-logind.service: got WATCHDOG=1
lut 25 13:32:30 raspberrypi systemd[1]: Got message type=method_call sender=:1.1 destination=org.freedesktop.systemd1 object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=StartTransientUnit cookie=27 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=method_call sender=n/a destination=org.freedesktop.DBus object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=GetConnectionUnixUser cookie=119 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Failed to load configuration for session-c2.scope: No such file or directory
lut 25 13:32:30 raspberrypi systemd[1]: Trying to enqueue job session-c2.scope/start/fail
lut 25 13:32:30 raspberrypi systemd[1]: Installed new job session-c2.scope/start as 194
lut 25 13:32:30 raspberrypi systemd[1]: Enqueued job session-c2.scope/start as 194
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=method_call sender=n/a destination=org.freedesktop.DBus object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=AddMatch cookie=120 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=method_return sender=n/a destination=:1.1 object=n/a interface=n/a member=n/a cookie=122 reply_cookie=27 error=n/a
lut 25 13:32:30 raspberrypi systemd-logind[396]: New session c2 of user pi.
-- Subject: A new session c2 has been created for user pi
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- Documentation: http://www.freedesktop.org/wiki/Software/systemd/multiseat
--
-- A new session with the ID c2 has been created for the user pi.
--
-- The leading process of the session is 632.
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=123 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=JobNew cookie=124 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Starting Session c2 of user pi.
-- Subject: Unit session-c2.scope has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit session-c2.scope has begun starting up.
lut 25 13:32:30 raspberrypi systemd[1]: session-c2.scope changed dead -> running
lut 25 13:32:30 raspberrypi systemd[1]: Job session-c2.scope/start finished, result=done
lut 25 13:32:30 raspberrypi systemd[1]: Started Session c2 of user pi.
-- Subject: Unit session-c2.scope has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit session-c2.scope has finished starting up.
--
-- The start-up result is done.
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=method_call sender=n/a destination=org.freedesktop.DBus object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=RemoveMatch cookie=126 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/session_2dc2_2escope interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=127 reply_cookie=0 error=n/a
lut 25 13:32:30 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1/unit/session_2dc2_2escope interface=org.freedesktop.DBus.Properties member=PropertiesChanged cookie=128 reply_cookie=0 error=n/a
lut 25 13:32:31 raspberrypi systemd[1]: Sent message type=method_call sender=n/a destination=org.freedesktop.DBus object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=GetNameOwner cookie=121 reply_cookie=0 error=n/a
lut 25 13:32:31 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=JobRemoved cookie=125 reply_cookie=0 error=n/a
lut 25 13:32:33 raspberrypi sudo[657]: pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/su
lut 25 13:32:33 raspberrypi sudo[657]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
lut 25 13:32:33 raspberrypi su[664]: Successful su for root by root
lut 25 13:32:33 raspberrypi su[664]: + /dev/pts/0 root:root
lut 25 13:32:33 raspberrypi su[664]: pam_unix(su:session): session opened for user root by pi(uid=0)
lut 25 13:32:33 raspberrypi systemd[1]: Got message type=signal sender=org.freedesktop.DBus destination=n/a object=/org/freedesktop/DBus interface=org.freedesktop.DBus member=NameOwnerChanged cookie=31 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Accepted new private connection.
lut 25 13:32:45 raspberrypi systemd[1]: Got message type=method_call sender=n/a destination=org.freedesktop.systemd1 object=/org/freedesktop/systemd1/unit/chromium_2eservice interface=org.freedesktop.DBus.Properties member=GetAll cookie=1 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Looking for unit files in (higher priority first):
lut 25 13:32:45 raspberrypi systemd[1]: /etc/systemd/system
lut 25 13:32:45 raspberrypi systemd[1]: /run/systemd/system
lut 25 13:32:45 raspberrypi systemd[1]: /usr/local/lib/systemd/system
lut 25 13:32:45 raspberrypi systemd[1]: /lib/systemd/system
lut 25 13:32:45 raspberrypi systemd[1]: /usr/lib/systemd/system
lut 25 13:32:45 raspberrypi systemd[1]: Looking for SysV init scripts in:
lut 25 13:32:45 raspberrypi systemd[1]: /etc/init.d
lut 25 13:32:45 raspberrypi systemd[1]: Looking for SysV rcN.d links in:
lut 25 13:32:45 raspberrypi systemd[1]: /etc
lut 25 13:32:45 raspberrypi systemd[1]: Sent message type=method_return sender=n/a destination=n/a object=n/a interface=n/a member=n/a cookie=1 reply_cookie=1 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Collecting chromium.service
lut 25 13:32:45 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=2 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitNew cookie=129 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=3 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Sent message type=signal sender=n/a destination=n/a object=/org/freedesktop/systemd1 interface=org.freedesktop.systemd1.Manager member=UnitRemoved cookie=130 reply_cookie=0 error=n/a
lut 25 13:32:45 raspberrypi systemd[1]: Got disconnect on private connection.
lut 25 13:33:13 raspberrypi systemd[1]: Got notification message for unit systemd-journald.service
lut 25 13:33:13 raspberrypi systemd[1]: systemd-journald.service: Got notification message from PID 105 (WATCHDOG=1...)
lut 25 13:33:13 raspberrypi systemd[1]: systemd-journald.service: got WATCHDOG=1
lut 25 13:33:13 raspberrypi systemd[1]: Got notification message for unit systemd-journald.service
lut 25 13:33:13 raspberrypi systemd[1]: systemd-journald.service: Got notification message from PID 105 (WATCHDOG=1...)
lut 25 13:33:13 raspberrypi systemd[1]: systemd-journald.service: got WATCHDOG=1
답변1
더 많은 정보를 얻기 위해 로깅의 자세한 정도를 높이겠습니다. 그런 다음 로그 파일에서 chromium을 찾아 적절한 스니펫을 보여주세요.
세부 수준을 높이기 위해,/etc/systemd/system.conf
LogLevel=debug <--- Uncomment this line and use "debug" (default: commented and "info")
After=
배선이 잘못된 것 같은데요 ? 현재 구성에서는 크롬이 getty 이후에 시작되지만 먼저 그래픽 시스템을 통해 활성화되는 것으로 표시됩니다(설치 읽기).
그래픽 시스템이 부팅된 후 chromium이 시작되기를 원합니다(실제로 chromium은필요하다그래픽 시스템이므로 라인 Requires=
뒤에)를 추가하는 것이 좋으며 After=
대상은 및 라인이 getty.target
아니 어야 합니다 .graphical.target
After=
Requires=
로그의 자세한 정보를 늘리면 이 사실이 드러날 것입니다. 나는 당신이 시도하는 것을 시도하지 않았으므로 이것은 매뉴얼에 대한 나의 해석을 바탕으로 한 순전히 이론적 조언입니다.
에필로그, Install=
수동으로 시작하면(그래픽 시스템이 시작된 후) 잘 작동한다고 해서 작동하는 것 같습니다.
답변2
사용자 정의 서비스를 스크립트로 생성
/etc/rc.d/rc.local 파일을 엽니다.
파일 줄 끝에 있는 스크립트 파일 위치를 가리킵니다(예: sh /{파일 경로}/{파일 이름}.sh).
/etc/rc.d/rc.local 및 /{파일 경로}/{filename}.sh에는 실행 권한이 있어야 함을 기억하세요.
참고: Linux 시스템은 /etc/rc.d/rc.local을 사용하여 마지막 순간의 사용자 정의 스크립트를 실행합니다.