Page 5 of 9 FirstFirst ... 34567 ... LastLast
Results 41 to 50 of 84

Thread: HOWTO: Backup all installed programs/packages

  1. #41
    Join Date
    Apr 2006
    Location
    Coventry
    Beans
    1,379
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO: Backup all installed programs/packages

    Quote Originally Posted by bbowdry View Post
    Can you add remarks to this file such as date and information on how back and/or restore?
    Not sure how this would be possible. But I suppose you could create another list with all the packages (in one txt file) that has the information you require. When I remember how to do this I will let you know!

  2. #42
    Join Date
    May 2009
    Beans
    127
    Distro
    Ubuntu 12.10 Quantal Quetzal

    Re: HOWTO: Backup all installed programs/packages

    thanks it was very helpful i was looking for it

  3. #43
    Join Date
    Feb 2009
    Beans
    182

    Re: HOWTO: Backup all installed programs/packages

    I finished repackaging my Jaunty, a total of 1,425 pkgs in 942 MB of storage.
    It took about 3 hours and I did get a couple of error messages indicating broken packages. I have to assume that my system was not utilizing these broken packages.

  4. #44
    Join Date
    Mar 2008
    Beans
    4,715
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO: Backup all installed programs/packages

    Cuba71, if you have ever uninstalled a package then when you run
    Code:
    fakeroot -u dpkg-repack `dpkg --get-selections | grep install | cut -f1`
    you will get an error because
    Code:
    dpkg --get-selections | grep install | cut -f1
    will list "deinstalled" packages as well as "installed" packages.

    A way to avoid this problem is to run
    Code:
    fakeroot -u dpkg-repack $(aptitude -F '%p' search '~i')
    instead, because unlike the dpkg command
    Code:
    aptitude -F '%p' search '~i'
    will list installed packages only.

  5. #45
    Join Date
    Feb 2009
    Beans
    182

    Re: HOWTO: Backup all installed programs/packages

    unutbu:
    I see where I made the mistake. I think I could've used:

    Code:
    fakeroot –u dpkg-repack `dpkg –get-selections | grep -v deinstall | cut -f1`
    to eliminate the "deinstall" packages

  6. #46
    Join Date
    Feb 2009
    Beans
    22
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO: Backup all installed programs/packages

    Quote Originally Posted by PinkFloyd102489 View Post
    Wouldnt it just be easier to do this?

    Code:
    To make the list:
    sudo dpkg --get-selections > installed-software
    
    To restore packages:
    sudo dpkg --set-selections < installed-software
    This gives you the list of packages without all of the deb files. Mind that you'll need an internet connection, but most computers do.



    EDIT: installed-software is a file btw. It just acts as a list that you pipe back into the dpkg command so it will know what packages to download.
    How will you install the packages after set-selections?

    If you use dselect, it will remove any installed packages which are not in the list...
    Last edited by atoztoa; December 8th, 2009 at 03:23 PM.

  7. #47
    Join Date
    Feb 2009
    Beans
    22
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO: Backup all installed programs/packages

    Quote Originally Posted by abhiroopb View Post
    No problem. So it seems that all it takes is putting ALL debs in one directory and running dpkg -i *.deb. But you have to make sure that all dependencies are in the directory.
    I had once tried that command for the .deb files generated by APTonCD. It worked for some time and showed lots of errors and finally told... "Too many errors" and aborted.

    The next time I restarted, X-windows wont load... I had to reinstall Ubuntu

    Be careful...
    Last edited by atoztoa; December 8th, 2009 at 03:23 PM.

  8. #48
    Join Date
    Feb 2010
    Beans
    30

    Re: HOWTO: Backup all installed programs/packages

    I think we should use
    dpkg -E -i *.deb
    to ignore all the packages have the same version with the installed packages.

  9. #49
    Join Date
    Jun 2010
    Beans
    48

    Re: HOWTO: Backup all installed programs/packages

    Code:
    $ sudo apt-get install dpkg-repack fakeroot
    $ mkdir ~/dpkg-repack; cd ~/dpkg-repack
    $ fakeroot -u dpkg-repack `dpkg --get-selections | grep install | cut -f1`
    (the last command will take some time)


    When I tried the third command, it says

    Unknown option: --get selections

    and displays some options with --

    what should i do to resolve this?

  10. #50
    Join Date
    May 2010
    Location
    UK
    Beans
    305
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Backup all installed programs/packages

    Quote Originally Posted by abhiroopb View Post
    PROBLEM: Lets say you have set up your *buntu box. Now you want to backup all the installed deb files so that you can restore them quickly and efficiently.
    Interesting, might come in handy someday, +1

Page 5 of 9 FirstFirst ... 34567 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •