Notices


Reply
Thread Tools
Posts: 5 | Thanked: 0 times | Joined on Feb 2011 @ Germany
#1
Dear Community,

I'm not familiar with the way N900 operates to get packages installed (coming from SuSE's yast/RPM world).

But I had to learn in the past that web-sources are not permanently reliable concerning package availability.
So what I'd like to do, is to backup on my PC all the "packages" that I installed on my N900 and found useful.

Why? Say my Phone crashes in 2 months - I reinstall to FW/OS, then want to reinstall my favourite Radio-Application and realize: no longer available on the Internet...

But for my Question: following downloadlinks (or even worse using the application manager) does not necessarily offer me a package, but rather some "xxxx.install" file, which doesn't contain the package.
So what do I have to do to really get the package downloaded?
 
Posts: 2,101 | Thanked: 1,934 times | Joined on Sep 2008 @ Berlin, Germany
#2
Dpkg is the equivalent application to rpm. Use it to create a list of your installed applications
Code:
dpkg -l|awk '/^ii/{ print $2 }' >pkgs_installed.txt
This generates a long list of installed packages.
Now download them with apt-get from the repos
Code:
apt-get update && apt-get install -dy $(<pkgs_installed.txt)
This is quite some space occupied in /opt/var/cache/apt/archives. You better get them soon off your Device or you will run into some sort of trouble with lack of space.

Edit: Fixed the path to the archives in /opt...

Last edited by michaaa62; 2011-02-19 at 00:08.
 

The Following 3 Users Say Thank You to michaaa62 For This Useful Post:
Posts: 5 | Thanked: 0 times | Joined on Feb 2011 @ Germany
#3
Just to get you right: Using the second command on my N900 will place all installed packages in the directory "/opt/var/cache/archives"?
And once i backuped this directory's content, I can savely remove it from the N900 without crashing the system?
Last question: if I should happen to need to reinstall all the packages:
Where would I have to put them on the N900?
What command would I have to use for that?

Big thanks so far.
 
Posts: 2,101 | Thanked: 1,934 times | Joined on Sep 2008 @ Berlin, Germany
#4
Okay that was a it in a hurry, sorry.
The second command i gave you will refresh the package list first and then get each package from the list and 'install' it, but with the -d option you just download it. This would go to /var/cache/apt/, this directory is linked to /opt/var/cache/apt/. Inside is the directory /archives where you will find all the downloaded packages. Copy the folder to some safe storage and also add the generated list.

For reinstallation there is the need to install rootsh from extras repo before you could do anything relevant as 'local linux-guru'. This step also refreshes the package list for apt-get to work.
a) Then copy the folder back to the mentioned directory, grab the corresponding list and
Code:
apt-get install $(pkgs_installed.txt)
will install them right away.

Or

B) You could also change into the directory and install all of the packages with a wildcard
Code:
dpkg -i *.deb
This will give you all sorts of dependency error, because dpkg knows little how to resolve dependencies. But
Code:
dpkg --configure -a
and/or
Code:
apt-get install -f
will cope with all the problems sooner or later.

EDIT: I fixed the directory in my former post to contain the right path.

Last edited by michaaa62; 2011-02-19 at 00:09.
 

The Following User Says Thank You to michaaa62 For This Useful Post:
Banned | Posts: 726 | Thanked: 497 times | Joined on Aug 2010 @ Gravesend, UK
#5
michaaaarrrrggghhhh62!

Thanks for that.
 
Posts: 5 | Thanked: 0 times | Joined on Feb 2011 @ Germany
#6
Once again thanks - but now two questions come up:
1) You mentioned, that I should get the downloaded packages off my device or I might face diskspace trouble. I asked, whether it was save to delete them from /opt/var/cache/apt/archives. So, can I savely do that?
2) As I start with "apt-get update && apt-get install -dy $(<pkgs_installed.txt)" my N900 starts downloading packages.

[Edit:] I think managed to unistall the broken package, rebuilt package list with command(1) and executed command(2)

Now I get:
(...)
Hit http://repository.maemo.org fremantle/non-free Packages
Hit http://edu.kde.org stable/ Packages
Reading package lists... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.

But looking into: /opt/var/cache/apt/archives
I can only see python related debs. But none for eg marble which is installed on my N900.

Last edited by N900_TUX; 2011-02-19 at 09:47.
 
Posts: 2,101 | Thanked: 1,934 times | Joined on Sep 2008 @ Berlin, Germany
#7
To 1) I would move them from the device to external storage, may that be another microSD or some PC does not matter.
To 2) Well, these are only the packages, that do not come with a standard firmware image, you are seeing or those that are in the repos in a newer version than the pre-installed versions.
 
Posts: 5 | Thanked: 0 times | Joined on Feb 2011 @ Germany
#8
Wel,l thanks for explaining.

Maybe I didn't express exactly enough, what I wanted to do.
I want to backup all packages that are not part of the standard intallation (and not those, that are newer then the ones I installed).
So lets say I installed marble 1.0.0 (which is a Navigation SW) from the internet repo. Then I'd like to backup all needed packages to be able to reinstall marble on a clean standard installation WITHOUT needing access to the internet repository.
[Edit:]
Currently I only see (no Addblock-Plus, no marble, no FM Radio):
lock
partial
pymaemo-optify_0.5_all.deb
python-cairo_1.4.12-1.2maemo2_armel.deb
python-central_0.6.11.1maemo2_all.deb
python-dbus_0.83.0-1maemo3_armel.deb
python-gconf_2.26.1-1maemo1_armel.deb
python-gobject_2.16.1-1maemo2_armel.deb
python-gst0.10_0.10.14-2maemo5_armel.deb
python-gtk2_2.12.1-6maemo10_armel.deb
python-hildon_0.9.0-1maemo18_armel.deb
python-minimal_2.5.2-3maemo4_all.deb
python-notify_0.1.1-2maemo1_armel.deb
python-numeric_24.2-9maemo4_armel.deb
python-osso_0.4-0maemo5_armel.deb
python-support_1.0.6maemo1_all.deb
python2.5-minimal_2.5.4-1maemo6_armel.deb
python2.5_2.5.4-1maemo6_armel.deb
python_2.5.2-3maemo4_all.deb

Last edited by N900_TUX; 2011-02-19 at 11:00. Reason: incomplete
 
Posts: 2,101 | Thanked: 1,934 times | Joined on Sep 2008 @ Berlin, Germany
#9
Well,it is far, far above my regex knowledge [being a builder] to try to subtract the pre-installed packages from the pkgs_installed.txt, you generated with the command #1.
But you could try to download the packages by actually making the process you want to be prepared for: Generate the list, flash the firmware, get rootsh installed via HAM, install the rest of your packages through command #2.
Better do it on a relaxed Saturday morning, than late Sunday night to have it ready on Monday morning

Last edited by michaaa62; 2011-02-19 at 12:13.
 

The Following User Says Thank You to michaaa62 For This Useful Post:
Posts: 5 | Thanked: 0 times | Joined on Feb 2011 @ Germany
#10
Hmm - getting prepared for the "Supergau" by starting it testwise...
There should be some easier way?
Isn't it possible to download a whole repository for a known program?
I mean, I know the download source for a certain program (e.g. marble). Klicking on that link causes my N900 to perform certain actions to install this software. Clicking that link on a PC results in downloading the following file: stable.install
Content:
[catalogues]
catalogues = marble-stable

[install]
catalogues = marble-stable
package = marble

[marble-stable]
name = Marble (Stable)
uri = http://edu.kde.org/marble/downloads/maemo/fremantle
dist = stable/

What does N900 do with this info? What do I need to do to achive the same on a PC for obtaining the relevant installation packages?

Possible alternative: Is it possible to get ALL installed packages (including standard installation) into a directory and copy these? (Because the initially given command (1) causes a full list (of packages?) to be created, but the command (2) only gives the small excerpt of these (as stated, only those python related packages can be found).

But big thanks to you for helping me so many times...
 
Reply


 
Forum Jump


All times are GMT. The time now is 08:13.