DebianNet(3pm)
π DebianNet π
okay bestie, so this is DebianNet(3pm) from the dpkg suite β a lil Perl module that lets you β¨create, remove, enable or disable entries in /etc/inetd.confβ¨. yes THE inetd.conf. we're doing sysadmin stuff today and we're gonna slay it π«Ά
β¨ NAME β¨
DebianNet β create, remove, enable or disable entry in /etc/inetd.conf.
πΈ DESCRIPTION πΈ
so like, the whole vibe of this module is: you get a bunch of functions in DebianNet and you use them to add, remove, enable or disable entries in the /etc/inetd.conf file. that's it. that's the job π
and the way that it's so considerate?? after /etc/inetd.conf gets changed, a SIGHUP signal is sent to the inetd process to make sure inetd actually picks up the new /etc/inetd.conf file. no cap, it tells inetd to re-read. iconic behavior honestly π
the functions can also be used to add entries that are commented out by default. those get treated like normal entries β same energy, same rules. but (and this is the important part, bestie, listen) that also means: if you already have an entry that's commented out, you can't add an entry for the same service without removing the old one first. no sneaky duplicates. periodt.
also, a lil detail that matters: DebianNet treats entries that are commented out by a single '#' character as entries that have been commented out by a user. and it will not change such entries. hands off. respect the user's choices π
for shell scripts you can also use the update-inetd command. see update-inetd(8) for further information. iykyk π
π VARIABLES π
$DebianNet::INETD_CONFβ contains a scalar filename to use as the inetd config file (e.g. for testing purposes).- Defaults to
/etc/inetd.conf.
- Defaults to
$DebianNet::SEPβ contains the entry comment characters. this is only necessary if you have to deal with two (or more) services of the same name. like, only then, bestie.- Defaults to
"#<off># "as the comment characters.
- Defaults to
$DebianNet::MULTIβ contains a boolean that decides whether to disable/remove more than one entry at a time. if you try to remove more than one entry at a time without using this option, the program will show a warning and will ask the user whether to continue. it's giving "are you SURE bestie" energy π- Defaults to false.
$DebianNet::VERBOSEβ contains a boolean to select whether to explain verbosely what is being done. she's chatty, she tells you everything π¬- Defaults to false.
π FUNCTIONS π
$rc = DebianNet::add_service($newentry, $group)β add$newentryto the group$groupof the/etc/inetd.conffile. if the entry already exists it will be enabled (it will also detect entries with different program options β she's observant like that). using$groupis optional (the default group is the groupOTHER). if the group does not exist, the entry will be placed at the end of the file.- Returns
1on success, and-1on failure. this function might callexit()due to debconf prompt answers. β οΈ yes fr fr, it can just dip out on you because of a debconf prompt.
- Returns
$rc = DebianNet::remove_service($entry)β remove$entryfrom/etc/inetd.conf. you can use a regular expression to remove the entry. regex girlies rise π§- Returns
1on success, and-1on failure.
- Returns
$rc = DebianNet::disable_service($service, $pattern)β disable$service(e.g."ftp") in/etc/inetd.conf. using$patternis optional (seeenable_service()).- Returns
1on success, and-1on failure.
- Returns
$rc = DebianNet::enable_service($service, $pattern)β enable$service(e.g."ftp") in/etc/inetd.conf. using$patternis optional. it can be used to select a service. you only need this option if you have two (or more) services of the same name.- an example, because examples are everything: you have three ftp entries in the
/etc/inetd.conffile (all disabled by default) and you want to enable the entry which uses thevsftpddaemon. to do this, use the pattern"vsftpd"(or any other regular expression that matches this entry). - Returns
1on success, and-1on failure.
- an example, because examples are everything: you have three ftp entries in the
β CHANGES β
π Version 1.13
- New variables:
$VERSION,$VERBOSE,$MULTI,$SEP,$INETD_CONF. - Deprecated variables:
$version,$verbose,$multi,$sep,$inetdcf.
lowkey a glow-up era. out with the lowercase, in with the SCREAMING. deprecated doesn't mean deleted tho, so don't come for me π
and that's the whole page bestie!! this beauty is version 4.54build1, dated 2026-02-02 πΈ go forth and manage your inetd.conf with main character energy, you absolute icon π
β¨π
π¦ where this page comes from
- ubuntu resolute: update-inetd 4.54build1
- ubuntu stonking: update-inetd 4.54build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms