Re: how to remove GUI
Hi there. On 11/09/2020 01.40, Michael Morgan wrote: I recently installed Debian 9.13 on my machine. I was planning to use it for scientific computation so GUI is not necessary. For some reason, I installed the desktop environment with LXDE desktop during installation. Later I decided to remove them. These two commands were executed: tasksel remove desktop apt purge $(tasksel --task-packages desktop) (...) If you don't mind, I see at least two options: 1 - see what packages you would like to have/need and reinstall from scratch, if you can afford a re-installation. 2 - if you don't want/can't reinstall, then I would install aptitude and use its interactive interface for selecting the packages that you need. I like option 2 and whenever I install any Debian system, that's one of the first packages that I install (and I completely ignore this tasks thing). I like my installs to be absolutely minimal at first (they will inevitably grow with time). That being said, the system where I am typing this right now has its filesystem timestamp indicating that it was created in 2011... Regards, Rogério Brito.
Re: how to remove GUI
On Vi, 11 sep 20, 10:35:46, David Wright wrote: > > I don't use a DE so I can't check. Who owns the X server nowadays > when running a DM? (With no DM running, ownership changed from root > to the user some time ago.) As far as I know it depends on the DM, e.g. with lightdm it's root, at least on buster. Kind regards, Andrei -- http://wiki.debian.org/FAQsFromDebianUser signature.asc Description: PGP signature
Re: how to remove GUI
On Fri, Sep 11, 2020 at 10:35:46AM -0500, David Wright wrote: > That's the first mention of this phenomenon I recall seeing since I posted > https://lists.debian.org/debian-user/2018/03/msg01030.html > (which dealt mainly with a more serious problem). > > I never install a DE/DM and all that stuff, but I get the cursor > movement nonetheless. Is that what you're saying? It's not as serious as what you reported in the 2018 thread. It's just an occasional glitch, not easily reproducible, with a trivial workaround. I only mention it because once in a while, someone sees something like it and freaks out, thinking the computer is locked up or whatever. They don't realize they can just hit the Enter key and get a fresh login prompt, and all is fine.
Re: how to remove GUI
On Fri 11 Sep 2020 at 10:35:19 (-0400), Greg Wooledge wrote: > On Fri, Sep 11, 2020 at 09:02:30AM -0400, Kenneth Parker wrote: > > I am actually curious, what SystemD does, if it expects graphical.target, > > yet the tools (x11, desktop, etc) are no longer available? > > It boots just as you would expect. If there is no display manager > installed, then none will be executed. At that point, you can login > on the console, and either work that way, or run "startx" to start > an X session, exactly the way you did before systemd. > > There are a few *minor* differences. The biggest is that the X session > stays running on the same tty where you ran startx, rather than switching > to the first idle VT. I don't use a DE so I can't check. Who owns the X server nowadays when running a DM? (With no DM running, ownership changed from root to the user some time ago.) > It's also significantly harder to get the system > to stop clearing the screen after booting, after you logout, and so on. For booting, I use the file: $ cat /etc/systemd/system/getty@.service.d/noclear.conf # /etc/systemd/system/getty@.service.d/noclear.conf 2019-07-15 # https://wiki.archlinux.org/index.php/Disable_clearing_of_boot_messages # Parameter is documented in # /etc/systemd/system/getty.target.wants/getty@tty1.service # and # /lib/systemd/system/getty@.service # [Service] # the VT is cleared by TTYVTDisallocate # TTYVTDisallocate=yes # This file contradicts that default value. [Service] TTYVTDisallocate=no # $ For logout, just edit ~/.bash_logout or remove it. > And every once in a while, the cursor moves to the start of the line a > few seconds after the login prompt has been displayed, but hitting Enter > fixes that. That's the first mention of this phenomenon I recall seeing since I posted https://lists.debian.org/debian-user/2018/03/msg01030.html (which dealt mainly with a more serious problem). I never install a DE/DM and all that stuff, but I get the cursor movement nonetheless. Is that what you're saying? As for the more serious problem reported in my post, I think it only occurred when the laptop was running on the battery. At the time, realising it was to do with that was hampered because I didn't know that the PSU's captive cable entry was iffy, and that it could still be on battery power when connected to the PSU. Eventually the PSU gave out, and its replacement made it obvious that nulls were typed only when on battery power. Since that time, buster has been released, which never showed the phenomenon, the replacement PSU has its captive cable lashed to a coat peg because it's coming off, the connection plug is loose, and the laptop power control section has packed up, so it will only run on the mains. It's not long for this world. > Other than that, it's pretty much the same. Out of its original context, that comment looks somewhat ironic. Cheers, David.
Re: how to remove GUI
On Fri, Sep 11, 2020 at 09:02:30AM -0400, Kenneth Parker wrote: > I am actually curious, what SystemD does, if it expects graphical.target, > yet the tools (x11, desktop, etc) are no longer available? It boots just as you would expect. If there is no display manager installed, then none will be executed. At that point, you can login on the console, and either work that way, or run "startx" to start an X session, exactly the way you did before systemd. There are a few *minor* differences. The biggest is that the X session stays running on the same tty where you ran startx, rather than switching to the first idle VT. It's also significantly harder to get the system to stop clearing the screen after booting, after you logout, and so on. And every once in a while, the cursor moves to the start of the line a few seconds after the login prompt has been displayed, but hitting Enter fixes that. Other than that, it's pretty much the same.
Re: how to remove GUI
On Fri, Sep 11, 2020, 7:56 AM Henning Follmann wrote: > On Thu, Sep 10, 2020 at 11:33:21PM -0500, Michael Morgan wrote: > > Dear friend, > > > > > > > > I recently installed Debian 9.13 on my machine. I was planning to use it > for > > scientific computation so GUI is not necessary. For some reason, I > installed > > the desktop environment with LXDE desktop during installation. Later I > > decided to remove them. These two commands were executed: > > > [...] > > Hello, > > may I interject here. > First, is there a particular reason why you installed an older version of > debian? > > And second, there is no real reason to go through all of this. > You can make the non gui the default. > With systemd: > systemctl set-default multi-user.target > +1 I am actually curious, what SystemD does, if it expects graphical.target, yet the tools (x11, desktop, etc) are no longer available? One note: My preference, is to set multi-user.target on my current systems, boot them into Text, sign into root in Console 2, and do the apt-get "ritual". If it includes a new Kernel (or is, in my opinion, complex), reboot. And then, as the next step, enter the "systemctl start graphical.target" command to get to the Desktop. Good luck! Kenneth Parker
Re: how to remove GUI
Thanks for the explanation of the autoremove intent (I had never seen that explanation before (never looked for it, didn't think I needed it (so far), but the understanding is helpful). Nothing new below this line. On Friday, September 11, 2020 07:53:26 AM Greg Wooledge wrote: > In the more general case, there are two strategies to remove a whole > bunch of packages that have a dependency tree relationship. The first > strategy, which is relatively new, is to count on "apt autoremove", > which is a relatively new feature and has a lot of quirky behavior. > The concept here is that, when you installed the top-level package of > the large dependency tree (whether that's "gnome-core" or > "task-something"), apt will have marked that one package as "manually > installed", and anything else that was brought in at the same time, would > not be so marked. Then, when you want to remove all of them, you first > remove the same top-level package. This doesn't do much on its own, but > now all of the dependent packages have nothing anchoring them. So if you > follow up with an "apt autoremove", it should, in theory, remove all of > the dependent packages. > > In my experience, that doesn't work very well, so I've disabled autoremove > on my system.
Re: how to remove GUI
On Thu, Sep 10, 2020 at 11:33:21PM -0500, Michael Morgan wrote: > Dear friend, > > > > I recently installed Debian 9.13 on my machine. I was planning to use it for > scientific computation so GUI is not necessary. For some reason, I installed > the desktop environment with LXDE desktop during installation. Later I > decided to remove them. These two commands were executed: > [...] Hello, may I interject here. First, is there a particular reason why you installed an older version of debian? And second, there is no real reason to go through all of this. You can make the non gui the default. With systemd: systemctl set-default multi-user.target At that point also disable hibernate and suspend: systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target And last, debian has pure blends for specific fields: https://www.debian.org/blends/ May I suggest Debian Science here? -H -- Henning Follmann | hfollm...@itcfollmann.com
Re: how to remove GUI
On Thu, Sep 10, 2020 at 11:33:21PM -0500, Michael Morgan wrote: > I recently installed Debian 9.13 on my machine. So, not the current stable release > What is the correct way to > completely remove GUI? Well, in this *particular* case, your best course of action would probably be a clean install of Debian 10. Select only "Standard" (or maybe add the OpenSSH server) during the initial task selection. In the more general case, there are two strategies to remove a whole bunch of packages that have a dependency tree relationship. The first strategy, which is relatively new, is to count on "apt autoremove", which is a relatively new feature and has a lot of quirky behavior. The concept here is that, when you installed the top-level package of the large dependency tree (whether that's "gnome-core" or "task-something"), apt will have marked that one package as "manually installed", and anything else that was brought in at the same time, would not be so marked. Then, when you want to remove all of them, you first remove the same top-level package. This doesn't do much on its own, but now all of the dependent packages have nothing anchoring them. So if you follow up with an "apt autoremove", it should, in theory, remove all of the dependent packages. In my experience, that doesn't work very well, so I've disabled autoremove on my system. The other strategy, which is a much older one, relies on you performing a light analysis of the dependency tree and finding some lynchpin package that is holding the whole thing up. E.g. with GNOME 2.x, there was some package like "libgnome-common" or something. If you removed that, it would remove everything else, because everything in GNOME depended (directly or indirectly) on this one package. In the case of a desktop environment, you really have two different dependency trees to worry about. There's the X server (xorg), and there's the desktop environment (task-gnome-or-whatever). You can perform a separate analysis on each of these trees, identify which low-level libraries or "common" packages are necessary to hold them up, and remove those. Or, as we've said a few times now, you can just leave the packages in place and ignore them. Or do a clean install.
Re: how to remove GUI
On Thu, 10 Sep 2020 23:33:21 -0500 "Michael Morgan" wrote: > Dear friend, > > > > I recently installed Debian 9.13 on my machine. I was planning to use > it for scientific computation so GUI is not necessary. For some > reason, I installed the desktop environment with LXDE desktop during > installation. Later I decided to remove them. As Andrei has said, 'if I was going there then I wouldn't start from here..'. It really would be a lot quicker to reinstall than to spend days trying to identify what you need to remove. When the time comes in the installer, don't select anything at all, remove all the ticks, and you will get a fairly minimal console-only installation. Alternatively, remove the Display Manager (gdm, xdm, etc.) and whatever GUI you have remaining should never start, you should boot into just a console. Only if you have a really tiny hard drive will the wasted space be a problem. -- Joe
Re: how to remove GUI
On Vi, 11 sep 20, 09:32:23, Andrei POPESCU wrote: > > When removing them you might need to add > > -o APT::Autoremove::SuggestsImportant=no > > and even > > -o APT::Autoremove::RecommendsImportant=no Err, these won't do much on removing the package, they work only in combination with 'autoremove'. > Note: the second one in combination with 'autoremove' may remove much > more than actually intended. This is still very much valid. Kind regards, Andrei -- http://wiki.debian.org/FAQsFromDebianUser signature.asc Description: PGP signature
Re: how to remove GUI
On Jo, 10 sep 20, 23:33:21, Michael Morgan wrote: > > So it seems the desktop package was removed. But why it still has GUI? As you found out, removing collections of packages is more difficult than installing them. Try running this: apt -o APT::Autoremove::SuggestsImportant=no autoremove --purge Do check carefully the list of packages to be removed, in case it removes packages that are still needed. If this doesn't work you might still have some LXDE related package installed. You can find them with apt list --installed '*lxde*' When removing them you might need to add -o APT::Autoremove::SuggestsImportant=no and even -o APT::Autoremove::RecommendsImportant=no Note: the second one in combination with 'autoremove' may remove much more than actually intended. Kind regards, Andrei -- http://wiki.debian.org/FAQsFromDebianUser signature.asc Description: PGP signature