Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Portage with p2p
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3, 4, 5, 6  Next  
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
panserg
Apprentice
Apprentice


Joined: 16 Apr 2003
Posts: 188

PostPosted: Thu Aug 28, 2003 9:49 pm    Post subject: Reply with quote

is there any p2p protocol that is transparent for a typical http-proxy? The best woul be a p2p based on a wedav server.
_________________
Less is more!
Back to top
View user's profile Send private message
Sieg
Tux's lil' helper
Tux's lil' helper


Joined: 07 Oct 2002
Posts: 87

PostPosted: Fri Aug 29, 2003 12:29 pm    Post subject: Reply with quote

dasalvagg wrote:
I've never heard of a 1gig upload limit, but maybe i'm just sheltered.


Welcome to ISPs of the Montreal (Canada) area! :) At least things are finally starting to change for the better, but it's been like that for years for some of the major ISPs.
Back to top
View user's profile Send private message
delta407
Bodhisattva
Bodhisattva


Joined: 23 Apr 2002
Posts: 2876
Location: Chicago, IL

PostPosted: Fri Aug 29, 2003 12:44 pm    Post subject: Reply with quote

ebrostig wrote:
Currently no P2P application has a good solution for people behind firewalls, esp restrictive ones like the one I'm behind.
Freenet is working on this, and it would meet most of the criteria here -- however, it's probably a sub-optimal solution.

From what I remember of a discussion about this on the Freenet mailing lists a few months ago, there are two cases. One is a NAT "firewall", the other is a true packet filter. For puncturing the NAT, they looked at multiplayer games: when joining a game, for instance, your computer opens a UDP socket and sends a packet out on a specific port to some computer. Since [most] NATs use a SEND/RECEIVE mechanism, this establishes a state change, and any incoming UDP packets to that port but not necessarily from the original peer are allowed in. That is, the other players can talk to you on that port, even if you didn't talk to them yet.

The other situation is a packet filter. This gets worse. If you have the option to, a workaround would be to use, say, SSH to do remote connection forwarding to a remote machine. The node would advertise the remote, unfirewalled machine's address as its own, and when the remote SSHD got a connection to the Freenet port, it would send it through the SSH tunnel. Another option was to masquerade as HTTP traffic (there are programs that do this) -- using some distributed tracking system to establish numerous outbound connections, as this system would be unable to have inbound connections.

Of course, this is Freenet, and none of these ideas have been implemented. :roll: But still, in most cases, there are ways of doing this.
_________________
I don't believe in witty sigs.
Back to top
View user's profile Send private message
dasalvagg
Apprentice
Apprentice


Joined: 26 Jun 2002
Posts: 183
Location: NY

PostPosted: Sat Aug 30, 2003 2:51 pm    Post subject: Reply with quote

In an e-mail to a Gentoo dev I received this response about protocols.
Fred Van Andel wrote:
For various reasons the existing p2p networks are not suitable for gentoo.


What do people think about a new protocol. He also sent me a write-up of what the new protocol would entail, but asked that I not release it until it could be polished up a little more. I see benifits from using already proven systems....
Back to top
View user's profile Send private message
fava
Retired Dev
Retired Dev


Joined: 27 Sep 2002
Posts: 8

PostPosted: Sat Aug 30, 2003 9:53 pm    Post subject: Network requirements Reply with quote

Regarding Bittorrent:
Bitorrent requires a separate instance and a separate port for every file that you are sharing. When some people will be sharing hundreds of files this is simply not a workable approach.

Bittorent is optimized towards dealing with a small number of large files under very high (initial) demand situations. Our needs are a little different, we are dealing with large number of much smaller files under moderate demand and without the initial spike in demand.

In General:
The content of the network needs to be tightly controlled. We are dealing with source code here and the consequences of someone being able to inject malicious code or malicious files into the network would be unthinkable. Therefore ALL files on the network MUST be vetted by a central server, and ONLY files allowed by the central server would be allowed on the network. All files transfered over the network MUST be checked to make sure that they match the checksums of the authorized files.

I also want to create a network that is 100% legal content so that when the RIAA or MPAA goes on a rampage we will be unaffected.

As far as I know there are no p2p networks that allow this much central control, the trend in p2p networks is away from central controll because of liability issues.
Back to top
View user's profile Send private message
mmealman
Guru
Guru


Joined: 02 Nov 2002
Posts: 348
Location: Florida

PostPosted: Sat Aug 30, 2003 10:38 pm    Post subject: Reply with quote

The p2p protocol should only share files that match a master list kept at an official Gentoo mirror with the proper checksums.

