<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Avi :) &#187; config</title>
	<atom:link href="http://blog.avi.co/wp/tag/config/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.avi.co</link>
	<description>Open Source Software Hippy and all-round pedant</description>
	<lastBuildDate>Mon, 07 Jun 2010 14:34:05 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Whoo! Theme update!</title>
		<link>http://blog.avi.co/wp/whoo-theme-update/</link>
		<comments>http://blog.avi.co/wp/whoo-theme-update/#comments</comments>
		<pubDate>Tue, 12 Jan 2010 10:40:38 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[css]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=518</guid>
		<description><![CDATA[I've updated the theme, and applied my handy modifications that make it more grey. Here's the diff on the css file, if you're wondering what I did (and for next time when I forget). I despise CSS, so it's all nice and easy.
The changes are to give the &#60;pre&#62; tags a grey (#EEE) background colour, [...]]]></description>
			<content:encoded><![CDATA[<p>I've updated the theme, and applied my handy modifications that make it more grey. Here's the diff on the css file, if you're wondering what I did (and for next time when I forget). I despise CSS, so it's all nice and easy.</p>
<p>The changes are to give the <tt>&lt;pre&gt;</tt> tags a grey (#EEE) background colour, and to make the posts individual white boxes on grey, rather than an all-white page. </p>
<pre class="css">&nbsp;
avi<span style="color: #a1a100;">@avi:whiteasmilk_1.8$ diff style.css style.css.original</span>
<span style="color: #933;">18</span>,35d17
&lt; <span style="color: #808080; font-style: italic;">/* Added to make the code blocks pretty. Stupid CSS implementations mean this will break
&lt;    any form of validity in order to actually make it work. Stupid browser people.
&lt;    I can't remember where I got this from, but if you reckon I might've found it on your site
&lt;    let me know and if I believe you I'll stick a URL here
&lt; */</span>
&lt; pre <span style="color: #66cc66;">&#123;</span>
&lt; 	<span style="color: #000000; font-weight: bold;">border</span> <span style="color: #933;">0</span>
&lt; 	<span style="color: #000000; font-weight: bold;">padding</span>: <span style="color: #933;">0</span><span style="color: #6666ff;"><span style="color: #933;">.2em</span></span> <span style="color: #933;">0</span><span style="color: #6666ff;"><span style="color: #933;">.5em</span></span>;
&lt; 	<span style="color: #000000; font-weight: bold;">background-color</span>:<span style="color: #cc00cc;">#EEE</span>;
&lt; 	white-space<span style="color: #3333ff;">:pre-wrap</span>;
&lt; 	<span style="color: #000000; font-weight: bold;">white-space</span>: -moz-pre-wrap;  <span style="color: #808080; font-style: italic;">/* Mozilla, since 1999 */</span>
&lt; 	<span style="color: #000000; font-weight: bold;">white-space</span>: -pre-wrap;      <span style="color: #808080; font-style: italic;">/* Opera 4-6 */</span>
&lt; 	<span style="color: #000000; font-weight: bold;">white-space</span>: -o-pre-wrap;    <span style="color: #808080; font-style: italic;">/* Opera 7 */</span>
&lt; 	word-wrap: break-word;       <span style="color: #808080; font-style: italic;">/* Internet Explorer 5.5+ */</span>
&lt; <span style="color: #66cc66;">&#125;</span>
&lt;
&lt;
&lt;
40c22
&lt;   body <span style="color: #66cc66;">&#123;</span><span style="color: #000000; font-weight: bold;">background-color</span>:<span style="color: #cc00cc;">#c9c9c9</span>;<span style="color: #66cc66;">&#125;</span>
---
&gt;   body <span style="color: #66cc66;">&#123;</span>background-color<span style="color: #3333ff;">:white</span>;<span style="color: #66cc66;">&#125;</span>
<span style="color: #933;">323</span>,326c305
&lt; border-bottom<span style="color: #3333ff;">:<span style="color: #933;">15px</span></span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#c9c9c9</span>;
&lt;   padding-left<span style="color: #3333ff;">:<span style="color: #933;">10px</span></span>;
&lt;   padding-right<span style="color: #3333ff;">:<span style="color: #933;">10px</span></span>;
&lt;   <span style="color: #000000; font-weight: bold;">background-color</span>:<span style="color: #cc00cc;">#fff</span>;
---
&gt;   border-bottom<span style="color: #3333ff;">:<span style="color: #933;">1px</span></span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#<span style="color: #933;">999</span></span>;</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/whoo-theme-update/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Giving Android a swap file</title>
		<link>http://blog.avi.co/wp/giving-android-a-swap-file/</link>
		<comments>http://blog.avi.co/wp/giving-android-a-swap-file/#comments</comments>
		<pubDate>Fri, 20 Nov 2009 14:33:15 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[cyanogen]]></category>
		<category><![CDATA[dowant]]></category>
		<category><![CDATA[swap]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=251</guid>
		<description><![CDATA[I don't know if it's because I'm doing more with it than I used to, or the rose-tinted specs that come with the novelty value have worn off, or if the later updates have been designed for more powerful hardware, but my G1's been lagging a bit recently, so I figured I'd have a look [...]]]></description>
			<content:encoded><![CDATA[<p>I don't know if it's because I'm doing more with it than I used to, or the rose-tinted specs that come with the novelty value have worn off, or if the later updates have been designed for more powerful hardware, but my G1's been lagging a bit recently, so I figured I'd have a look at what I can do to make it faster. Turns out it's quite receptive to the idea of a swap file.<br />
You'll need root access for this - everything below is to be run as root. Following is how I did it on my cyanogen'd G1, but I don't see why it wouldn't work on anything else - it makes use of standard linux tools. This will likely advance the death of your sdcard - it increases the reads and writes by some large margin. I don't know enough about sdcards to know how much quicker it will die, but modern ones will likely deal with it better than older ones.</p>
<p>Anyway, in your terminal emulator:</p>
<pre class="bash"><span style="color: #c20cb9; font-weight: bold;">dd</span> <span style="color: #007800;">if=</span>/dev/zero <span style="color: #007800;">of=</span>/sdcard/swap <span style="color: #007800;">bs=</span>1M <span style="color: #007800;">count=</span><span style="color: #000000;">100</span></pre>
<p>You can call it whatever you like. The 'count' value (100 above) is how many MB of swap space you want. The above will create 100MB of swap.<br />
This will take a few seconds (of the order of 50), so if it's 'hung' it's probably not crashed.</p>
<p>Then we make it into a swap file and activate it as swap space:</p>
<pre class="bash">mkswap /sdcard/swap
swapon /sdcard/swap</pre>
<p>Finally, we want to change the swappiness of the system. When the system memory is completely full, and more is requested, the kernel needs to work out how to create some space. It, generally, can do one of two things: drop some filesystem cache, or move some application memory to swap.<br />
The swappiness value dictates the priority of either - a value of 0 means it will always try to drop fs cache rather than use swap, and a value of 100 means it will always try to use swap and preserve the fs cache. Only values between 0 and 100 inclusive are allowed, and neither guarantees any action - you can still find yourself swapping out at 0, for example - just the priority afforded each solution.<br />
The default value for the Linux kernel is 60, which is generally not appropriate for something running completely from flash media (where the fs cache isn't so important). So I'm dropping it to 20, which seems to work for me. If it doesn't for you, try some other values, it's an on-the-fly change.</p>
<pre class="bash"><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #000000;">20</span> &gt; /proc/sys/vm/swappiness</pre>
<p>On rebooting the phone, the above settings wont hold. The swap file will still be available (assuming the SD card is still inserted), but on reboot you'll need to run</p>
<pre class="bash">swapon /sdcard/swap
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #000000;">20</span> &gt; /proc/sys/vm/swappiness</pre>
<p>On the plus side, you'll be rebooting less.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/giving-android-a-swap-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cyanogen on my G1</title>
		<link>http://blog.avi.co/wp/cyanogen-on-my-g1/</link>
		<comments>http://blog.avi.co/wp/cyanogen-on-my-g1/#comments</comments>
		<pubDate>Sat, 14 Nov 2009 23:50:08 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[cyanogen]]></category>
		<category><![CDATA[dowant]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=260</guid>
		<description><![CDATA[I've just upgraded to Cyanogen on my G1 and it's lovely. Well, I got root, which is basically what I always wanted.
I basically followed the instructions on the Cyanogen wiki and everything worked exactly as described, I've nothing really to add here except to say it's brilliantly easy and everyone should do it.
One small note, [...]]]></description>
			<content:encoded><![CDATA[<p>I've just upgraded to Cyanogen on my G1 and it's lovely. Well, I got root, which is basically what I always wanted.</p>
<p>I basically followed the <a href="http://wiki.cyanogenmod.com/index.php/Full_Update_Guide_-_G1/Dream_Firmware_to_CyanogenMod">instructions</a> on the <a href="http://wiki.cyanogenmod.com">Cyanogen wiki</a> and everything worked exactly as described, I've nothing really to add here except to say it's brilliantly easy and everyone should do it.<br />
One small note, though, the final reboot into Cyanogen takes a long time. Mine took just shy of thirty minutes, and I've read of others taking anything above about 15.</p>
<p>The first obvious benefits are root access, exchange activesync support, five workspaces (as against the stock 3) and a bunch of useful apps already installed, including a nifty <a href="http://www.cyanogenmod.com/wp-content/gallery/cm-mod/power_control_widget.png">power control widget</a> which replaces my collection of 5 distinct widgets. I'll write more on it when I've used it more.<br />
In case, as I did, you've been pondering this and wondering what the end result is like, it's almost exactly as previously, but with some new features, there's some <a href="http://www.cyanogenmod.com/screenshots">screenshots</a> on the webpage. I've not yet found anything to have been degraded by it, and it all looks and feels the same, but a bit more polished in areas. Though it only ships with one ringtone.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/cyanogen-on-my-g1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Some notes from configuring rTorrent</title>
		<link>http://blog.avi.co/wp/some-notes-from-configuring-rtorrent/</link>
		<comments>http://blog.avi.co/wp/some-notes-from-configuring-rtorrent/#comments</comments>
		<pubDate>Wed, 28 Oct 2009 22:53:16 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[torrent]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/wordpress/?p=28</guid>
		<description><![CDATA[In anticipation of the new *buntus tomorrow, I'm configuring one of my servers as a torrent node for it, and for reasons unknown I've settled on rtorrent which is in the repos. The documentation is a little lacking (but does tell you how to do things like download torrents. Read it), and the most popular [...]]]></description>
			<content:encoded><![CDATA[<p>In anticipation of the new *buntus tomorrow, I'm configuring one of my servers as a torrent node for it, and for reasons unknown I've settled on <tt>rtorrent</tt> which is in the repos. The <a href="http://libtorrent.rakshasa.no/wiki/RTorrentUserGuide">documentation</a> is a little lacking (but does tell you how to do things like download torrents. Read it), and the <a href="http://kmandla.wordpress.com/2007/05/02/howto-use-rtorrent-like-a-pro/">most popular HowTo</a> is quite verbose.</p>
<p><tt>~/.torrentrc</tt> is the config file for rtorrent. The one from the Debian repos puts an example in <tt>/usr/share/doc/rtorrent/examples/rtorrent.rc</tt>, and apparently so does *buntu. You probably want to edit this. Path variables can be absolute or relative, and are generally relative and inside <tt>./</tt> by default. I've two directories, <tt>~/torrents/</tt> for the torrents and <tt>~/.rtorrent/</tt> for rtorrent's working directories.<br />
Some variables I found to be handy:</p>
<pre class="perl">scgi_local=<span style="color: #ff0000;">&quot;~/.rtorrent/socket/rpc.socket&quot;</span></pre>
<p>Defines the socket file for scgi communication, which you only really need if you want external stats from it. I did, but haven't yet got round to using them.</p>
<pre class="perl">session = ~/.rtorrent/sessio</pre>
<p>The session directory, which lets multiple instances of rtorrent remember where they left off. Cannot be shared between instances.</p>
<p><strong>Scheduling</strong><br />
rtorrent supports command scheduling, the syntax for which is occasionally documented. The syntax is approximately:</p>
<pre class="perl">schedule = a,b,c,d</pre>
<p>Where<br />
<tt>a</tt>: What you want to call this scheduled command<sup>1</sup>.<br />
<tt>b</tt>: How many seconds after rtorrent starts you want to first execute the command.<br />
<tt>c</tt>: The interval for subsequent executions.<br />
<tt>d</tt>: the command you want to execute.<br />
This comes in most handy for auotmatically starting torrents in a directory:</p>
<pre class="perl">schedule = watch_directory,<span style="color: #cc66cc;">5</span>,<span style="color: #cc66cc;">5</span>,load_start=~/torrents/*.torrent</pre>
<p>Exactly what that does is left as an excercise to the reader (the example .rtorrent.rc explains, too).</p>
<ol class="footnotes"><li id="footnote_0_28" class="footnote">I don't know where this comes in handy later on</li></ol>]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/some-notes-from-configuring-rtorrent/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Moving WinXP&#8217;s My Documents</title>
		<link>http://blog.avi.co/wp/moving-winxps-my-documents/</link>
		<comments>http://blog.avi.co/wp/moving-winxps-my-documents/#comments</comments>
		<pubDate>Fri, 29 May 2009 15:37:35 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[batch]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[registry]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=112</guid>
		<description><![CDATA[The My Documents directory location is stored in the registry at HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders in a key called personal.
The following script is what I use to remap this to u:/documents:
;; create some dirs:u:mkdir documentsmkdir outlook&#160;;; Move My Documents folder:;; delete current settingreg.exe delete &#34;HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders&#34; /v Personal /f;; create new settingreg.exe Add  &#34;HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders&#34; /v [...]]]></description>
			<content:encoded><![CDATA[<p>The My Documents directory location is stored in the registry at <tt>HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders</tt> in a key called <tt>personal</tt>.</p>
<p>The following script is what I use to remap this to <tt>u:/documents</tt>:</p>
<pre class="winbatch"><ol><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #008000; font-style: italic;">;; create some dirs:</span></div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">u<span style="color: #FF1010; font-weight: bold;">:</span></div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">mkdir documents</div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">mkdir outlook</div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #008000; font-style: italic;">;; Move My Documents folder:</span></div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #008000; font-style: italic;">;; delete current setting</span></div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">reg.exe delete <span style="color: #ff0000;">&quot;HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders&quot;</span> /v Personal /f</div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #008000; font-style: italic;">;; create new setting</span></div></li><li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;"><div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">reg.exe Add  <span style="color: #ff0000;">&quot;HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders&quot;</span> /v Personal /t REG_SZ /d u<span style="color: #FF1010; font-weight: bold;">:/documents</span></div></li></ol></pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/moving-winxps-my-documents/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Synergy to share a keyboard and mouse across PCs</title>
		<link>http://blog.avi.co/wp/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/</link>
		<comments>http://blog.avi.co/wp/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/#comments</comments>
		<pubDate>Sat, 09 May 2009 21:10:50 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[hardware]]></category>
		<category><![CDATA[keyboard]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mouse]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[synergy]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=348</guid>
		<description><![CDATA[Synergy is a really neat way of using multiple computers at the same time, like a more convenient KVM switch (you do need to be physically close to all of them). 
It basically allows you to have a monitor for each PC on your desk, and one keyboard and mouse with which to monitor them. [...]]]></description>
			<content:encoded><![CDATA[<p>Synergy is a really neat way of using multiple computers at the same time, like a more convenient KVM switch (you do need to be physically close to all of them). </p>
<p>It basically allows you to have a monitor for each PC on your desk, and one keyboard and mouse with which to monitor them. Switching between PCs involves just moving the mouse pointer onto the relevant screen. It uses 'screens' rather than monitors, so you don't need to let it know if you've got a complicated multi-monitor setup on a host (or even if you add or remove monitors from one), and it allows for having screens of different sizes and for, say, the bottom half of one screen to line up with the top half of the next.</p>
<p>It's a server/client model - you have one server box into which you plug the keyboard and mouse. The rest connect over the network to it (in cleartext, don't do this where you don't trust the network).</p>
<p>I have two hosts. My work laptop is running Windows XP and has an external monitor plugged in to it. My testing PC is running Debian testing and is a PC proper. Here's my desk:<br />
<a href="http://aviswebsite.co.uk/wordpress/wp-content/uploads/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/desk1.jpg"><img src="http://aviswebsite.co.uk/wordpress/wp-content/uploads/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/desk1-300x225.jpg" alt="desk" title="desk" class="aligncenter size-medium wp-image-386" /></a><br />
<tt>jup-linux2</tt> is the left monitor (attached to the PC to its left, running Debian), <tt>jup-rmt07</tt> is the laptop on the right, which is also attached to the Sony screen in the middle. Since I take the laptop home with me occasionally, <tt>jup-linux2</tt> is configured as a server, <tt>jup-rmt07</tt> as the client (less to unplug).</p>
<p>Synergy is in the debian repositories, so it's just an <tt>apt-get install synergy</tt>. This provides two binaries, <tt>/usr/bin/synergyc</tt> and <tt>/usr/bin/synergys</tt>, which are the client and the server respectively.<br />
To install it in Windows, you'll want to grab it from their <a href="http://sourceforge.net/projects/synergy2/files/">Sourceforge page</a></p>
<p><strong>Configuring and starting the server</strong><br />
So, having installed, we can configure! The configuration file can be arbitrarily named, mine's cunningly called <tt>~/.synergy.conf</tt> and appears verbatim at the bottom of this. Synergy's really rather configurable, but I've never found much need for more than the basics, so I've an incredibly simple setup.</p>
<p>First, we define some 'screens'. Here we can also configure optons for screens, especially as regards the transference of caps-lock and num-lock statuses. I've no special requests, so I just list the hosts whose screens I want Synergy to manage:</p>
<pre>section: screens
	jup-rmt07:
	jup-linux2:
end</pre>
<p>Second, we define the links. For each monitor, we state what is at any edge of it. This is used to decide where to put the mouse pointer on leaving the screen, so it needs to be done in both directions - the fact that <tt>jup-linux2</tt> is to the left of <tt>jup-rmt07</tt> does not imply to synergy that <tt>jup-rmt07</tt> is to the right of <tt>jup-linux2</tt>:</p>
<pre>section: links
jup-rmt07:
	left = jup-linux2
jup-linux2:
	right = jup-rmt07
end </pre>
<p>If I have two screens at different heights, I can tell synergy that the top 30% of <tt>jup-linux2</tt> lines up with the bottom 40% of <tt>jup-rmt07</tt>, for example:</p>
<pre>jup-linux2
	right(70-100) = jup-linux2(0-40)
jup-rmt07
	left(0-40) = jup-rmt07(70-100)</pre>
<p>Again, you always always <strong>always</strong> need to define the screen in both directions. The file is parsed by synergy to see what to do on leaving that particular screen - when you're in jup-rmt07 and move towards the left of the screen, it's only going to do anything if there's a <tt>left</tt> defined for that screen, irrespective of how many rights point there.<br />
If my screens are above and below each other, <tt>up</tt> and <tt>down</tt> are used. A screen can have as many other screens round it as you like, by assigning percentages of edges to different screens.</p>
<p>Configuring the server under Windows involves a different process to use the same principles. Essentially, you build the same text file as above, but in a clicky gui. It's a little odd, but quite simple.</p>
<p><a href="http://aviswebsite.co.uk/wordpress/wp-content/uploads/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/synergy-win-server1.PNG"><img src="http://aviswebsite.co.uk/wordpress/wp-content/uploads/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/synergy-win-server1-150x150.PNG" alt="configuring Synergy server under Windows" title="synergy-win-server" width="150" height="150" class="size-thumbnail wp-image-370" /></a></p>
<p>To start the synergy server, we now run</p>
<pre class="bash">synergys --config ~/.synergy.conf</pre>
<p>Replacing '~/.synergy.conf' with the path to wherever the config file is saved.</p>
<p><strong>Configuring and starting the clients</strong></p>
<p>So, we have a server. Now, clients.<br />
On Windows, synergy is only one executable, so we start that, select the 'Use another computer's shared keyboard and mouse (client)' option, stick the server's hostname or IP in the box, and click 'start'.<br />
If you have a *nix client, the command to connect to a server at <tt>jup-rmt07</tt> is <tt>synergyc jup-rmt07</tt>. <tt>synergyc</tt> provides a few options for changing the behaviour.</p>
<p><strong>Starting Synergy automatically</strong><br />
Finally, I want them to start automagically on boot/login. For the linux host, this is relatively easy, add the following to your crontab:</p>
<pre class="bash">@reboot synergys --config ~/.synergy.conf</pre>
<p>And it'll be started on boot.<br />
To start it under Windows, click the 'AutoStart' button. This will let you configure it to start it on login or, if you have the requisite permissions, start on boot.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/using-synergy-to-share-a-keyboard-and-mouse-across-pcs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stop OSX writing .DS_Store and ._ files on network shares</title>
		<link>http://blog.avi.co/wp/stop-osx-writing-ds_store-and-_-files-on-network-shares/</link>
		<comments>http://blog.avi.co/wp/stop-osx-writing-ds_store-and-_-files-on-network-shares/#comments</comments>
		<pubDate>Mon, 13 Apr 2009 12:18:34 +0000</pubDate>
		<dc:creator>Avi</dc:creator>
				<category><![CDATA[Geekery]]></category>
		<category><![CDATA[config]]></category>
		<category><![CDATA[files]]></category>
		<category><![CDATA[osx]]></category>
		<category><![CDATA[smb]]></category>

		<guid isPermaLink="false">http://aviswebsite.co.uk/?p=136</guid>
		<description><![CDATA[All our fileservers are Windows. Most of the files are manipulated in OSX. This isn't likely to change soon since, irrespective of who is accountable for most of the bytes, Windows are far and away the most populous in terms of hosts.
.DS_Store files are apple's way of storing the finder preferences for a particular directory. [...]]]></description>
			<content:encoded><![CDATA[<p>All our fileservers are Windows. Most of the files are manipulated in OSX. This isn't likely to change soon since, irrespective of who is accountable for most of the bytes, Windows are far and away the most populous in terms of hosts.</p>
<p>.DS_Store files are apple's way of storing the finder preferences for a particular directory. They contain things like background image, sort order, window size and position, and are written when any value for the current directory deviates from that of the parent, which includes every time it is moved.<br />
._ files are Apple's way of storing attributes supported by HFS and HFS+ on less featureful filesystems (like NTFS and FAT). </p>
<p>To prevent OSX writing .DS_Store files to SMB shares, run the following:</p>
<pre class="bash">defaults <span style="color: #c20cb9; font-weight: bold;">write</span> com.apple.desktopservices DSDontWriteNetworkStores <span style="color: #c20cb9; font-weight: bold;">true</span></pre>
<p>This sets a per-profile value, so must be run as each user.<br />
Preventing ._ files is <a href="http://forums.macosxhints.com/showthread.php?t=45098&page=1">a bit more tricky</a>, but it can be done in/for the shell with:</p>
<pre class="bash"><span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">COPY_EXTENDED_ATTRIBUTES_DISABLE=</span>true</pre>
<p>To prevent Samba accepting these files, enter the following into <tt>smb.conf</tt></p>
<pre class="bash">veto files = /.DS_Store/</pre>
<p>And read <a href="http://www.lavalite.de/2008/10/12/disable-creation-of-_files-dot-underscore-files/">LavaLite's bit on it</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.avi.co/wp/stop-osx-writing-ds_store-and-_-files-on-network-shares/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
