Author Topic: <Solved>On creating a Local repository???  (Read 607 times)

Offline gezza

  • Hero Member
  • *****
  • Posts: 514
<Solved>On creating a Local repository???
« on: July 24, 2012, 01:52:21 AM »
ho to all,
I have suffered a lot of internet failures due to Telstra  upgrading their system.
Sometins it has been over 24 hours.
Soooo. I would like to rsync from aarnet.net.au to a local drive.
Could some kind folk give me the correct syntax, is rsync -aurv aarnet.net.au  /mnt/data
I used to do this many years ago,about 0.93 times,  but it has been wiped from my memory
Gezza
« Last Edit: December 05, 2012, 02:01:33 AM by gezza »

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8589
  • Aurum nostrum non est aurum vulgi.
Re: On creating a Local repository???
« Reply #1 on: July 24, 2012, 02:23:22 AM »
ho to all,
I have suffered a lot of internet failures due to Telstra  upgrading their system.
Sometins it has been over 24 hours.
Soooo. I would like to rsync from aarnet.net.au to a local drive.
Could some kind folk give me the correct syntax, is rsync -aurv aarnet.net.au  /mnt/data
I used to do this many years ago,about 0.93 times,  but it has been wiped from my memory
Gezza

You could try:

rsync -av --progress --delete --exclude=SRPM*/ mirror.aarnet.edu.au:pclinuxos/pclinuxos/apt/pclinuxos/2010/  /mnt/data
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10644
  • MLUs Forever!
Re: On creating a Local repository???
« Reply #2 on: July 24, 2012, 04:09:51 AM »
I suggest you use something like Grsync which will allow you to edit the 'extra' options and do a dummy run etc to see what you will download.
Also suggest you use  /mnt/Data/ Local_Repository  or some such to keep all the files/directories in their own sub-folder.

Be aware that some mirrors do not respond to rsync ....  they do not have that function. When doing a dummy run, if that is the case it will report it.

Here is one command I used in Grsync which excluded a whole lot of stuff like different language options for Firefox and repository sections I did not need at the time ...

