From owner-freebsd-mips@FreeBSD.ORG Fri Jun 11 13:40:06 2010 Return-Path: Delivered-To: freebsd-mips@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1E78E1065677 for ; Fri, 11 Jun 2010 13:40:06 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-gy0-f182.google.com (mail-gy0-f182.google.com [209.85.160.182]) by mx1.freebsd.org (Postfix) with ESMTP id CB46D8FC22 for ; Fri, 11 Jun 2010 13:40:05 +0000 (UTC) Received: by gyh20 with SMTP id 20so862835gyh.13 for ; Fri, 11 Jun 2010 06:40:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=v6CMQEd+ZHGS3u2tKvDsYSV67vMvsIKZRayIPpaGQgA=; b=mZUrKKfEy5iYFqartW2zBMRk+uvzxMA9aELvDbkXsDGNFMkVTsIQkDj5S7zCbMdOGE Wka5zZrKvHQT9axe338rQ1/hEWhlkQ8ag8/KFdTZEMvfZenLsGQDEvaiSh1a5+BHKLFj 7Vt626TXmnh6YHtAsfMOr938NOUpCeddBuK3g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=P2fTkg2vydL8F/6v+DBj05wI9x0jS1X5krm96W9G3l3tPfjcuf4zUZSnfYGXh33aQK bWq/tLOpDWRHxy6KP8d1J3Q/OsYuKkMYDl6fryTjx2F9G01ym4//SbI9WC72G+jsEyGd or671EHauZJcNSjLRndk3rE8dGEpnCYsFlz8w= MIME-Version: 1.0 Received: by 10.91.146.20 with SMTP id y20mr2288838agn.19.1276263604786; Fri, 11 Jun 2010 06:40:04 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.231.156.76 with HTTP; Fri, 11 Jun 2010 06:40:04 -0700 (PDT) In-Reply-To: <9c83a480a3f456a711411e7b458fdd41.squirrel@webmail.equix.ee> References: <9c83a480a3f456a711411e7b458fdd41.squirrel@webmail.equix.ee> Date: Fri, 11 Jun 2010 21:40:04 +0800 X-Google-Sender-Auth: EEr40O18FsBcu6t-pLPPaskTT8A Message-ID: From: Adrian Chadd To: Ain Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-mips@freebsd.org Subject: Re: Building image for Routerstation Pro X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Jun 2010 13:40:06 -0000 Hi! Ok, so: The mkfwimage program is from ubiquiti and the openwrt project. It's based on "Linux" assumptions - that there's a small kernel partition that is booted, then a large rootfs partition which holds the root filesystem, (device driver, etc) modules, etc. My images at work are integrated kernel+mdroot (gzip'ed). I'd like to eventually be able to run off of a read-only rootfs on the SPI flash but that will require some significant twiddling of the flash device code. For now, I use a user-space filestore program and a small rootfs (1mb) for config file and other sundry storage. There should be a cut down config file example in the config file there. You could try adding the various bits to make a geom_gzip mdroot - this significantly reduced my image size. HTH, adrian On 11 June 2010 21:07, Ain wrote: > Hello! > > I am trying get big picture, what is needed to make standalone, all in > onboard flash installation. I found some good pointers, like Adrian Chadd > patched utilities and README at http://people.freebsd.org/~adrian/rspro/ > But something seems to missing, from example, i don't get, why =A0mfs wri= tes > mdroot in kernel and then =A0mkfwimage (used by mkflash script) combines = new > kernel with mdroot file again. > Second thing is (if i understand correctly) 13 MB is allowed RSPRO image > size. > My =A0temporary file system image size is 13-14 MB (created by =A0Adrian = mfs > script, named /tmp/mfsroot). > mkfwimage raports =A0combined image filesize 19MB (i added little printin= g > statement in create_image_layout, before if (filelength(rootfsfile) + > kernel->partition_length > p->firmware_max_length) ). > What is needed to make system smaller? Sources are 8. june CURRENT, kerne= l > options MD_ROOT_SIZE=3D8192 > > Any pointers or questions are welcomed, > > Ain > > _______________________________________________ > freebsd-mips@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-mips > To unsubscribe, send any mail to "freebsd-mips-unsubscribe@freebsd.org" >