# Syncing with AOSP Question



## doobie711 (Jan 24, 2012)

I live in the boonies and get no good ISPs because the telephone company for my area has a monopoly on the lines my down speed is about 1.5 Mbps. I've had a terrible time trying to sync the past two days with intermittent freezes and all kinds of loss of connection. While I am downloading the source I rarely see higher than 40 KiB/s. Is this what I should expect or should it be closer to my downspeed of approx. 200 KiB/s. Are multiple files being downloading simultaneously for the source?


----------



## imnuts (Jun 9, 2011)

Try running "repo sync -j1". By default, it runs at -j4. It may help you out some in syncing. It should run close to your max download speed, but if it is syncing multiple items at once, you may not see it going faster than 40-50KBps if it is running 4 downloads at once. Still won't come down fast, but it should prevent it from stopping mid-sync for you.


----------



## doobie711 (Jan 24, 2012)

Thank you for the reply. This honestly looks like the most difficult part for me in building. I have gotten the sync started again but if it fails I will try to sync with that parameter. My biggest problem is the ISP right now. My modem kept reporting an incorrect username and password when nothing has changed in two years. I'll be giving them a ring tomorrow. Or make my way to a library or college to finish this.


----------



## imnuts (Jun 9, 2011)

The initial source sync will be the longest, and if you have a slow connection, the hardest one to complete. After that, syncing shouldn't be as difficult because you will be getting just the incremental updates rather than EVERYTHING since the source repositories were started.


----------



## doobie711 (Jan 24, 2012)

Browsing through branches I figured the only thing I need right now is the latest branch so I can just make sure I'm doing it right. from this time onwards I'll be visiting a friend with a T1 connection.


----------



## imnuts (Jun 9, 2011)

The first sync will download all branches for a given manifest that you're syncing against. If you switch to a new branch later, it won't have to download anything new unless there are updates, or the new branch has new repositories to sync compared to what you were on previously.


----------



## doobie711 (Jan 24, 2012)

using -j1 didn't help. while fetching prebuild it just hangs indefinitely. this is likely a network issue so nothing to see here. moving on. it just wasn't meant to be.


----------



## imnuts (Jun 9, 2011)

prebuilt is the largest directory to sync, followed by frameworks/base I believe. If you're on a slow connection, it would definitely be hard to sync.


----------



## JBirdVegas (Jun 11, 2011)

imnuts said:


> The first sync will download all branches for a given manifest that you're syncing against. If you switch to a new branch later, it won't have to download anything new unless there are updates, or the new branch has new repositories to sync compared to what you were on previously.


If you include the -b ics flag in repo init (depending on where you are repoing, master is aosp main public dev branch from which public tags are based) then you won't get all branches... you will get tags but you won't get gb and eclair branches of projects.


----------



## doobie711 (Jan 24, 2012)

Thanks to imnuts for mentioning changing how many jobs are running simultaneously. and to JBirdVegas I had started just syncing 4.0.4r2.1 since it was the newest and including building for toro. I did eventually give up since I was missing GnuPG and make and quite a few other things. I have deleted the dmg that housed the source quite a few times and am now on my third time downloading it. I expect it to be done sometime tomorrow afternoon as I think the only thing I lack is the tuna branch and the prebuilt. I am in the lowest 10% of connection speeds nationally according to speedtest, but I would really like to get into updating through AOSP despite that shortcoming.


----------

