Rapid7

module

Service System V Persistence

Disclosed
Jan 1, 1983
Created
Oct 16, 2025

Description

This module will create a service via System V on the box, and mark it for auto-restart.
We need enough access to write service files and potentially restart services.

Some systems include backwards compatibility, such as Ubuntu up to about 16.04.

Targets:
CentOS
Debian
Kali 2.0
Ubuntu
Note: System V won't restart the service if it dies, only an init change (reboot etc) will restart it.

Verified on Kali 2.0, Ubuntu 10.04

Author

h00die

Platform

Linux,Unix

Architectures

cmd, x86, x64, armle, aarch64, ppc, mipsle, mipsbe

Module Options

To display the available options, load the module within the Metasploit console and run the commands 'show options' or 'show advanced':


msf > use exploit/linux/persistence/init_sysvinit
msf exploit(init_sysvinit) > show targets
...targets...
msf exploit(init_sysvinit) > set TARGET < target-id >
msf exploit(init_sysvinit) > show options
...show and set options...
msf exploit(init_sysvinit) > exploit

Title
Rapid7 Labs

2026 Global Threat Landscape Report

The predictive window has collapsed. Exploitation follows disclosure in days. See how attackers are accelerating and how to stay ahead.