You are not logged in.

#1 2007-04-18 14:29:00

chilebiker
Member
From: Zurich, Switzerland
Registered: 2006-07-18
Posts: 161

error when trying to make local repository (solved)

i'm trying to make a local repository for a laptop without internet connection.

on my desktop, the packages are in /var/cache/pacman/pkg and the corresponding PKGBUILD in /var/lib/pacman/local. but whenever i run (as root)

#gensync /var/lib/pacman/local /var/cache/pacman/pkg/laptop.db.tar.gz

i get the following error:

gensync: building database entries, generating md5sums...
gensync: compressing to /var/cache/pacman/pkg/laptop.db.tar.gz...
tar: *: Cannot stat: No such file or directory
tar: Error exit delayed from previous errors

i can see the file laptop.db.tar.gz, but it's only 45 bytes!

Last edited by chilebiker (2007-04-18 20:52:37)


Don't panic!

Offline

#2 2007-04-18 15:21:12

gradgrind
Member
From: Germany
Registered: 2005-10-06
Posts: 921

Re: error when trying to make local repository (solved)

Are you confusing 'PKGBUILD' with the repository database? Normally PKGBUILDs won't be in /var/lib/pacman/local ...

Getting all the PKGBUILDs together is generally not so easy. That is why I have written a python script (gen_repo) to  build a ***.db.tar.gz without needing PKGBUILDs. cactus has also written one. You can get mine from the larch download page, or from the arch-wiki.

Offline

#3 2007-04-18 16:40:44

chilebiker
Member
From: Zurich, Switzerland
Registered: 2006-07-18
Posts: 161

Re: error when trying to make local repository (solved)

@gradgrind
i used your script already! smile
but unfortunately pacman complained about corrupted packages (which i copied from /var/cache/pacman/pkg).


Don't panic!

Offline

#4 2007-04-18 17:24:29

gradgrind
Member
From: Germany
Registered: 2005-10-06
Posts: 921

Re: error when trying to make local repository (solved)

Maybe you could describe what you are doing a bit more. What I gather is that you want to take the pacman cache from the desktop system and somehow (how?) use this to update (or install to?) a laptop.

You can make the desktop cache into a repository with gen_repo - but I forgot to say that you need to check that only a single version of each package is present in the cache (I think pacman -Sc should do that).

If the laptop and desktop are then connected, e.g. by lan, you can set pacman.conf on the laptop to point at this repository (e.g. using NFS). Or you can copy the repository to the laptop and set pacman.conf to point at it.

Another possibility would be to copy the pacman db (/var/lib/pacman/) to the laptop, and the package cache, then use pacman -S to install stuff. For that you don't need gen_repo, etc. Or you could just mount the desktop cache using NFS.

There are all sorts of possibilities ... did you have something particular in mind?

Offline

#5 2007-04-18 18:29:51

cactus
Taco Eater
From: t͈̫̹ͨa͖͕͎̱͈ͨ͆ć̥̖̝o̫̫̼s͈̭̱̞͍̃!̰
Registered: 2004-05-25
Posts: 4,622
Website

Re: error when trying to make local repository (solved)

are you using pacman 3?

if not, then you could try my script...maybe it will work....

http://cactuswax.net/projects/pygenrepo.html


"Be conservative in what you send; be liberal in what you accept." -- Postel's Law
"tacos" -- Cactus' Law
"t̥͍͎̪̪͗a̴̻̩͈͚ͨc̠o̩̙͈ͫͅs͙͎̙͊ ͔͇̫̜t͎̳̀a̜̞̗ͩc̗͍͚o̲̯̿s̖̣̤̙͌ ̖̜̈ț̰̫͓ạ̪͖̳c̲͎͕̰̯̃̈o͉ͅs̪ͪ ̜̻̖̜͕" -- -̖͚̫̙̓-̺̠͇ͤ̃ ̜̪̜ͯZ͔̗̭̞ͪA̝͈̙͖̩L͉̠̺͓G̙̞̦͖O̳̗͍

Offline

#6 2007-04-18 20:20:35

chilebiker
Member
From: Zurich, Switzerland
Registered: 2006-07-18
Posts: 161

Re: error when trying to make local repository (solved)

@cactus and gradgrind
both scripts work well, but that's not my problem!

i have an old laptop (no internet, no network) and my desktop with a fully functional arch. i did a install (latest 0.8) on the laptop with the x-server working. now i want to upgrade the system and install some applications.

my idea was to use my desktop's local repository to do that (with an external usb-hd). i failed with gensync (see first post), but the two mentioned scripts worked well to build the database. i updated /etc/pacman.conf on the laptop and can sync the database (on the usb-hd) with pacman -Sy. but as soon as i want to upgrade the system or install an application, i get a pacman error on every package while checking their integrity: error: archive blablabla.pkg.tar.gz is corrupted

i wonder why, as the same package seem to work on my desktop.


Don't panic!

Offline

#7 2007-04-18 20:56:44

chilebiker
Member
From: Zurich, Switzerland
Registered: 2006-07-18
Posts: 161

Re: error when trying to make local repository (solved)

i solved the problem by cleaning /var/cache/pacman/pkg on my laptop.

thanks for your help and those scripts!


Don't panic!

Offline

Board footer

Powered by FluxBB