Results 1 to 7 of 7

Thread: Backup Packages

  1. #1
    Join Date
    Nov 2011
    Beans
    11

    Talking Backup Packages

    Hi !

    I am about to reinstall Kubuntu on my laptop (had a little problem :s http://ubuntuforums.org/showthread.p...2#post11710212 ) and I wanted to know if there is a way to list, or to backup all the currently installed packages so I can reinstall them easily once I'm done.
    Even just an automaticaly generated text list would be usefull, at least I would be sure not to forget one.

    Thanks !

    EDIT : Due to the problem mentionned above, I have no graphic inteface xD
    Last edited by mebss; February 23rd, 2012 at 01:05 AM.

  2. #2
    Join Date
    Mar 2010
    Beans
    Hidden!

    Re: Backup Packages

    You can do the listing of your packages with dpkg (should work in kde like unity).

    Code:
    sudo dpkg --get-selections > /path/to/file/<filename>
    alter "/path/to/file/<filename>" to define what the output file (your list of packages) is called and where it is stored on your filesystems.


    To update a newly installed sysem use,

    Code:
    sudo dpkg --set-selections < /path/to/file/<filename>
    alter the path and filename to match the first code above.

    followed by,

    Code:
    sudo apt-get install dselect
    and

    Code:
    sudo dselect
    dselect when used correctly will download and install all the previously installed packages as defined by your list.
    Last edited by yetiman64; February 23rd, 2012 at 01:28 AM.

  3. #3
    Join Date
    Nov 2011
    Beans
    11

    Re: Backup Packages

    Nice, thank you!
    Just a question, will it also list the system updates or just the packages I installed myself?

  4. #4
    Join Date
    Mar 2010
    Beans
    Hidden!

    Re: Backup Packages

    Quote Originally Posted by mebss View Post
    Nice, thank you!
    Just a question, will it also list the system updates or just the packages I installed myself?
    It will list everything installed as far as I am aware up to the point you used the command.

    I'm not sure about this next bit, but it would probably be wise to revert/uninstall any ppa's/proprietary drivers before using this. They could then be re-added to the new install after using dselect, I would advise you to wait for confirmation if you feel it is necessary.

    I have used the method above successfully with Ubuntu, but I did take the precaution of removing ppas and proprietary drivers first, before doing the install listing initially.

  5. #5
    Join Date
    Nov 2011
    Beans
    11

    Re: Backup Packages

    Hmm nice to know that.
    As you said it would "be wise to revert/uninstall any ppa's/proprietary drivers before" proceeding.
    But how do I do that and why would it be bad if I don't?
    Or maybe I can chose which packets to install or not before running dselect (maybe by editing the file)?
    Last edited by mebss; February 23rd, 2012 at 02:12 AM.

  6. #6
    Join Date
    Mar 2010
    Beans
    Hidden!

    Re: Backup Packages

    Quote Originally Posted by mebss View Post
    Hmm nice to know that.
    As you said it would "be wise to revert/uninstall any ppa's/proprietary drivers before" proceeding.
    But how do I do that and why would it be bad if I don't?
    Or maybe I can chose which packets to install or not before running dselect (maybe by editing the file)?
    I actually said,

    ..it would probably be wise to revert...
    As I indicated, I'm not sure it is entirely necessary I just used that approach as a precautionary measure. Maybe it would have been easier for me to leave the ppas in place and install all their gpg keys and details in the new install, did an update and run dselect. Will have to test that out next time I need to use it.

    Wait for further opinion on that from others here (maybe consider removing the [SOLVED] tag on the thread to garner more views on the main forum).

    I would avoid your suggestion of removing packages from the list directly, could leave you with a broken new install if you break a dependency of another package you leave in when doing so. That possibility is known as "dependency hell", and yes it can get messy to the point of being easier to do a reinstall.

    Good luck and cheers for now. yetiman64

  7. #7
    Join Date
    Nov 2011
    Beans
    11

    Re: Backup Packages

    All right, thank you very much yetiman64 ;D

    Waiting for other replies ^^.
    Last edited by mebss; February 23rd, 2012 at 06:19 AM.

Tags for this Thread

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
  •