Linux services: is there a GUI for services?

12

0

I am looking for a GUI program, that shows running services from /etc/init.d (and /etc/init), and allows to manage (start / stop / runlevel) them. What can you recommend?

Background: even though I like working with the command line, this could ease things a bit on a test machine dedicated for trying out different services, so that you can see what is running and what not. For example: tomcat 5.5, tomcat 6, tomcat 7 on one machine for testing ... add two RDBMS in some versions, Apache httpd, ...

Last but not least: some CLI tool with decent ncurses menu will do as well.

pwn4g3

Posted 2010-08-03T19:21:24.477

Reputation: 195

Answers

5

Try sysv-rc-conf to alter the runlevel settings.

and chkconfig to see what's running

Don't forget that ubuntu (and others?) are starting to use the Upstart Startup Manager, so you'll have to keep an eye on the /etc/init directory too

bryan

Posted 2010-08-03T19:21:24.477

Reputation: 7 848

4

Old thread, but yes now there is! Check out the systemd-manager

Systemd Manager

This application is a systemd service manager written in the Rust programming language with GTK3 as the graphical user interface of choice. The units are filtered into three separate lists: services, sockets, and timers. As a unit is selected in the left pane, the right pane is updated with information pertaining to that unit, and the right headerbar is updated to reflect the status of the unit where you may disable/enable and start/stop the selected unit. Services are units that are activated immediately, sockets are units that are activated when they are needed, and timers are units that activate on a regular time interval. In addition to display units, the application also provides stats generated by systemd-analyze on the Systemd Analyze view.

vejiwavi

Posted 2010-08-03T19:21:24.477

Reputation: 41

Welcome to Super User! On this Q&A site we value answers. Hyperlinks alone tend to point toward an answer without actually being one. Please edit your answer so that it includes the essential elements from your linked source.

– I say Reinstate Monica – 2016-08-11T00:37:38.213

Or convert this into a comment instead – rogerdpack – 2016-08-17T15:46:25.177

Unfortunately, this repository does not exist anymore, and I cannot find any other GUI application doing that thing – Boiethios – 2019-06-08T16:57:48.207

This is the same repository. GuillaumeGomez/systemd-manager

– Animesh – 2020-01-16T07:13:07.637

2

On my Redhat (err, Centos) box:

curses: ntsysv

gui: system-config-services

On another note, remember to add the descriptive comment stanza to the top of your file. chkconfig and other tools (like ntsysv) read this.

Rich Homolka

Posted 2010-08-03T19:21:24.477

Reputation: 27 121

1

If you also consider a web alternative, I suggest you to have a look at webmin.

vtest

Posted 2010-08-03T19:21:24.477

Reputation: 4 424

Good suggestion but overkill – pwn4g3 – 2010-08-09T22:15:17.917

0

Once upon a time I wrote a zenity-GUI myself. In short words: It looks for files in init.d, greps for the case statements, and tries to guess what should be displayed on the fly.

Maybe it doesn't work well for all services, but for my work (cups, postgresql, ...) it's sufficient.

As a side note, it shows how to dynamically fit your window to screensize (maximum) and content size (width, length).

Here it is:

#!/bin/bash
#
# oetv.sh
# Show all servives in /etc/init.d in a list, and let the user choose how to start it.
#
# (c) 2008 Stefan Wagner, license GPLv3
# 
# Search /etc/init.d/ for all executable files
# Get their number, and the maximum name size to produce a fitting window

width=0
height=0

# The font will influence the optimal window size
# But I don't know how to get them. 
# Probably depending on windowmanager, desktop, usersettings 

function xyFromList 
{
    anz=0 
    wmax=0 
    for file in $1
    do 
        anz=$((anz+1))
        len=${#file}
        [ $len -gt $wmax ] && wmax=$len
    done;
    width=$((wmax*9+50))
    height=$((anz*26+160))
}

dienstlist=$(ls /etc/init.d/ )
xyFromList "$dienstlist"

dienst=$(zenity --width=$width --height=$height --list --text "Service schalten" --column "Dienst" $dienstlist)
[ "foo"$dienst == "foo" ] && exit

# select options for the service, and display an apropriate window

optionen=$(egrep -h "[a-z]+\)" /etc/init.d/$dienst | sed 's/^[ \t]*//;s/).*/)/;s/#.*//;s/)//g;s/|/ /g' | sort -u)
xyFromList "$optionen"
aktion=$(zenity --width=$width --height=$height --list --text "Service schalten" --column "Befehl" $optionen)
[ "foo"$aktion == "foo" ] && exit
result=$(gksudo /etc/init.d/$dienst $aktion)
zenity --info "$aktion" --text "$result"

user unknown

Posted 2010-08-03T19:21:24.477

Reputation: 1 623