Sponsored Content
Top Forums UNIX for Advanced & Expert Users How to create custom options of my own in systemctl Linux? Post 303036687 by Neo on Monday 8th of July 2019 06:42:03 AM
Old 07-08-2019
Ravinder,

If it was me, I would download the source code from github and search the source for these kinds of tokens, for example: start/stop/restart and try to find out where in the code these options are processed.

Then, you might find that it's not too difficult of a task to add a custom option to systemd by writing some code and recompiling your custom version of systemd. You might be able to link your new code in dynamically as a "ravinder" module.

The best way to do this, of course, is to fork the systemd code into your own github account, so you can track the changes and perhaps if your changes are interesting to others, they can download from your github page(s) as well. VSC has all the hooks you need to track all changes and manage all version control in the appropriate programming language (I assume C or C++, but have not checked).

I've not looked at the code, but I think it's a viable approach if you want to customize systemd, obviously you will need to modify the source, track changes, etc. and all the source is available.

It's just a matter of "doing it"... after doing your homework a bit more and deciding on where in the architecture to add your custom code.
This User Gave Thanks to Neo For This Post:
 

6 More Discussions You Might Find Interesting

1. AIX

how to create custom fortunes.dat

How do I create my own custom fortunes.dat on aix? (0 Replies)
Discussion started by: techuser
0 Replies

2. Programming

How to create a custom GUI

In Unix, is there any way in which I can create a GUI like Realplayer? I mean the Windows Look & Feel. Borded with buttons, windows, dialogs and other predefined widgets, I am wondering how to create my own buttons that come in different shapes and fashions or even draw images/control objects... (2 Replies)
Discussion started by: hirosima
2 Replies

3. Solaris

Create a custom CD boot

I'm doing as the official document of the SUN : www.sun.com/blueprints/1205/819-3731.pdf Who on page 15 / 18, asks to be executed the following command: 3.Combine mboot and pboot into a single file called mboot+pboot.cd. # dd if=/dev/dsk/c1t1d0p0 of=mboot+pboot.cd bs=512 count=2 I try... (6 Replies)
Discussion started by: poyato
6 Replies

4. Infrastructure Monitoring

Nagios widgets to create custom GUI

Hi, I need to create a custom GUI for Nagios, as follows: - no logo - including monitoring info (network status overview, host/service details & status) as well as some network google map I'm looking for Nagios widgets that can be easily integrated in our HTML page. Can you suggest if there... (0 Replies)
Discussion started by: CHK
0 Replies

5. UNIX for Advanced & Expert Users

Creating a Custom ISO with Options

Here is the scenario: At work I have been ask to create a custom ISO using UBUNTU as the chosen distro, install our prerequisted packages and present the customer with a choice of options of enabling and disabling services and just in general custom choices that I want to present to the user... (2 Replies)
Discussion started by: metallica1973
2 Replies

6. UNIX for Dummies Questions & Answers

How to create a TAR File in a Custom Destination Directory?

I want to create the tarzip file into a destination directory, i am in /var/sftp/home/archive/rquadri directory and i am using below command. However it is creating the file in the /var/sftp/home/archive/rquadri directory itself instead of /tmp, may i please know how do i resolve this. tar -cvzf... (5 Replies)
Discussion started by: Ariean
5 Replies
SYSTEMD-NETWORKD.SERVICE(8)				     systemd-networkd.service				       SYSTEMD-NETWORKD.SERVICE(8)

NAME
systemd-networkd.service, systemd-networkd - Network manager SYNOPSIS
systemd-networkd.service /lib/systemd/systemd-networkd DESCRIPTION
systemd-networkd is a system service that manages networks. It detects and configures network devices as they appear, as well as creating virtual network devices. To configure low-level link settings independently of networks, see systemd.link(5). systemd-networkd will create network devices based on the configuration in systemd.netdev(5) files, respecting the [Match] sections in those files. systemd-networkd will manage network addresses and routes for any link for which it finds a .network file with an appropriate [Match] section, see systemd.network(5). For those links, it will flush existing network addresses and routes when bringing up the device. Any links not matched by one of the .network files will be ignored. It is also possible to explicitly tell systemd-networkd to ignore a link by using Unmanaged=yes option, see systemd.network(5). When systemd-networkd exits, it generally leaves existing network devices and configuration intact. This makes it possible to transition from the initrams and to restart the service without breaking connectivity. This also means that when configuration is updated and systemd-networkd is restarted, netdev interfaces for which configuration was removed will not be dropped, and may need to be cleaned up manually. CONFIGURATION FILES
The configuration files are read from the files located in the system network directory /lib/systemd/network, the volatile runtime network directory /run/systemd/network and the local administration network directory /etc/systemd/network. Networks are configured in .network files, see systemd.network(5), and virtual network devices are configured in .netdev files, see systemd.netdev(5). SEE ALSO
systemd(1), systemd.link(5), systemd.network(5), systemd.netdev(5), systemd-networkd-wait-online.service(8) systemd 237 SYSTEMD-NETWORKD.SERVICE(8)
All times are GMT -4. The time now is 10:52 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy