From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 64B9D1381F3 for ; Fri, 26 Apr 2013 17:47:38 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 07298E08BE; Fri, 26 Apr 2013 17:47:35 +0000 (UTC) Received: from mail.tilibox.com (ma1.maserver.com [144.76.38.141]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 7B3B4E08BE for ; Fri, 26 Apr 2013 17:47:34 +0000 (UTC) Received: from [192.168.1.100] (ool-44c22576.dyn.optonline.net [68.194.37.118]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mail.tilibox.com (Postfix) with ESMTPSA id 4E93F92674 for ; Fri, 26 Apr 2013 19:47:34 +0200 (CEST) Message-ID: <517A8573.4010207@missionaccomplish.com> Date: Fri, 26 Apr 2013 13:47:31 +0000 From: Isabel Orocu User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130421 Thunderbird/17.0.5 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-catalyst@lists.gentoo.org Reply-to: gentoo-catalyst@lists.gentoo.org MIME-Version: 1.0 To: gentoo-catalyst@lists.gentoo.org Subject: [gentoo-catalyst] Support for custom memory settings in AUFS References: <1366997059-7478-mlmmj-0c5cc6a9@lists.gentoo.org> In-Reply-To: <1366997059-7478-mlmmj-0c5cc6a9@lists.gentoo.org> Content-Type: multipart/mixed; boundary="------------090803080905070903090702" X-Archives-Salt: b451aac4-28b2-4f8a-93d3-69dee463d803 X-Archives-Hash: 4c61c60dff73fbeec00f3e5c1b811525 This is a multi-part message in MIME format. --------------090803080905070903090702 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On the original livedvd which I initially implemented AUFS support to allow users to use of emerge, I implemented the ability to append "aufs_mem=X" into the kernel since the default was to use tmpfs without "-o size" option. Attached is a patch that will reintroduce this to catalyst. -- Thank you, Fernando Orocu GPG BDD75DD7 Mission Accomplish, Inc. Tel: 7187100008 Cell: 3479275477 --------------090803080905070903090702 Content-Type: text/x-patch; name="catalyst-aufs-mem-support.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="catalyst-aufs-mem-support.patch" diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts index ff724b5..c59a100 100755 --- a/defaults/initrd.scripts +++ b/defaults/initrd.scripts @@ -1152,7 +1152,13 @@ setup_squashfs_aufs() { modprobe aufs > /dev/null 2>&1 mount -t squashfs -o loop,ro "${CDROOT_PATH}/${LOOPEXT}${LOOP}" "${static}" - mount -t tmpfs none "${overlay}" + + if [ ${aufs_mem} ];then + mount -t tmpfs none "${overlay}" + else + mount -t tmpfs -o size=${aufs_mem} none "${overlay}" + fi + mount -t aufs -o br:${overlay}:${static} aufs "${NEW_ROOT}" [ ! -d "${NEW_ROOT}${overlay}" ] && mkdir -p "${NEW_ROOT}${overlay}" diff --git a/defaults/linuxrc b/defaults/linuxrc index ba9c5d5..fef14ba 100755 --- a/defaults/linuxrc +++ b/defaults/linuxrc @@ -248,6 +248,9 @@ do aufs) USE_AUFS_NORMAL=1 ;; + aufs_mem=*) + aufs_mem=${x#*=} + ;; unionfs) if [ ! -x /sbin/unionfs ] then --------------090803080905070903090702--