Also, the protocol should be limitable in various ways even beyond simple bandwidth throttling.

For example, if my server is on a 100Mbs line with a 150GB monthly limit and a 95% rate at 256k, I'd have no problems at all letting the p2p burst at high rates so long as I could control the frequency and monthly upload GBs.

The upload bandwidth usage need to be very customizable, controllable and monitorable if admins are going to use it.
Back to top
View user's profile Send private message
syko
n00b
n00b


Joined: 15 Jul 2003
Posts: 36
Location: Alberta, Canada

PostPosted: Sun Aug 31, 2003 1:22 am    Post subject: Reply with quote

It definitely could not be anything but an option, and it would have to be disabled by default. I like the idea, and the plan, but with my 2GB upload cap (not quite the 1GB of others, but still pretty low) I wouldn't be able to participate 24/7.

I think it all depends on continuing to use the standard gentoo mirrors, in addition to a network like this. If a p2p system would offer more benefits, then more and more people would use it, reducing the load on the primary servers, and allowing corporations, and others who cannot use a p2p network for whatever reason to use a less bogged-down standard http or ftp server.
Back to top
View user's profile Send private message
dasalvagg
Apprentice
Apprentice


Joined: 26 Jun 2002
Posts: 183
Location: NY

PostPosted: Sun Aug 31, 2003 11:19 pm    Post subject: Reply with quote

so...looks like everyone is in agreement that this would be great for gentoo. Anyone willing to help out fava? Everytime i think about it, it seems like a larger project.....
Back to top
View user's profile Send private message
ebrostig
Bodhisattva
Bodhisattva


Joined: 20 Jul 2002
Posts: 3152
Location: Orlando, Fl

PostPosted: Mon Sep 01, 2003 12:15 am    Post subject: Reply with quote

I don't think it necessarily is good unless this is a second option and it can work with any kind of firewall or proxy and not require specific ports to be opened.

I also feel it is not a good thing if it would require people to host parts of portage nor do I see how syncing of Portage is going to work nor a lot of other things.

Please work out a detailed description prioor to starting and coordinate it with the developers prior to start any coding.

Erik
_________________
'Yes, Firefox is indeed greater than women. Can women block pops up for you? No. Can Firefox show you naked women? Yes.'
Back to top
View user's profile Send private message
dasalvagg
Apprentice
Apprentice


Joined: 26 Jun 2002
Posts: 183
Location: NY

PostPosted: Mon Sep 01, 2003 3:14 pm    Post subject: Reply with quote

Have you read the previous posts?

Firewalls...you're not the largest part of the population. Purpose is to get a good number on it, not necessarlly 100%. Do what is easy first, then add help for others.

Syncing.....was never brought up. This is for distfiles.
Back to top
View user's profile Send private message
fava
Retired Dev
Retired Dev


Joined: 27 Sep 2002
Posts: 8

PostPosted: Mon Sep 01, 2003 4:06 pm    Post subject: Reply with quote

Quote:
I don't think it necessarily is good unless this is a second option and it can work with any kind of firewall or proxy and not require specific ports to be opened.

I also feel it is not a good thing if it would require people to host parts of portage nor do I see how syncing of Portage is going to work nor a lot of other things.

Please work out a detailed description prioor to starting and coordinate it with the developers prior to start any coding.


It WILL be optional not required.

Making it work transparently through a firewall in non trivial and would require much more resources on the central server. Every client would need to keep an open port with the central server at all times. This might happen in the future, but not initally.

It WILL NOT affect portage, it will ONLY affect the distfiles directory. Emerge sync will not work via p2p, the security implications rule that out.

I am a developer, I am also writing the code. Do I need to coordinate with myself?

As a general note:
I am currently writing "proof of concept" code for this. When this code has enough basic functionality to actually do something usefull it (and the specification) will be posted and development opened up to anyone who wants to help.
Back to top
View user's profile Send private message
progster
Apprentice
Apprentice


Joined: 16 Jul 2002
Posts: 271

PostPosted: Mon Sep 01, 2003 4:45 pm    Post subject: Reply with quote

If it wasn't optional I think gentoo wouldn't run on any servers anymore, as traffic costs money. Also p2p networks are not that great for cable users (fast download but slow upload), for some reason the slow upload speed actually slows down downloads on p2p networks (especially bittorrent)

~progster
Back to top
View user's profile Send private message
pytigger
Tux's lil' helper
Tux's lil' helper


Joined: 27 Aug 2003
Posts: 134
Location: Hanover, Germany

