From owner-freebsd-questions@FreeBSD.ORG Thu Feb 15 21:30:00 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4992716A400 for ; Thu, 15 Feb 2007 21:30:00 +0000 (UTC) (envelope-from lists@jnielsen.net) Received: from ns1.jnielsen.net (ns1.jnielsen.net [69.55.238.237]) by mx1.freebsd.org (Postfix) with ESMTP id DF95813C4C2 for ; Thu, 15 Feb 2007 21:29:59 +0000 (UTC) (envelope-from lists@jnielsen.net) Received: from localhost (jn@ns1 [69.55.238.237]) (authenticated bits=0) by ns1.jnielsen.net (8.12.9p2/8.12.9) with ESMTP id l1FLTuAE089972; Thu, 15 Feb 2007 16:29:59 -0500 (EST) (envelope-from lists@jnielsen.net) From: John Nielsen To: freebsd-questions@freebsd.org Date: Thu, 15 Feb 2007 16:29:38 -0500 User-Agent: KMail/1.9.5 References: In-Reply-To: X-Face: #X5#Y*q>F:]zT!DegL3z5Xo'^MN[$8k\[4^3rN~wm=s=Uw(sW}R?3b^*f1Wu*.<=?utf-8?q?of=5F4NrS=0A=09P*M/9CpxDo!D6?=)IY1w<9B1jB; tBQf[RU-R<,I)e"$q7N7 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200702151629.38558.lists@jnielsen.net> X-Virus-Scanned: ClamAV version 0.88.4, clamav-milter version 0.88.4 on ns1.jnielsen.net X-Virus-Status: Clean Cc: pancho pantera Subject: Re: jailed VPS behind NAT X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Feb 2007 21:30:00 -0000 On Thursday 15 February 2007 14:44, pancho pantera wrote: > hello, > > i don't know where to search for THIS, info about jailed VPS.and secondly > handbook and other papers and docs, are some times criptic , because > english is not may mother language, i usually speak spanish. > > usually irtual private servers has its own public internet IP address, > but here in mexico this is very expensive. > > my project is to get just one IP address and put freebsd jails for VPS > behind NAT for offer: " VPS whit shared IP". > > something between shared webhsoting and FULL VPS (whit own public IP for > each). > > please letme know where can ia find more info or answer for this > topic. Set up NAT as you otherwise would using the "real" interface and IP as the external network. There are several different methods for doing this, most of which are discussed and mentioned in the handbook. I use ipfw+natd since that's what I'm most familiar with, but pf may be a better option if you're just getting started. Since your "internal" network doesn't have (or need) a real network interface, use the loopback interface (lo0). Create an alias in the 127.0.0.0/8 network for each jail. You should of course reserve 127.0.0.1 as the "real" localhost address. Set up the jails as you normally would, using the 127.x.x.x IP's you allocated above. See the jail(8) manpage to get started. There are other howtos and guides out there that might give more background and examples, but the manpage has always been adequate fo my (modest) needs. You might also want to look at the sysutils/ezjail port. See also http://erdgeist.org/arts/software/ezjail/ . Decide how you are going to allocate ports and/or proxy/share commonly used ports. For http and https (80 and 443), consider running Apache with mod_proxy and virtualhosts. Should get you started at least... JN