{"id":928,"date":"2011-04-28T07:38:07","date_gmt":"2011-04-28T02:08:07","guid":{"rendered":"http:\/\/judepereira.com\/blog\/?p=928"},"modified":"2011-05-08T08:06:25","modified_gmt":"2011-05-08T02:36:25","slug":"binpkg-gentoos-masterpiece","status":"publish","type":"post","link":"https:\/\/judepereira.com\/blog\/binpkg-gentoos-masterpiece\/","title":{"rendered":"binpkg: a Gentoo Masterpiece"},"content":{"rendered":"<p><strong>If you were running a cluster of Gentoo driven machines, would you actually compile source for each of them?<\/strong><\/p>\n<p><strong> <\/strong><em>Or rather use <strong>binary packages<\/strong>?<\/em><\/p>\n<p>Gentoo&#8217;s masterpiece is binpkg, when you compile for one machine, you don&#8217;t have to recompile throughout, use quickpkg to build binary packages. Such packages can be hosted over a central server and each system downloads just the binary package.<\/p>\n<p>You can use this even if your not running a cluster, but frequently reinstall certain packages. Use the -b flag with emerge to install and build the package as well.<\/p>\n<p>Setting the PKGDIR in \/etc\/make.conf<br \/>\nAdd the following directive in make.conf<\/p>\n<p><span style=\"font-family: Consolas, Monaco, 'Courier New', Courier, monospace; font-size: 12px; line-height: 18px; white-space: pre;\">PKGDIR=&#8221;\/var\/cache\/portage\/binpkg&#8221;<\/span><\/p>\n<p><span style=\"font-family: Consolas, Monaco, 'Courier New', Courier, monospace; font-size: 12px; line-height: 18px; white-space: pre;\"> <\/span>Building binary packages is easy.<\/p>\n<p><span style=\"font-family: Consolas, Monaco, 'Courier New', Courier, monospace; font-size: 12px; line-height: 18px; white-space: pre;\">quickpkg $(qlist -IC)<\/span><\/p>\n<p>That goes on your main server.<\/p>\n<p>You can add the parameter &#8211;include-config=y , it&#8217;s not reccommended because then you&#8217;ll bascically be cloning the host. Your IP addresses, etc. are installed as is. Deploy an instance of <a href=\"http:\/\/www.puppetlabs.com\/\">puppet<\/a>.<\/p>\n<p>Now your binary packages are built, you can symlink them and make them available on the webserver for production purposes.<\/p>\n<p>Adding BINHOST to your sister machines, add the following directive in your make.conf, make the necesssary changes:<\/p>\n<pre>PORTAGE_BINHOST=\"http:\/\/your.server.repo\/path\/to\/binary\/packages\"\r\nPKGDIR=\"\/var\/cache\/portage\/binpkg\"<\/pre>\n<p>&nbsp;<\/p>\n<table cellspacing=\"2\">\n<tbody>\n<tr>\n<td colspan=\"2\"><strong>Options<\/strong><\/td>\n<\/tr>\n<tr>\n<td>&#8211;getbinpkg<\/td>\n<td>Fetch binary source if available, else, fetch source<\/td>\n<\/tr>\n<tr>\n<td>&#8211;getbinpkgonly<\/td>\n<td>Fetch binary source ONLY<\/td>\n<\/tr>\n<tr>\n<td>&#8211;usepkg<\/td>\n<td>Use binary package for merge if available, else resort to source compile<\/td>\n<\/tr>\n<tr>\n<td>&#8211;usepkgonly<\/td>\n<td>Use binary package ONLY<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><strong>Note: <\/strong>If you specify to fetch\/merge using ONLY binary packages, if certain dependencies are missing, emerge will simply abort. Hence, its not advisable to do so.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you were running a cluster of Gentoo driven machines, would you actually compile source for each of them? Or rather use binary packages? Gentoo&#8217;s masterpiece is binpkg, when you compile for one machine, you don&#8217;t have to recompile throughout, use quickpkg to build binary packages. Such packages can be hosted over a central server [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[11],"tags":[196,194,191,103,192,193,195,190],"class_list":["post-928","post","type-post","status-publish","format-standard","hentry","category-gen-sab-fed","tag-binary","tag-binary-gentoo-package","tag-binpkg","tag-gentoo","tag-gentoo-binary","tag-gentoo-package","tag-packages-for-gentoo","tag-quickpkg"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/pqtyx-eY","jetpack-related-posts":[{"id":289,"url":"https:\/\/judepereira.com\/blog\/sabayon-four-oh\/","url_meta":{"origin":928,"position":0},"title":"Sabayon fOuR oH","author":"Jude Pereira","date":"June 16, 2009","format":false,"excerpt":"Based on Gentoo, Sabayon 4.1, tells me: Great performance with less RAM(though you need like 1GB RAM for it to work well enough). Package Management System is absolutely fantastic, with it's new \"Entropy\". Totally the perfect distribution. A fine distribution for the newbie or the expert. This is what a\u2026","rel":"","context":"In &quot;gnu linux&quot;","block_context":{"text":"gnu linux","link":"https:\/\/judepereira.com\/blog\/category\/linux\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":893,"url":"https:\/\/judepereira.com\/blog\/coloured-varlogmessages-at-tty12\/","url_meta":{"origin":928,"position":1},"title":"Coloured \/var\/log\/messages at tty12","author":"Jude Pereira","date":"April 26, 2011","format":false,"excerpt":"Reading logs could never become any more easier, at just a keystroke, you have your logs displayed where you want, in some fancy colour. They look great too. TTY's can be accessed by pressing Alt + Ctrl + F[1 - 12] simultaneously. In the following, you'll get a decent, colourized\u2026","rel":"","context":"In &quot;another snippet | code&quot;","block_context":{"text":"another snippet | code","link":"https:\/\/judepereira.com\/blog\/category\/code\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":694,"url":"https:\/\/judepereira.com\/blog\/visual-basic-6-revisited-linux-wine\/","url_meta":{"origin":928,"position":2},"title":"visual basic 6 revisited &#8211; linux &#8211; wine","author":"Jude Pereira","date":"August 5, 2010","format":false,"excerpt":"Earlier this year, I had written an article on running Visual Basic 6 on linux under wine, this is an update for it, the prior one is deprecated Getting Visual Basic 6 to work on linux is pretty easy, not much trouble, all the basic things work, as of what\u2026","rel":"","context":"In &quot;another snippet | code&quot;","block_context":{"text":"another snippet | code","link":"https:\/\/judepereira.com\/blog\/category\/code\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":64,"url":"https:\/\/judepereira.com\/blog\/faunos-shadow\/","url_meta":{"origin":928,"position":3},"title":"FaunOS Shadow","author":"Jude Pereira","date":"January 20, 2009","format":false,"excerpt":"It's a distribution based totally on Arch Linux... specialized for USB Portable installs and can also be used as primary OS has over 600 packages pre-installed (I know... it reminds you of Fedora and me too!). So that's to say that it comes with definitely all the packages you would\u2026","rel":"","context":"In &quot;gnu linux&quot;","block_context":{"text":"gnu linux","link":"https:\/\/judepereira.com\/blog\/category\/linux\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1685,"url":"https:\/\/judepereira.com\/blog\/compile-less-on-the-fly-for-your-exploded-war-in-intellij\/","url_meta":{"origin":928,"position":4},"title":"Compile LESS on the fly for your exploded WAR in IntelliJ","author":"Jude Pereira","date":"February 5, 2016","format":false,"excerpt":"At CleverTap, we've recently started using LESS for dynamic CSS. While it has it's upsides, the biggest downside\u00a0was that most of our developers couldn't use the hot deploy feature for their local deployments. After an hour or so, we came up with a neat solution. \u00a0 There are two parts\u2026","rel":"","context":"In &quot;another snippet | code&quot;","block_context":{"text":"another snippet | code","link":"https:\/\/judepereira.com\/blog\/category\/code\/"},"img":{"alt_text":"External Tool configuration for compiling LESS files before deployment","src":"https:\/\/i0.wp.com\/judepereira.com\/blog\/wp-content\/uploads\/Screen-Shot-2016-02-05-at-01.32.45-1024x494.png?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/judepereira.com\/blog\/wp-content\/uploads\/Screen-Shot-2016-02-05-at-01.32.45-1024x494.png?resize=350%2C200 1x, https:\/\/i0.wp.com\/judepereira.com\/blog\/wp-content\/uploads\/Screen-Shot-2016-02-05-at-01.32.45-1024x494.png?resize=525%2C300 1.5x"},"classes":[]}],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/posts\/928","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/comments?post=928"}],"version-history":[{"count":20,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/posts\/928\/revisions"}],"predecessor-version":[{"id":1007,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/posts\/928\/revisions\/1007"}],"wp:attachment":[{"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/media?parent=928"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/categories?post=928"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/judepereira.com\/blog\/wp-json\/wp\/v2\/tags?post=928"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}