PostPosted: Mon Sep 01, 2003 6:43 pm    Post subject: Reply with quote

There has been a discussion about improving portage in general, and one of these things is making the download / build process parallel. That would smooth out a few speed issues.

The packages that are downloaded must be verified. One solution might be to check a checksum from portage or any trustable mirror (or even more than one). Gnutella would thus be quite usable (but keeping clear of any traditional Gnutella networks of course).
The problem is, that some lamers could probably modify gnutella or any other protocol to name the correct checksum before downloading, instead of the real checksum from the modified packages. Both with multiple and single source downloading portage would have to wait until the download is complete to see there was a corrupted file download.

And, of Course, the P2P thing has to be kept secure. IP revealance is not really relevant, since we all spread our IP around the net anyway, except maybe some who notoriously use proxys / routes to remain anonymous.
It must be made sure that users don't have security holes activated. There should be documentation about various aspects of possible misconfigurations etc.
_________________
And by the way - Gentoo needs an official WIKI!!
Back to top
View user's profile Send private message
dasalvagg
Apprentice
Apprentice


Joined: 26 Jun 2002
Posts: 183
Location: NY

PostPosted: Mon Sep 01, 2003 9:22 pm    Post subject: Reply with quote

Checksums and the like could be downloaded from a central server everytime a file is downloaded from the p2p system. Or it could be included from an rsync, which would be out of the scope of the p2p system. Either method makes certain that an outside source is available to verify the integrity of the file.
Back to top
View user's profile Send private message
srob99
n00b
n00b


Joined: 14 Oct 2003
Posts: 48
Location: Perth WA

PostPosted: Tue Nov 04, 2003 8:21 am    Post subject: bittorrent (protocol) is perfect Reply with quote

People have mentioned that bittorrent requires a separate port and instance for each file - as the main argument against bittorrent.
Sure.. that is for the official bittorrent client. Keep in mind that bittorrent is also a defined open protocol. We are completely allowed to create our own client (which is still bittorrent compliant), but which uses a single port and a single process. For example, see mldonkey's bittorrent implementation. It works reasonably flawlessly, i'm down/uploading about 4 completely different bittorrent streams (each one using a completely different tracker too) to various people/IPs, and only need one process of mldonkey. I also only have one port open on the firewall for bittorrent.

For a Gentoo implementation, the "bittorrent distfiles" service would need to be optionally activated from /etc/init.d in a runlevel, and emerge (with appropriate command-line options to enable this mode) would somehow need to tell the bittorrent client to add a particular package to its "list" of files to download/upload. emerge would then need to have a way of knowing when the download is complete, so it can continue on it's merry way. The bittorrent service, in the mean time, is sitting there day in, day out helping everybody else with all the files in /usr/portage/distfiles that it can find a valid tracker at gentoo.org for.

Probably another fairly important required feature would be bandwidth control, in particular for upstream. eg a modem user would probably want to limit the upstream to 1k/s if he/she wants to anything else useful with the link. still, each 1k/s that people offer is 1k/s less that a mirror has to provide!

