Hi ChenQi, Thanks for the help, I tried following service, it did not work, the systemd complains bad unit
[Unit] Description=Application Shutdown Service Before=multi-user.target [Service] Type=oneshot ExecStart= ExecStop=/usr/sbin/app_cleanup.sh [Install] WantedBy=multi-user.target >> Most of the services are started in boot, how can I have create a >> service only to be active in shutdown (not in boot) to clean up? >> >> Thank you. >> >> Kind regards, >> >> - jh > > Make use of ExecStop, leave ExecStart to be empty. I tried it: [Unit] Description=Application Shutdown Service Before=multi-user.target [Service] Type=oneshot ExecStart= ExecStop=/usr/sbin/app_cleanup.sh [Install] WantedBy=multi-user.target There were errors: Loaded: bad-setting (Reason: Unit myclean.service has a bad unit file set) What I could be missing here? Thank you very much. Kind regards, - jh -- _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto