Use gkDebconf to reconfigure debconf-using programs

Jack Wallen
Dec 16, 2010
Updated • Jan 16, 2013
Linux
|
1

There are certain applications, such as MySQL and Apache that are configured upon installation. The most familiar to you might be MySQL. At the point of installation you configure the server address, admin password, etc. But what happens when you need to reconfigure that tool and you don't want to go through the process of unistalling/reinstalling? Fortunately there is a tool to handle that task. That tool is dpkg-reconfigure. Of course this tool is a command line tool and many newer users do not want to bother with commands.

For those users who do not want to bother with commands, but still need to re-configure certain packages, there is a front end called gkDebconf that can be used to easily reconfigure those already installed packages. Let's see how to install and use this tool.

Installation

Since gkDebconf is found in the standard repositories, installation is very simple. Just follow these steps:

  1. Open up the Ubuntu Software Center.
  2. Search for "gkdebconf" (No quotes).
  3. Click the Install button.
  4. Enter your sudo password when prompted.
  5. When the installation is complete, close the Software Center.

Once installed, you will find the application in System > Administration > gkDebconf.

Usage

Figure 1

One of the problems with starting the tool from the menu is that it will not ask you for your sudo password, therefore you will not have administrative access. For some of the package re-configuration (such as MySQL) you must have admin access. So if you are reconfiguring a package that you know requires admin access, start gkDebconf from the command line. To do this open up a terminal window and issue the command sudo gkdebconf. When this command is issued the main window for gkDebconf will open (see Figure 1) where you can locate the package you want to reconfigure.

As you can see there are numerous packages available to you. I am illustrating the MySQl-server package as that is the package that I get the most questions regarding re-configuring.

Figure 1

So to run the re-configuration process select the package you want to reconfigure and click the Configure button. When you do this a new window will open, that window being the debconf configuration window for the package in question (see Figure 2). In my example you can see the first step is asking you for the MySQL root user password. If you have already installed this package, you will have already walked through this wizard so it will be very familiar.

Some of the more important applications you can reconfigure include:

  • adduser
  • apparmor
  • cups
  • gdm
  • openssh-server
  • quota
  • Samba
  • Snort

For those who would like to to do this same task from the command line, you can use the dpkg-reconfigure like so:

sudo dpkg-reconfigure APPLICATION

Where APPLICATION is the package you want to reconfigure. So if you want to reconfigure Samba you would issue the command:

sudo dpkg-reconfigure samba

Final thoughts

Although the task isn't too challenging to handle from the command line, it's always nice to not have to guess the name of the package you want to configure (remember, Linux is very case-sensitive, so MySQL is not mysql). gkDebconf makes this task much easier.

Advertisement

Previous Post: «
Next Post: «

Comments

  1. Dotan Cohen said on December 17, 2010 at 10:46 am
    Reply

    Thanks, this is good to know.

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.