Announcement

Collapse
No announcement yet.

Space used by programmes

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Originally posted by GreyGeek View Post
    A list of man pages and what they do: apropos man
    And if one forgets that command, its inverse will remind you: man apropos

    Comment


      #17
      Originally posted by whatthefunk View Post
      Some are Bash commands, but many are just program names followed by arguments for the programs. In this thread, there has been no Bash. For example:
      Code:
      apt show bleachbit
      apt is a program name while show and bleachbit are arguments for that program which tell it what to do. In this case, show gives package information for the package bleachbit.
      Thank you

      A good and clear explanation
      kubuntu version: 16.04.5 LTS

      Laptop: Toshiba-Satellite-L350

      Comment


        #18
        Originally posted by GreyGeek View Post
        A list of man pages and what they do: apropos man

        Example of apropos apt
        Code:
        $ apropos apt
        add-apt-key (8)      - Command line tool to add GPG keys to the APT keyring
        add-apt-repository (1) - Adds a repository into the /etc/apt/sources.list or /etc/apt/sources.list.d or removes an existing one
        airodump-ng (8)      - a wireless packet capture tool for aircrack-ng
        apt (8)              - command-line interface
        apt-add-repository (1) - Adds a repository into the /etc/apt/sources.list or /etc/apt/sources.list.d or removes an existing one
        apt-cache (8)        - query the APT cache
        apt-cdrom (8)        - APT CD-ROM management utility
        apt-config (8)       - APT Configuration Query program
        apt-extracttemplates (1) - Utility to extract debconf config and templates from Debian packages
        apt-ftparchive (1)   - Utility to generate index files
        apt-get (8)          - APT package handling utility - - command-line interface
        apt-key (8)          - APT key management utility
        apt-mark (8)         - mark/unmark a package as being automatically-installed
        apt-rdepends (1)     - performs recursive dependency listings similar to apt-cache
        apt-secure (8)       - Archive authentication support for APT
        apt-show-source (1)  - Lists source-packages.
        apt-show-versions (1p) - Lists available package versions with distribution
        apt-sortpkgs (1)     - Utility to sort package index files
        apt.conf (5)         - Configuration file for APT
        apt_preferences (5)  - Preference control file for APT
        aptd (1)             - package managing daemon proving a D-Bus interface
        aptdcon (1)          - command line client for aptdaemon
        aptitude (8)         - high-level interface to the package manager
        aptitude-create-state-bundle (1) - bundle the current aptitude state
        aptitude-curses (8)  - high-level interface to the package manager
        aptitude-run-state-bundle (1) - unpack an aptitude state bundle and invoke aptitude on it
        AptPkg (3pm)         - interface to libapt-pkg
        AptPkg::Cache (3pm)  - APT package cache interface
        AptPkg::Config (3pm) - APT configuration interface
        AptPkg::hash (3pm)   - a helper class for implementing tied hashes
        AptPkg::PkgRecords (3pm) - APT package description class
        AptPkg::Policy (3pm) - APT package version policy class
        AptPkg::Source (3pm) - APT source package interface
        AptPkg::System (3pm) - APT system abstraction class
        AptPkg::Version (3pm) - APT package versioning class
        apturl (8)           - graphical apt-protocol interpreting package installer
        apturl-kde (8)       - graphical apt-protocol interpreting package installer
        axi-cache (1)        - query the Apt Xapian Index
        captoinfo (1)        - convert a termcap description into a terminfo description
        debconf-apt-progress (1) - install packages using debconf to display a progress bar
        dvdxchap (1)         - Extract chapter information from DVDs
        dvgrab (1)           - Capture DV or MPEG-2 Transport Stream (HDV) video and audio data from FireWire
        Image::ExifTool::CaptureOne (3pm) - Read Capture One EIP and COS files
        Image::ExifTool::NikonCapture (3pm) - Read/write Nikon Capture information
        import (1)           - saves any visible window on an X server and outputs it as an image file. You can capture a single window, the entire ...
        import.im6 (1)       - saves any visible window on an X server and outputs it as an image file. You can capture a single window, the entire ...
        kazam (1)            - Screen recording and capturing program.
        laptop-detect (8)    - attempt to detect a laptop
        lmdb_table (5)       - Postfix LMDB adapter
        Net::DNS::RR::NAPTR (3pm) - DNS NAPTR resource record
        org.debian.apt (7)   - the main interface of aptdaemon
        org.debian.apt.transaction (7) - the main interface of an aptdaemon transaction
        sane-scsi (5)        - SCSI adapter tips for scanners
        sources.list (5)     - List of configured APT data sources
        synaptic (8)         - graphical management of software packages
        synaptics (4)        - touchpad input driver
        synclient (1)        - commandline utility to query and modify Synaptics driver options.
        toshset (1)          - manipulate bios and hardware settings of Toshiba laptops
        update-apt-xapian-index (8) - rebuild the Apt Xapian Index
        XkbApplyCompatMapToKey (3) - Apply the new compatibility mapping to an individual key to get its semantics updated
        XkbSAPtrDfltValue (3) - Returns the valueXXX field of act converted to a signed int
        xvinfo (1)           - Print out X-Video extension adaptor information
        Then use the man on any item in the list...

        EDIT: I forgot my old favorite, before KDE appeared.
        xman
        which, ignoring the font warning, shows a small bash gui. On it is "Show Manual". When that GUI pops open it has two parts. The top part lists the commands. Click on a command and its man page shows in the bottom part. The xman gui has two menu options which show several other options.
        Thank you

        I had not heard of xman

        My gui has four buttons help, quit and Manual Page

        A good resource
        kubuntu version: 16.04.5 LTS

        Laptop: Toshiba-Satellite-L350

        Comment


          #19
          The KDE help system can also read man pages. You can press Alt+F2 and type khelpcenter man:command, where command is whatever you want to learn about.

          A useful approach is to create a Bash alias to the help center. Now you can easily open man pages at the command line into separate windows, which avoids interrupting your workflow at the command prompt.

          Comment


            #20
            Yes, that works.

            I have help listed in my favourites.

            If I click of this function, I can activate the same system.
            kubuntu version: 16.04.5 LTS

            Laptop: Toshiba-Satellite-L350

            Comment


              #21
              Back to the OP; I found this interesting command on an Ubuntu blog:

              dpkg-query --show --showformat='${Package;-50}\t${Installed-Size}\n' | sort -k 2 -n | grep -v deinstall | awk '{printf "%.3f MB \t %s\n", $2/(1024), $1}'

              Which will list all installed packages and the space they consume. The real issue is dependencies. Rarely does a package live alone. You'd have to add all packages together to get the real total, and even then you would often be wrong because many packages are used by more than one program.

              BTW, to list say - only the 20 largest packages - add this to the above command:

              | tail -n 20

              Please Read Me

              Comment


                #22
                Originally posted by oshunluvr View Post
                Back to the OP; I found this interesting command on an Ubuntu blog:

                dpkg-query --show --showformat='${Package;-50}\t${Installed-Size}\n' | sort -k 2 -n | grep -v deinstall | awk '{printf "%.3f MB \t %s\n", $2/(1024), $1}'

                Goodness gracious.

                That's one for an alias or two - or more
                Last edited by anonprivate; Oct 18, 2014, 07:41 AM.
                kubuntu version: 16.04.5 LTS

                Laptop: Toshiba-Satellite-L350

                Comment


                  #23
                  Originally posted by anonprivate View Post
                  Goodness gracious.

                  That's one for an alias or two - or more
                  Good idea! Alias it to "space" then you could do

                  space | grep <somepackagename>

                  nice.

                  Please Read Me

                  Comment


                    #24
                    Originally posted by oshunluvr View Post
                    Good idea! Alias it to "space" then you could do

                    space | grep <somepackagename>

                    nice.
                    I can confirm that the command works as described.

                    When running the command, I noticed what I believe the be repetitions (probably updates). Are these repetitions necessary?

                    I give an example:

                    Code:
                    2.434 MB        linux-headers-3.13.0-35-generic
                    12.436 MB        linux-headers-3.13.0-36-generic
                    12.441 MB        linux-headers-3.13.0-37-generic
                    
                    30.980 MB        linux-image-3.13.0-34-generic
                    31.022 MB        linux-image-3.13.0-35-generic
                    31.027 MB        linux-image-3.13.0-36-generic
                    31.044 MB        linux-image-3.13.0-37-generic
                    
                    60.350 MB        linux-headers-3.13.0-34
                    60.354 MB        linux-headers-3.13.0-36
                    60.371 MB        linux-headers-3.13.0-35
                    60.373 MB        linux-headers-3.13.0-37
                    
                    108.079 MB       linux-image-extra-3.13.0-34-generic
                    108.112 MB       linux-image-extra-3.13.0-35-generic
                    108.150 MB       linux-image-extra-3.13.0-36-generic
                    108.174 MB       linux-image-extra-3.13.0-37-generic
                    108.285 MB       linux-image-3.2.0-58-generic-pae
                    108.592 MB       linux-image-3.2.0-67-generic-pae
                    Best wishes.

                    A
                    kubuntu version: 16.04.5 LTS

                    Laptop: Toshiba-Satellite-L350

                    Comment


                      #25
                      Not repititions as you put it. Each installed kernel has three parts: headers, image, and image-extra. Your output shows that you have kernels 3.13.0.34 through 3.13.0.37 installed.
                      Windows no longer obstructs my view.
                      Using Kubuntu Linux since March 23, 2007.
                      "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                      Comment


                        #26
                        Originally posted by anonprivate View Post
                        Are these repetitions necessary?
                        If you do not have a specific need for older kernels (and the newest versions boots and works fine), you can safely remove/purge older versions (although it is usually a good idea to keep at least two kernels installed so you have a failsafe to boot to if you run into unexpected issues with the latest one)

                        You can remove the older packages manually, or you can run:
                        sudo apt-get --purge autoremove
                        to remove unneeded packages including redundant kernel packages (kernel autoremoval should keep at least two kernel versions installed, the actual number of kept kernel versions depends on a few variables...like which kernel you are currently running)

                        another useful command to find orphaned packages is deborphan (in the package 'deborphan')
                        Last edited by kubicle; Oct 19, 2014, 02:29 AM.

                        Comment


                          #27
                          Originally posted by kubicle View Post
                          If you do not have a specific need for older kernels (and the newest versions boots and works fine), you can safely remove/purge older versions (although it is usually a good idea to keep at least two kernels installed so you have a failsafe to boot to if you run into unexpected issues with the latest one)

                          You can remove the older packages manually, or you can run:
                          sudo apt-get --purge autoremove
                          to remove unneeded packages including redundant kernel packages (kernel autoremoval should keep at least two kernel versions installed, the actual number of kept kernel versions depends on a few variables...like which kernel you are currently running)

                          another useful command to find orphaned packages is deborphan (in the package 'deborphan')
                          Thank you for responding.

                          Useful information, as always.

                          I have plenty of disk space, so I will keep the older kernels.

                          I believe that I am running Bash

                          Out of interest, I tried the man pages: purge, autoremove, deborphan

                          There appears to be no entries (konsole, not elevated).

                          I have discovered that I do not have deborphan installed.

                          Again, out of interest, If I decided to manually remove, say, version 34 would I delete all of the following.

                          Code:
                          andrew@andrew-Dell-DM061:~$ locate linux-image-3.13.0-34-generic
                          
                          /home/andrew/.local/share/Trash/files/usr/share/doc/linux-image-3.13.0-34-generic
                          /usr/share/doc/linux-image-3.13.0-34-generic
                          /usr/share/doc/linux-image-3.13.0-34-generic/changelog.Debian.gz
                          /usr/share/doc/linux-image-3.13.0-34-generic/copyright
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.list
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.md5sums
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.postinst
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.postrm
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.preinst
                          /var/lib/dpkg/info/linux-image-3.13.0-34-generic.prerm
                          Best wishes.

                          A
                          kubuntu version: 16.04.5 LTS

                          Laptop: Toshiba-Satellite-L350

                          Comment


                            #28
                            Originally posted by anonprivate View Post
                            Out of interest, I tried the man pages: purge, autoremove, deborphan
                            "--purge" is an option for apt-get (meaning also remove config files when uninstalling package)
                            "autoremove" is a command for apt-get (meaning remove packages that were installed as dependencies but are no longer needed)
                            both of these are explained in 'man apt-get'
                            deborphan has to be installed for it's man page to be available

                            Originally posted by anonprivate View Post
                            Again, out of interest, If I decided to manually remove, say, version 34 would I delete all of the following.
                            No, don't delete files that were installed by a package, I meant manually removing redundant packages, as in 'sudo apt-get purge linux-image-3.13.0-34-generic' (of course, autoremoval is usually easier and quicker)

                            Comment


                              #29
                              OK

                              Out of interest

                              sudo apt-get --purge autoremove

                              I have read the man page.

                              Purge is an option and autoremove a command.

                              I get a little confused between options and commands and the use of, or not, --

                              Purge sounds like a command
                              Last edited by anonprivate; Oct 19, 2014, 10:19 PM.
                              kubuntu version: 16.04.5 LTS

                              Laptop: Toshiba-Satellite-L350

                              Comment


                                #30
                                Originally posted by anonprivate View Post
                                OK

                                Out of interest

                                sudo apt-get --purge autoremove

                                I have read the man page.

                                Purge is an option and autoremove a command.

                                I get a little confused between options and commands and the use of, or not, --

                                Purge sounds like a command
                                In short, apt-get requires one command that basically tells apt-get what to do, these are listed in the DESCRIPTION section of the man page.
                                Then you can tweak the behavior of the command by defining additional options, these are listed in the OPTIONS section of the man page and are prefixed with either -- or - (depending on whether you use long or short options).

                                Of course it might be confusing that purge can be used either as a command or an option, "sudo apt-get purge <packagename>" (purge used as a command) is the same as "sudo apt-get --purge remove <packagename>" (remove as the command, --purge as an option).

                                The command autoremove does not purge packages by default, hence the need for the --purge option when using it if you want to completely remove the packages.

                                Comment

                                Working...
                                X