1      Scope of Document

systemd 是一个 Linux 系统基础组件的集合,提供了一个系统和服务管理器,运行为 PID 1 并负责启动其它程序。功能包括:支持并行化任务;同时采用 socket 式与 D-Bus 总线式激活服务;按需启动守护进程(daemon);利用 Linux 的 cgroups 监视进程;支持快照和系统恢复;维护挂载点和自动挂载点;各服务间基于依赖关系进行精密控制。systemd 支持 SysV 和 LSB 初始脚本,可以替代 sysvinit。除此之外,功能还包括日志进程、控制基础系统配置,维护登陆用户列表以及系统账户、运行时目录和设置,可以运行容器和虚拟机,可以简单的管理网络配置、网络时间同步、日志转发和名称解析等。

与多数发行版使用的System V风格init相比,systemd采用了以下新技术: (1) 采用Socket激活式与总线激活式服务,以提高相互依赖的各服务的并行运行性能; (2) 用Cgroups代替PID来追踪进程,以此即使是两次fork之后生成的守护进程也不会脱离systemd的控制。

1.1     Function Requirement

Learning systemd script, and write related systemd scirpt , example gps.service/4g.service.

2      Hardware Overview

NA

3      Functional Description

3.1     Functional Block Diagram

NA

4      Demo

4.1     4g script using systemd

[Unit]

Description=IoTP 4G Service (one-shot 4g mode)

Before=ntpd.service

[Service]

Type=oneshot

ExecStart=

ExecStart=/bin/4g-lunch

RemainAfterExit=yes

[Install]

WantedBy=multi-user.target

4.2     Gps script using systemd

[Unit]

Description=IoTP GPS Service (one-shot mode)

Before=ntpd.service

[Service]

Type=oneshot

ExecStart=

ExecStart=/bin/gps-lunch

RemainAfterExit=yes

[Install]

WantedBy=multi-user.target

5      Boot log

Starting IoTP 4G Service (one-shot 4g mode)...

[  OK  ] Started IoTP 4G Service (one-shot 4g mode).

Starting IoTP GPS Service (one-shot mode)...

[  OK  ] Started IoTP GPS Service (one-shot mode).

Basic command:

systemctl enable 4g.service

systemctl disable 4g.service

systemctl status 4g.service

am335x system upgrade rootfs custom service using systemd script(十七)的更多相关文章

  1. am335x system upgrade rootfs using yocto make rootfs(十二)

    1      Scope of Document This document describes how to make am335x arago rootfs using ycoto project ...

  2. am335x system upgrade rootfs for bridge-utils cross compile (十四)

    bridge-utils移植 [目的] 移植bridge-utils的目是在AM335X开发板上使用bridge功能. [环境] 1.  Ubuntu 16.04发行版 2.  MC183平台 3.  ...

  3. am335x system upgrade rootfs for dhcpcd cross compile(十三)

    dhcpcd移植 [目的] 移植dhcpcd的目是在AM335X开发板上使用dhcp功能,获取WAN口设备的IP,并且可以通过参数指定其matric,matric值越小,其优先级越高.如设备可以以太网 ...

  4. am335x system upgrade set/get current cpufreq(二十一)

    1      Scope of Document This document describes am335x cpufreq technology insider. 2      Requireme ...

  5. am335x system upgrade kernel tf(五)

    1      Scope of Document This document describes TF hardware design 2      Requiremen 2.1     Functi ...

  6. am335x system upgrade uboot nand boot(三)

    在uboot 下初始化nand,一般需要做如下工作: 第一: 配置默认从NAND boot Index: include/configs/am335x_evm.h=================== ...

  7. am335x system upgrade uboot ethernet(二)

    系统可以通过SD卡引道之后,为了之后了调试方便 通过查看网卡的硬件设计 正常来说需要注意的有如下几点: 1) 网口 的接线方式: RMII 2) 网口的PHY地址两张网口,这里我们只需先初始化一张网卡 ...

  8. am335x system upgrade kernel ethernet(四)

    1      Scope of Document This document describes ethernet hardware design and porting KZS8081 to ubo ...

  9. am335x system upgrade kernel gpio(九)

    1      Hardware Overview gpio interface,pin map: AM335X_I2C0_W_C----------------------MCASP0_AXR1 /* ...

随机推荐

  1. docker学习笔记(一)--介绍和基本组成

    Docker基本介绍 1.什么是docker docker本身不是容器,是创建容器的工具,是应用容器引擎,将应用程序自动部署到容器的开源引擎. 2.docker的目标特点 简单轻量,快速开发,具备可移 ...

  2. PowerBuilder学习笔记之打开Expressino属性页

  3. javascript:void(0);的含义以及使用场景

    一.含义: javascript:是伪协议,表示内容通过javascript执行. void(0)表示不作任何操作. 二.使用场景 1.href=”javascript:void(0);” 作用:为了 ...

  4. windows + Eclipse

    https://www.eclipse.org/downloads/index-packages.php 下载好后是一个压缩文件,解压并放到相要存放软件的目录,双击打开解压后的目录下eclipse.e ...

  5. Linux Wireless Supported Devices

    Linux Wireless Supported Devices https://ark.intel.com/content/www/us/en/ark/products/series/59484/i ...

  6. linux驱动开发随手记【1】

    1.一个patch只完成一项任务 2.用vim编辑多个文件,想同时关闭所有文件时候,可以用 :qall 命令 .vim用户手册08 3.mmc dev 0.mmc为U-boot命令,这句话的含义是设置 ...

  7. 【SpringMVC】RESTful支持

    一.概述 1.1 什么是RESTful 1.2 URL的RESTful实现 二.演示 2.1 需求 2.2 第一步更改DispatcherServlet配置 2.3 第二步参数通过url传递 2.4 ...

  8. Python 虚拟空间的使用

    使用虚拟环境, 可以将当前项目所使用的依赖与电脑中其他 Python 项目的依赖区分开, 避免依赖版本不匹配带来的问题, 同时也可以防止项目依赖被不当更新. mkdir myproject cd my ...

  9. Mycat学习-单独启动mycat

    Mycat下载地址:http://mycat.io/ Mycat安装:解压缩即可.   Mycat作为一个中间件,实现mysql协议,是可以不依赖数据库单独运行的. 对前端应用连接来说就是一个数据库, ...

  10. Python函数Day1

    一.函数的初识 函数的定义:函数最主要的目的是封装一个功能,一个函数就是一个功能 定义函数的格式: def 函数名(): 函数体 def my_len(): count = 0 s1 = 'hahah ...