Code: [Select]
rsync -r -n -t -p -o -g -v --progress -l --partial --numeric-ids --delete --exclude=SRPMS.* --exclude=RPMS.unstable --exclude=RPMS.xfce4 --exclude=base/*.unstable* --exclude=base/*.xfce4* --exclude=base/srclist.* --exclude=firefox-a* --exclude=firefox-b* --exclude=firefox-c* --exclude=firefox-d?-* --exclude=firefox-el* --exclude=firefox-eo* --exclude=firefox-es* --exclude=firefox-et* --exclude=firefox-eu* --exclude=firefox-f* --exclude=firefox-gl* --exclude=firefox-gu* --exclude=firefox-gd* --exclude=firefox-h* --exclude=firefox-i* --exclude=firefox-j* --exclude=firefox-k* --exclude=firefox-l* --exclude=firefox-m* --exclude=firefox-n* --exclude=firefox-o* --exclude=firefox-p* --exclude=firefox-q* --exclude=firefox-r* --exclude=firefox-s* --exclude=firefox-t* --exclude=firefox-u* --exclude=firefox-v* --exclude=firefox-w* --exclude=firefox-x* --exclude=firefox-y* --exclude=firefox-z* --exclude=mozilla-thunderbird-a* --exclude=mozilla-thunderbird-b* --exclude=mozilla-thunderbird-c* --exclude=mozilla-thunderbird-d?-* --exclude=mozilla-thunderbird-el* --exclude=mozilla-thunderbird-eo* --exclude=mozilla-thunderbird-es* --exclude=mozilla-thunderbird-et* --exclude=mozilla-thunderbird-eu* --exclude=mozilla-thunderbird-f* --exclude=mozilla-thunderbird-gl* --exclude=mozilla-thunderbird-gu* --exclude=mozilla-thunderbird-gd* --exclude=mozilla-thunderbird-h* --exclude=mozilla-thunderbird-i* --exclude=mozilla-thunderbird-j* --exclude=mozilla-thunderbird-k* --exclude=mozilla-thunderbird-l* --exclude=mozilla-thunderbird-m* --exclude=mozilla-thunderbird-n* --exclude=mozilla-thunderbird-o* --exclude=mozilla-thunderbird-p* --exclude=mozilla-thunderbird-q* --exclude=mozilla-thunderbird-r* --exclude=mozilla-thunderbird-s* --exclude=mozilla-thunderbird-t* --exclude=mozilla-thunderbird-u* --exclude=mozilla-thunderbird-v* --exclude=mozilla-thunderbird-w* --exclude=mozilla-thunderbird-x* --exclude=mozilla-thunderbird-y* --exclude=mozilla-thunderbird-z* ftp.heanet.ie::pub/pclinuxos/apt/pclinuxos/2010/ /media/1.5TB/32bit_Repository/pclinuxos/2010/
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline craesz

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 978
Re: On creating a Local repository???
« Reply #3 on: July 24, 2012, 05:31:32 AM »
I suggest you use something like Grsync which will allow you to edit the 'extra' options and do a dummy run etc to see what you will download.
Also suggest you use  /mnt/Data/ Local_Repository  or some such to keep all the files/directories in their own sub-folder.

Be aware that some mirrors do not respond to rsync ....  they do not have that function. When doing a dummy run, if that is the case it will report it.

Here is one command I used in Grsync which excluded a whole lot of stuff like different language options for Firefox and repository sections I did not need at the time ...

Code: [Select]
rsync -r -n -t -p -o -g -v --progress -l --partial --numeric-ids --delete --exclude=SRPMS.* --exclude=RPMS.unstable --exclude=RPMS.xfce4 --exclude=base/*.unstable* --exclude=base/*.xfce4* --exclude=base/srclist.* --exclude=firefox-a* --exclude=firefox-b* --exclude=firefox-c* --exclude=firefox-d?-* --exclude=firefox-el* --exclude=firefox-eo* --exclude=firefox-es* --exclude=firefox-et* --exclude=firefox-eu* --exclude=firefox-f* --exclude=firefox-gl* --exclude=firefox-gu* --exclude=firefox-gd* --exclude=firefox-h* --exclude=firefox-i* --exclude=firefox-j* --exclude=firefox-k* --exclude=firefox-l* --exclude=firefox-m* --exclude=firefox-n* --exclude=firefox-o* --exclude=firefox-p* --exclude=firefox-q* --exclude=firefox-r* --exclude=firefox-s* --exclude=firefox-t* --exclude=firefox-u* --exclude=firefox-v* --exclude=firefox-w* --exclude=firefox-x* --exclude=firefox-y* --exclude=firefox-z* --exclude=mozilla-thunderbird-a* --exclude=mozilla-thunderbird-b* --exclude=mozilla-thunderbird-c* --exclude=mozilla-thunderbird-d?-* --exclude=mozilla-thunderbird-el* --exclude=mozilla-thunderbird-eo* --exclude=mozilla-thunderbird-es* --exclude=mozilla-thunderbird-et* --exclude=mozilla-thunderbird-eu* --exclude=mozilla-thunderbird-f* --exclude=mozilla-thunderbird-gl* --exclude=mozilla-thunderbird-gu* --exclude=mozilla-thunderbird-gd* --exclude=mozilla-thunderbird-h* --exclude=mozilla-thunderbird-i* --exclude=mozilla-thunderbird-j* --exclude=mozilla-thunderbird-k* --exclude=mozilla-thunderbird-l* --exclude=mozilla-thunderbird-m* --exclude=mozilla-thunderbird-n* --exclude=mozilla-thunderbird-o* --exclude=mozilla-thunderbird-p* --exclude=mozilla-thunderbird-q* --exclude=mozilla-thunderbird-r* --exclude=mozilla-thunderbird-s* --exclude=mozilla-thunderbird-t* --exclude=mozilla-thunderbird-u* --exclude=mozilla-thunderbird-v* --exclude=mozilla-thunderbird-w* --exclude=mozilla-thunderbird-x* --exclude=mozilla-thunderbird-y* --exclude=mozilla-thunderbird-z* ftp.heanet.ie::pub/pclinuxos/apt/pclinuxos/2010/ /media/1.5TB/32bit_Repository/pclinuxos/2010/
nice.... very nice.
Desktop1: AMD64 8450 [3 core]; 8GB; 3.2.18-pclos2.pae.bfs; KDE
Desktop2: AMD64 5400 [8 core]; 16GB; 3.2.16-a64; KDE
Netbook: EeePC 901; Atom N270; 1GB; 2.6.33.7-pclos6.bfs; KDE


Offline menotu

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 15296
  • ┌∩┐(◕_◕)┌∩┐
Re: On creating a Local repository???
« Reply #4 on: July 24, 2012, 10:26:46 AM »
That's some line of code J18  ;D
=======================

sync -r -n -t -p -o -g -v --progress -l --partial --numeric-ids --delete --exclude=SRPMS.*
--exclude=RPMS.unstable --exclude=RPMS.xfce4 --exclude=base/*.unstable*
--exclude=base/*.xfce4* --exclude=base/srclist.* --exclude=firefox-a* --exclude=firefox-b*
--exclude=firefox-c* --exclude=firefox-d?-* --exclude=firefox-el* --exclude=firefox-eo*
--exclude=firefox-es* --exclude=firefox-et* --exclude=firefox-eu* --exclude=firefox-f*
--exclude=firefox-gl* --exclude=firefox-gu* --exclude=firefox-gd* --exclude=firefox-h*
--exclude=firefox-i* --exclude=firefox-j* --exclude=firefox-k* --exclude=firefox-l*
--exclude=firefox-m* --exclude=firefox-n* --exclude=firefox-o* --exclude=firefox-p*
--exclude=firefox-q* --exclude=firefox-r* --exclude=firefox-s* --exclude=firefox-t*
--exclude=firefox-u* --exclude=firefox-v* --exclude=firefox-w* --exclude=firefox-x*
--exclude=firefox-y* --exclude=firefox-z* --exclude=mozilla-thunderbird-a*
--exclude=mozilla-thunderbird-b* --exclude=mozilla-thunderbird-c*
--exclude=mozilla-thunderbird-d?-* --exclude=mozilla-thunderbird-el*
--exclude=mozilla-thunderbird-eo* --exclude=mozilla-thunderbird-es*
--exclude=mozilla-thunderbird-et* --exclude=mozilla-thunderbird-eu*
--exclude=mozilla-thunderbird-f* --exclude=mozilla-thunderbird-gl*
--exclude=mozilla-thunderbird-gu* --exclude=mozilla-thunderbird-gd*
--exclude=mozilla-thunderbird-h* --exclude=mozilla-thunderbird-i*
--exclude=mozilla-thunderbird-j* --exclude=mozilla-thunderbird-k*
--exclude=mozilla-thunderbird-l* --exclude=mozilla-thunderbird-m*
--exclude=mozilla-thunderbird-n* --exclude=mozilla-thunderbird-o*
--exclude=mozilla-thunderbird-p* --exclude=mozilla-thunderbird-q*
--exclude=mozilla-thunderbird-r* --exclude=mozilla-thunderbird-s*
--exclude=mozilla-thunderbird-t* --exclude=mozilla-thunderbird-u*
--exclude=mozilla-thunderbird-v* --exclude=mozilla-thunderbird-w*
--exclude=mozilla-thunderbird-x* --exclude=mozilla-thunderbird-y*
--exclude=mozilla-thunderbird-z* ftp.heanet.ie::pub/pclinuxos/apt/pclinuxos/2010/
/media/1.5TB/32bit_Repository/pclinuxos/2010/
PCLinuxOS 32bit KDE 4.10.1; kernel-3.4.11-pclos1.bfs & 64bit 3.2.18bfs; NVidia GeForce 8400GS 1GB 310.19 driver

Sony Vaio SVE1513A4ESI Laptop, Intel Core i5, 2.6GHz, 6GB RAM, 750GB, 15.6" Intel HD Graphics 4000

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8589
  • Aurum nostrum non est aurum vulgi.
Re: On creating a Local repository???
« Reply #5 on: July 24, 2012, 10:33:59 AM »
Oh hell yeah ... just from looking at it, I bet he'd finish his rsync before he finishes typing all that!  ;D
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline menotu

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 15296
  • ┌∩┐(◕_◕)┌∩┐
Re: On creating a Local repository???
« Reply #6 on: July 24, 2012, 10:45:16 AM »
Oh hell yeah ... just from looking at it, I bet he'd finish his rsync before he finishes typing all that!  ;D

 ;D ;D

Have to rsync "the code" to it's own HDD  :)
PCLinuxOS 32bit KDE 4.10.1; kernel-3.4.11-pclos1.bfs & 64bit 3.2.18bfs; NVidia GeForce 8400GS 1GB 310.19 driver

Sony Vaio SVE1513A4ESI Laptop, Intel Core i5, 2.6GHz, 6GB RAM, 750GB, 15.6" Intel HD Graphics 4000

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10644
  • MLUs Forever!
Re: On creating a Local repository???
« Reply #7 on: July 24, 2012, 01:58:25 PM »
Ah!  the benefits of Grsync ....  which retains all those 'excludes' and keeps my local mirror a reasonable size  :D

...  and of course I have multiple such commands all kept by Grsync, so I neither have to remember nor type them  ;)

just as well ....  it is difficult enought to remember to launch Grsync!   ::)
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline gezza

  • Hero Member
  • *****
  • Posts: 514
Re: On creating a Local repository???
« Reply #8 on: July 24, 2012, 04:47:15 PM »
Thanks Guys,
This will enable me, yet again.
I will copy all the replies to a text file then copy them to the screen to rsync.
Gezza

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8589
  • Aurum nostrum non est aurum vulgi.
Re: On creating a Local repository???
« Reply #9 on: July 24, 2012, 09:02:50 PM »
This is a wonderful thread ... it always is with Just18 and menotu. :D
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline gezza

  • Hero Member
  • *****
  • Posts: 514
Re: On creating a Local repository???
« Reply #10 on: July 25, 2012, 04:15:39 PM »
hi,
I now have a local repository. But....I cannot get it to work!!!
I have the local mounted on /mnt/data750/pclinuxos
what i need now is--what do I put in the repository table in 'synaptic'?
No matter what I put in, it generates an error. A line 39-41 error.
Apart from this, the rsync from Heanet just works, but I cannot get aarnet to function at all.
I have tried 'ftp', 'http; front end but no go. Any thoughts?
Gezza

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10644
  • MLUs Forever!
Re: On creating a Local repository???
« Reply #11 on: July 25, 2012, 04:26:05 PM »
file:///mnt/data750/pclinuxos

is the format of the first line in Synaptic.

Quote
Apart from this, the rsync from Heanet just works, but I cannot get aarnet to function at all.
I have tried 'ftp', 'http; front end but no go. Any thoughts?

As I previously posted, some mirrors do not support rsync ......  have you checked whether that one does or not?

MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8589
  • Aurum nostrum non est aurum vulgi.
Re: On creating a Local repository???
« Reply #12 on: July 25, 2012, 10:34:05 PM »
file:///mnt/data750/pclinuxos

is the format of the first line in Synaptic.

Quote
Apart from this, the rsync from Heanet just works, but I cannot get aarnet to function at all.
I have tried 'ftp', 'http; front end but no go. Any thoughts?

As I previously posted, some mirrors do not support rsync ......  have you checked whether that one does or not?



Are you sure? Mine use only one slash after file.

If Just18's suggestion have problems, try

Code: [Select]
file:/mnt/data750/pclinuxos
Check the child folders of your mounted repository. I suspect your URI might be more than what you posted. It could even be:

Code: [Select]
file:/mnt/data750/pclinuxos/pclinuxos/apt  the complete address should be before the pclinuxos/2010 folder.
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10644
  • MLUs Forever!
Re: On creating a Local repository???
« Reply #13 on: July 26, 2012, 01:51:05 AM »
Quote
Are you sure? Mine use only one slash after file.


Yes one slash should also work, but two won't.

http://
ftp://
file://<mount point>  is the way I have always entered it.

file:<mount point>  will also work

I guess I just have the habit of using the full  file://   ;)

Maybe I have been wrong all along .....  :D

MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline pupthai

  • Hero Member
  • *****
  • Posts: 1425
  • PCLinuxOS 2011 2 - KDE4
Re: On creating a Local repository???
« Reply #14 on: July 26, 2012, 05:00:39 AM »
Some things to consider -

You can write your rsync command into a bash script and for the excludes you can use a text file to list them and rsync will check it when it runs.

--exclude-from=FILE
    This option is related to the --exclude option, but it specifies a FILE that contains exclude patterns (one per line). Blank lines in the file and lines starting with ';' or '#' are ignored. If FILE is -, the list will be read from standard input.  Easy to edit the text file and not change the script.

Check out the rsync web site.  http://rsync.samba.org/ftp/rsync/rsync.html

 
PCLinuxOS 2011 2 - KDE4
Intel 2 core duo @3.22gig, Asus P5G41/M, DDR2/1066 4gig, ENGT220 DDR3/1gig, 2x Seagate 250gig.