From owner-freebsd-mips@freebsd.org Tue Dec 26 08:05:23 2017 Return-Path: Delivered-To: freebsd-mips@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BE661EA8BFB for ; Tue, 26 Dec 2017 08:05:23 +0000 (UTC) (envelope-from ray@ddteam.net) Received: from mail-ua0-x22c.google.com (mail-ua0-x22c.google.com [IPv6:2607:f8b0:400c:c08::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 79F0D69AB4 for ; Tue, 26 Dec 2017 08:05:23 +0000 (UTC) (envelope-from ray@ddteam.net) Received: by mail-ua0-x22c.google.com with SMTP id k4so3627040ual.11 for ; Tue, 26 Dec 2017 00:05:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ddteam-net.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=S8UnVwCNAk35tM7fPJ6nAu+JMd4xiWMzwdja4OGwqTQ=; b=DKF8SnRXaSE5fIgOso4uIHrnwhttNAPwamJBmRTKWwBYqf1WGU86q6w8FFmcPBSjA6 hTNrPt6FlFtCabhoe3qwkWXF5Ab7LFrb3mgo1wbjDqSSCWBL8Wjq4AauDLuZF4y7c65C 81SCJIttn6wYOmB/8mj0UXwD5qKoc7F6fI5wBxJ52oOTnDEHfsgKSdSvsiPa4QuIJiIl BtDmW04X+KZaDf/wBQX+lWX+ZefoWVu6pSsGdgNQZoZ7Co8REeFULTM87yQAhQHCibyg iXmyH71ipMyhkhZbrOYGm4rPM49MKc5Fyv26DvJDrU4IKKOtEfSbsBwaGZWHxvpnaA/k 3Vyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=S8UnVwCNAk35tM7fPJ6nAu+JMd4xiWMzwdja4OGwqTQ=; b=JiBWWry9t5xWaGE/5mwGfREYWdB+AW8fFoUVGZ+raNokJIN7Zo9LfnWrz4jLBPHhdy g4w/UaydlmRiFhImhsSDQp6yOCyownflle6Pw7gL3p85hGHsTQnhN+idQl33NVfv5gqF i+vYbt16JxOhCWGFAKSqDgtWN2y4+Xm8FoU3ajULqTS+SBJu8gQte7OD851pu+zZd5+p vgG3dzOEjunBGxog1jKQrRugvwrb3lgcwGQl/HRnR4ll/8uT2uXkwXp2goa/YclHdi/3 dQGd9ZwFYNObciewzKIyWBAajdbNc1ETXyKFfDieXK3UXnGrYbiE94MYRK6VLwtYvoNw pYlg== X-Gm-Message-State: AKGB3mIK6JqpvX6F7V3N1AVxTvUN/sedtOrk8kO1QKlYGzydTVu2NMiT NImq1B+Z+z3cJCsqCy3/hcAMeqFJjdzSnsFBTfWlVg== X-Google-Smtp-Source: ACJfBouTbCVaqM6zhW9MX9dPOfuLAi+RCINClkzKxWyN1/s8zFDLctQvclC/OQjkbjXjl0x8HCaJja+9GB5NmV99SKU= X-Received: by 10.176.24.139 with SMTP id t11mr22467122uag.100.1514275521764; Tue, 26 Dec 2017 00:05:21 -0800 (PST) MIME-Version: 1.0 Received: by 10.176.89.104 with HTTP; Tue, 26 Dec 2017 00:05:21 -0800 (PST) In-Reply-To: <663673.1215.qm@web101715.mail.ssk.yahoo.co.jp> References: <129336.4485.qm@web101707.mail.ssk.yahoo.co.jp> <5A1C0240.8000102@grosbein.net> <409601.10493.qm@web101716.mail.ssk.yahoo.co.jp> <115897.36610.qm@web101713.mail.ssk.yahoo.co.jp> <554872.85153.qm@web101719.mail.ssk.yahoo.co.jp> <663673.1215.qm@web101715.mail.ssk.yahoo.co.jp> From: Aleksandr Rybalko Date: Tue, 26 Dec 2017 10:05:21 +0200 Message-ID: Subject: Re: reboot -r on mips To: Mori Hiroki Cc: Eugene Grosbein , "freebsd-mips@freebsd.org" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.25 X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Dec 2017 08:05:23 -0000 Hi guys! Thanks Hiroki, copy squashed rootfs to memory is great idea! I like it. Thanks! 2017-12-26 9:22 GMT+02:00 Mori Hiroki : > Hi > > I have new good idea at upgrading flash. > > https://translate.google.com/translate?sl=3Dja&tl=3Den&js=3Dy& > prev=3D_t&hl=3Dja&ie=3DUTF-8&u=3Dhttps%3A%2F%2Fqiita.com%2Fyamori813%2Fit= ems% > 2F437dee80478fccac34ee&edit-text=3D > > > ----- Original Message ----- > > From: Mori Hiroki > > To: Eugene Grosbein ; "freebsd-mips@freebsd.org" < > freebsd-mips@freebsd.org> > > Cc: > > Date: 2017/12/21, Thu 16:53 > > Subject: Re: reboot -r on mips > > > > Hi. > > > > I found some time failed reboot -r. Log is here. > > > > Jan 1 09:01:04 init: cannot mount tmpfs on /dev/reroot: No space left > on device > > Jan 1 09:01:04 init: reroot failed; going to single user mode > > > > I checked code. This error come from TMPFS_PAGES_MINRESERVED > > cheek in sys/fs/tmpfs/tmpfs_vfsops.c. > > > > Now TMPFS_PAGES_MINRESERVED is 4MByte. This is big because of > > my target have only 16MByte or 32Byte memory. > > > > I want change smaller value to TMPFS_PAGES_MINRESERVED. > > > > How to modify code? > > > > Regards > > > > Hiroki Mori > > > > ----- Original Message ----- > >> From: Mori Hiroki > >> To: Eugene Grosbein ; > > "freebsd-mips@freebsd.org" > >> Cc: > >> Date: 2017/11/29, Wed 20:41 > >> Subject: Re: reboot -r on mips > >> > >> Hi > >> > >> I found new method at upgrade. That is use pipe. > >> > >> This is upgrade script. This method only use 6MByte md > >> any size flash. > >> > >> #!/bin/sh > >> > >> ZBOARD=3D`uname -i` > >> > >> . /etc/upgrade.conf > >> > >> cd /tmp > >> mkdir bin > >> mkdir sbin > >> mkdir libexec > >> mkdir dev > >> mkdir lib > >> mkdir etc > >> mkdir -p usr/bin > >> cp /sbin/init sbin/ > >> cp /bin/sh bin/ > >> cp /bin/dd bin/ > >> cp /bin/kill bin/ > >> cp /libexec/ld-elf.so.1 libexec/ > >> cp /etc/login.conf.db etc/ > >> cp /usr/bin/tftp usr/bin/ > >> cp /lib/libedit.so.7 lib/ > >> cp /lib/libncursesw.so.8 lib/ > >> cp /lib/libc.so.7 lib/ > >> mkfifo flashpipe > >> > >> kenv vfs.root.mountfrom=3D"ufs:md0" > >> > >> #echo ${ZBOARD}.zimage > >> > >> echo "#!/bin/sh" > etc/rc > >> echo "dd if=3D/flashpipe of=3D${UPGRADEDEV} obs=3D${UPGRADEBS} conv= =3Dosync > >> &" >> etc/rc > >> echo "echo =C2=A5"bin > >> get ${ZBOARD}.zimage /flashpipe > >> quit=C2=A5" | tftp ${UPGRADETFTP} 69" >> etc/rc > >> echo "kill -INT 1" >> etc/rc > >> chmod a+x etc/rc > >> > >> reboot -r > >> > >> Hiroki Mori > >> > >> ----- Original Message ----- > >>> From: Mori Hiroki > >>> To: Eugene Grosbein ; > >> "freebsd-mips@freebsd.org" > >>> Cc: > >>> Date: 2017/11/28, Tue 16:38 > >>> Subject: Re: reboot -r on mips > >>> > >>> Hi > >>> > >>> Thanks for your advice. I missing your mail. > >>> > >>> I use ZRouter build system. This build use md file system at /tmp. > >>> > >>> But small(10M) than 8M flash upgrade. Then I do this way. > >>> > >>> 1. nomal boot process > >>> > >>> 2. set kenv to prepareupgrade=3D1 > >>> > >>> 3. reboot -r > >>> > >>> 4. if set prepareupgrade then delete old md and make big(16M) md in > > rc. > >>> > >>> 5. make minimum rootfs in md and save new image by tftp. > >>> > >>> 6. reboot -r > >>> > >>> 7. image to flash by dd > >>> > >>> 8. kill -INT 1 > >>> > >>> Thanks again. > >>> > >>> Hiroki Mori > >>> > >>> ----- Original Message ----- > >>>> From: Eugene Grosbein > >>>> To: Mori Hiroki ; > >>> "freebsd-mips@freebsd.org" > >>>> Cc: > >>>> Date: 2017/11/27, Mon 21:17 > >>>> Subject: Re: reboot -r on mips > >>>> > >>>> 27.11.2017 18:56, Mori Hiroki =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > >>>>> Hi. > >>>>> > >>>>> I found reboot -r today. I try this function on my Atheros > > AR9. > >>>> > >>>> [skip] > >>>> > >>>>> This function make complete flash update method. > >>>> > >>>> Yes, it's great. Also, look at > >>>> > > https://lists.freebsd.org/pipermail/freebsd-mips/2016- > February/004431.html > >>>> > >>> _______________________________________________ > >>> freebsd-mips@freebsd.org mailing list > >>> https://lists.freebsd.org/mailman/listinfo/freebsd-mips > >>> To unsubscribe, send any mail to > >>> "freebsd-mips-unsubscribe@freebsd.org" > >>> > >> _______________________________________________ > >> freebsd-mips@freebsd.org mailing list > >> https://lists.freebsd.org/mailman/listinfo/freebsd-mips > >> To unsubscribe, send any mail to > >> "freebsd-mips-unsubscribe@freebsd.org" > >> > > _______________________________________________ > > freebsd-mips@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-mips > > To unsubscribe, send any mail to > > "freebsd-mips-unsubscribe@freebsd.org" > > > _______________________________________________ > freebsd-mips@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-mips > To unsubscribe, send any mail to "freebsd-mips-unsubscribe@freebsd.org" > --=20 WBW ------- Rybalko Aleksandr