Security concerns are of course a non-issue with the bittorrent protocol, as each 256k block is hash protected, the hashes are stored on the central tracker, and the official trackers would be run by gentoo.org (a custom tracker server would need to be created that could track multiple bittorrent streams at the same time, but this is probably already done. [haven't looked at bittorrent tracker for a while])

Indeed, a "bittorrent gentoo distfiles client" project would be a great idea to reduce official mirror bandwidth requirements around the world, but still does not tackle the issue of actual storage volume required on the official mirrors! (which of course still need to be maintained, as they are the backbone of gentoo!! - a P2P distfiles system is only useful as an add-on to those who actually want to "rc-update add " [and start] the service.)
Back to top
View user's profile Send private message
pookey
Tux's lil' helper
Tux's lil' helper


Joined: 03 Sep 2003
Posts: 88
Location: UK

PostPosted: Sat Mar 06, 2004 2:30 pm    Post subject: Portage with p2p Reply with quote

I had an idea a few days ago, and thought I should voice it here, perhaps someone might have an opinion about it.

When someone compiles a program, it is packageed up, and some kinda hash is makes of the compile and use flags for that package, and this file is stored somewhere on the file system. This file could then be made availible on the peer to peer network for others with the same use/compile flags to download, which would be a lot quicker then compiling it, but would achive the same goal.

This idea might see a little insecure, as someone could build a nasty package. I've not really come up with a conclusion on how to get around this. Perhaps a package wouldn't be considered valid untill there are 10+ sources for it, but even then that's no real security.

I don't have the time or the skills needed to set the ball rolling on this unfortunatly. but If anyone has any ideas on this, I would be interested to read any feedback.
Back to top
View user's profile Send private message
Earthwings
Bodhisattva
Bodhisattva


Joined: 14 Apr 2003
Posts: 7753
Location: Germany

PostPosted: Sat Mar 06, 2004 4:49 pm    Post subject: Re: Portage with p2p Reply with quote

pookey wrote:
This idea might see a little insecure, as someone could build a nasty package. I've not really come up with a conclusion on how to get around this.

You found the problem by yourself. And there is no secure solution to this.

If you're looking for a good way to speed up compiling in a net of trusted computers (e.g. your LAN), have a look at distcc.
Back to top
View user's profile Send private message
pookey
Tux's lil' helper
Tux's lil' helper


Joined: 03 Sep 2003
Posts: 88
Location: UK

PostPosted: Sat Mar 06, 2004 5:15 pm    Post subject: Re: Portage with p2p Reply with quote

Earthwings wrote:

You found the problem by yourself. And there is no secure solution to this.


There is a way this could be done securly, just one idea that pops into my head with very little though is a trusted server compiling it and comparing the packages, and then a md5 sum could be distributed toe clients conneting to the p2p distribution network

Earthwings wrote:
If you're looking for a good way to speed up compiling in a net of trusted computers (e.g. your LAN), have a look at distcc.


I'm not talking aobt speeding up compiling for me, I already know about distcc and ccache. I'm talking about speeding up the installation and compilation for*all*users.

This system could easily piggyback on BitTorrent (which I beleive is also mostly written in python.
Back to top
View user's profile Send private message
Earthwings
Bodhisattva
Bodhisattva


Joined: 14 Apr 2003
Posts: 7753
Location: Germany

PostPosted: Sat Mar 06, 2004 5:46 pm    Post subject: Re: Portage with p2p Reply with quote

pookey wrote:
There is a way this could be done securly, just one idea that pops into my head with very little though is a trusted server compiling it and comparing the packages, and then a md5 sum could be distributed toe clients conneting to the p2p distribution network

That is quite different to your first idea. You mean you want to setup a binary server with low traffic costs because its files are spread by p2p networks. Please search the forums why there are no official binary servers. For an unofficial server see http://chinstrap.alternating.net/index.html
The main problem will be to find such servers. Don't forget that to support an application with 5 use flags and, say, the very little of 10 different CFLAG-settings, you get 2^5 * 10 = 320 different versions of one single package. Gentoo has about 6000 ebuilds.
Back to top
View user's profile Send private message
pookey
Tux's lil' helper
Tux's lil' helper


Joined: 03 Sep 2003
Posts: 88
Location: UK

PostPosted: Sat Mar 06, 2004 6:35 pm    Post subject: Re: Portage with p2p Reply with quote

Earthwings wrote:
That is quite different to your first idea.


Same idea, just better explained I think :)

The fact that there are multiple options for each package shoudln't really be much of an issue IMO. I imagine most people use very similar cflags/use options. Obviously the more people using it, the faster it will be to download from p2p.

A group of trusted signers could be formed, signing packages and distributing the pgp detached signature via some kinda interface (perhaps XML) to a website. When someone wants to download something, they could query this server, obtaining the signature, and then downloading from some kinda p2p network.

Perhaps I'm on my own thinking this is a good idea.... i just thoguht I would share it.
Back to top
View user's profile Send private message
sanity
n00b
n00b


Joined: 19 May 2002
Posts: 39
Location: Iowa

PostPosted: Fri Mar 12, 2004 12:18 am    Post subject: bittorrent or gnutella, other considerations Reply with quote

One nice thing about Gnutella, last I checked, is that they actually use HTTP as the transfer protocol, to the extent that if your Gnutella client cooperates, you can actually browse it from a Web browser.

However, Bittorrent provides a single place to get both the file verification and a way to get mirrors -- the .torrent. I have no idea how it's implemented.

Freenet might actually solve both problems -- I'm not sure if it's transparent to proxies, but it certainly allows for entirely p2p operation (no censorship possible, so no worries from RIAA) while assuring data integrity.

Unfortunately, Freenet is written in Java and is very slow and buggy. We'd have to write our own client.

Clients to anything except Konspire2b can download from behind a firewall, but not necessarily upload. It's not too hard to imagine a client which allows no uploads at all -- in fact, giFT allows one to set the maximum number of simultaneous uploads to 0.

If we were to implement our own client, we'd want to make sure it's generic. And if we do that, there's no point without first considering all alternatives -- even Kazaa (FastTrack) via giFT!

Finally, remember that data integrity means we have to sign packages. Downloading an md5 over rsync is not secure -- "some lamer" can intercept your rsync connection just as easily as your p2p connection. There are plans to implment such signing, although I have no idea what progress has been made.

And if we are going to do this for distfiles, it might be nice to also do it for sync, somehow. We'd want a p2p network that scales well to small files, of course, but rsync really doesn't have much point, as we usually update whole files anyway. The advantage of rsync is it's efficient at updating lots of small files, and only the new ones. But everything we do over rsync, if we are signing the portage tree, makes more sense over p2p, if it could be made fast enough.
Back to top
View user's profile Send private message
epall
Tux's lil' helper
Tux's lil' helper


Joined: 16 May 2004
Posts: 77
Location: Silicon Valley, CA, USA

PostPosted: Sun May 16, 2004 4:33 am    Post subject: anything new? Reply with quote

I thought up pretty much the same idea as has been outlined here a few days ago and came to investigate. As far as I can tell, a bunch of work was done in the Summer of 2003, and then everybody walked away. Is this true? I'm very interested in supporting this in any way I can, but not alone. Is there still interest in this?

One thought I had was that bittorrent may not be the right protocol to use for this. I don't think we should use something like gnutella, in which the goal is one giant swarm, but bittorrent isn't that good for the thousands of tiny distfiles that gentoo has. I propose we consider OpenNap, because it provides the isolated(ish) network that we get with bittorrent, but is far better suited to exchanging many small files. I admit, there still is the issue of large files, because downloading from only one peer is not very good. Maybe we should create our own protocol that's a hybrid?
Back to top
View user's profile Send private message
Malakai
Apprentice
Apprentice


Joined: 24 Dec 2002
Posts: 299

PostPosted: Sun May 16, 2004 12:54 pm    Post subject: Reply with quote

[quote="dasalvagg"]
Quote:

Couldn't agree more. We could literally take over bittorent if we all got on at once. Plus it seems that every p2p network is getting sued sooner or later. Dont think we want to be a part of that.



Bittorrent files on the net are tracked by an individual tracker, not a centralized (or decentralized for that matter) network. We could use the bittorrent protocol (which is already open source anyway, possibly gpl, not sure) and central gentoo trackers, with no ill effects to existing torrent trackers.
Back to top
View user's profile Send private message
TheChuckster
Tux's lil' helper
Tux's lil' helper


Joined: 18 Aug 2003
Posts: 91

PostPosted: Sun May 16, 2004 1:13 pm    Post subject: Reply with quote

Couldn't syncing also be done via p2p by simply hosting a tar ball of the current portage tree on the network and extracting it on the user's system like you do during a GRP install?
Back to top
View user's profile Send private message
sanity
n00b
n00b


Joined: 19 May 2002
Posts: 39
Location: Iowa

PostPosted: Sun May 16, 2004 3:39 pm    Post subject: portage tarballs? Reply with quote

No thanks. du -ch /usr/portage (after nuking distfiles) on my reiser4 box shows 92M. That's not really fair -- making a tarball shows 15M -- but it's still absolutely out of the question for a dialup user, and a ginormous waste of bandwidth for everyone else.

Now, let's suppose we have a p2p network where as long as 'emerge sync' is running (unless the person decides to become a permanent mirror), all files in their /usr/portage are available for download. Suppose we also make a global Manifest file (for all the sub-Manifest files, and for files which don't yet have a manifest), which includes the date and time. Now all the user has to download from an official mirror is the Manifest file, probably via http, even checking the timestamp with a HEAD request. Then they can check all their files against that Manifest, then connect to the p2p network, making available only the files that are up-to-date against that latest Manifest. Then, requests are made across the network for a file with a particular name and checksum -- starting by replacing old Manifests with new ones. Each new Manifest gives them more checksums, and so it goes.

I suspect that a system like this will be a lot less efficient per literal byte sent than just a Torrent of a tarball, but it will also ultimately save tons of bandwidth for daily updates of 5-10 files.

It would help if the same system could apply to distfiles -- as long as 'emerge sync' or a particular distfile download is running, all of /usr/portage and /usr/portage/distfiles are available. This is nice because while not everyone will always be downloading the same tarball, if people don't immediately clean them all out (after every emerge), there will be enough left over to share, and if I'm downloading foo.tbz2, someone else can download bar.tbz2 from me.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Goto page Previous  1, 2, 3, 4, 5, 6  Next
Page 2 of 6

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum