maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   OS2007 / Maemo 3 / Bora (https://talk.maemo.org/forumdisplay.php?f=23)
-   -   Reinstall all previously applications after flashing (https://talk.maemo.org/showthread.php?t=5582)

smo 2007-04-01 20:36

Reinstall all previously applications after flashing
 
Hi everybody,

I've installed a lot of applications on my N800. I want to upgrade to the newest firmware, but after flshing all installed apps will be lost, right? I'm really scared to reinstall about 30 programmes one by one(!) again.

Is there a way to save a list of all installed applications and reinstall them after the upgrade with just one command/click?


smo

Tabster 2007-04-01 20:49

Re: Reinstall all previously applications after flashing
 
I made a complete backup
went through Application Manager and wrote down all my apps
upgraded to new OS
restored the backup
went through application manager and selected them one by one.

didn't take too long. All (most?) of your settings are saved in the backup/restore

Milhouse 2007-04-01 23:47

Re: Reinstall all previously applications after flashing
 
How difficult would it be for the currently installed package names (ie. ssh, mplayer, canola etc.) to be "remembered" as part of the backup? Upon restoring the backup the user could then reinstall the same packages automatically.

The application restore function would simply be multiple "apt-get install --force-yes <packagename>" commands where <packagename> is one of the previously installed packages. The necessary repositories must be present prior to installation but these are already part of the backup. And it's unlikely the function would work across major OS upgrades (ie. upgrading from OS 2006 to OS 2007 would most likely result in problems, but a minor upgrading within the same OS version should work more or less 100%).

It's probably not a technically difficult feature to implement, and is merely a cosmetic/convenience function but it may help improve consumer acceptance. I guess I should add it to Bugzilla as an enhancement if anyone thinks it has legs. :)

A simple shell script could also do the trick - anyone know how to get the list of installed packages (the same list that appears in App Manager -> Installed Apps)? The script would dump the current packages to memory card prior to upgrade then read back the package names when re-installing the packages.

therblack 2007-04-02 14:31

Re: Reinstall all previously applications after flashing
 
Okay, so I haven't actually done this on my n800, but I have just done it when upgrading a laptop (running ubuntu 6.10)

a) first, before upgrading, run in an XTerm:
dpkg --get-selections > /media/mmc1/packages.txt

This stores a list of packages and their installed status

b) upgrade and restore a backup that contains sources.list

c) In XTerm (running as root) run:
cat /media/mmc1/packages.txt > dpkg --set-selections
apt-get dselect-upgrade


This seems to work pretty well, at least of ubuntu, so maybe it will help here. Of course, for applications that have been installed but not from a repositary (gizmo, for example), it will not help...but in other cases, it maybe okay

TA-t3 2007-04-02 15:00

Re: Reinstall all previously applications after flashing
 
Better run that command with '-su' first (the upgrade command), just to verify what it will do first. (-s is a 'try before you buy' option, -u lists packages). e.g. apt-get dselect-upgrade -su

timsamoff 2007-04-02 15:05

Re: Reinstall all previously applications after flashing
 
Please go to the Maemo bugtracker and vote for this option to be added to the Backup app!!!

https://maemo.org/bugzilla/show_bug.cgi?id=647

Currently, there's only 1 vote (mine!), so please add your so that the developers know that we'd like this functionality added

Tim

ebunny 2007-04-02 16:46

Re: Reinstall all previously applications after flashing
 
I have a dumb question, I basically am a nubie to this OS system and can't seem to even find the applications on my N800 that I've installed to move them to my memory card, where do I go and look to copy them to my SD card?

smo 2007-04-02 19:49

Re: Reinstall all previously applications after flashing
 
I just tested the commands with my current OS by first uninstalling the app 'wget' via the gui and then reinstalling it via console:

1. Save installed packages:
Code:

$ dpkg --get-selections > packages.txt
2. Check if app "wget" is in packages.txt
Code:

$ less packages.txt | grep wget
wget    install

3. Uninstall wget via gui (I'll try to reinstall it via console in the next step).

4. Try to reinstall wget:
Code:

$ cat packages.txt | dpkg --set-selections
$ apt-get dselect-upgrade -su

Reading package lists...
Building dependency tree...
The following NEW packages will be installed:
  libblkid1 libuuid1 mount wget
The following packages will be upgraded:
  busybox
1 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Inst libblkid1 (1.37-2sarge1 repository.maemo.org)
Conf libblkid1 (1.37-2sarge1 repository.maemo.org)
Inst libuuid1 (1.37-2sarge1 repository.maemo.org)
Conf libuuid1 (1.37-2sarge1 repository.maemo.org)
Inst busybox [3:1.1.3-3.osso17] (3:1.1.3-3.sdk3 repository.maemo.org) []
Inst mount (2.12p-4sarge1.osso2 repository.maemo.org)
Conf mount (2.12p-4sarge1.osso2 repository.maemo.org)
Inst wget (1.10.2-2ubuntu1mg2 aggregated packages by Marius Gedminas:maemo3.0)
Conf busybox (3:1.1.3-3.sdk3 repository.maemo.org)
Conf wget (1.10.2-2ubuntu1mg2 aggregated packages by Marius Gedminas:maemo3.0)


As you can see, 'wget' (and some other packages?) will be installed. :)

After running
Code:

$ apt-get dselect-upgrade
(without 'su') 'wget' is installed again and everthing seems fine.

Thanks for your help. :)

smo

TA-t3 2007-04-03 10:33

Re: Reinstall all previously applications after flashing
 
Yeah, that's why I suggested the -su... I don't really understand why it wants to (re-)install more than just the package you removed. Anyway, if it worked ok for you then all is well! :)

lucky-luke 2007-04-03 15:13

Re: Reinstall all previously applications after flashing
 
There is any way to locally download to MMC1 all the packages, to install later off line?
This would be great.
I suppose that then will be better to make a local repository.
But I don't know how.


All times are GMT. The time now is 02:27.

vBulletin® Version 3.8.8