{"id":278,"date":"2004-07-03T12:57:00","date_gmt":"2004-07-03T12:57:00","guid":{"rendered":"http:\/\/adam.rosi-kessel.org\/weblog\/free_software\/recent_discoveries.html"},"modified":"-0001-11-30T00:00:00","modified_gmt":"1970-01-01T05:00:00","slug":"recent_discoveries","status":"publish","type":"post","link":"http:\/\/adam.rosi-kessel.org\/weblog\/2004\/07\/03\/recent_discoveries","title":{"rendered":"Recent Discoveries"},"content":{"rendered":"<p> To be added to my ongoing <a href=\"http:\/\/adam.rosi-kessel.org\/weblog\/free_software\/code\/linux.html\">useful linux<\/a> omnibus page: <\/p>\n<ul>\n<li><b>Firefox 0.9 remote newtab syntax<\/b><br \/> When I open a link from another application (gnome-terminal or <a href='http:\/\/www.ximian.com\/products\/evolution\/' title='Evolution'>evolution<\/a>, for example), I would like it to open in a new tab in <a href='http:\/\/www.mozilla.org\/products\/firefox\/' title='Firefox - The Browser Reloaded'>Firefox<\/a>, so I had a script which I called newmoz:<br \/>\n<blockquote><p> firefox -remote &#8220;openURL($1,new-tab)&#8221; <\/p><\/blockquote>\n<p> This is my default web browser. With Firefox 0.9, the syntax has changed. You now need: <\/p>\n<blockquote><p> firefox -a firefox -remote &#8220;openurl($1,new-tab)&#8221; <\/p><\/blockquote>\n<p> I believe this has something to do with the confusion of the possibility of several related Mozilla applications running all at once, although I&#8217;m not entirely convinced. To make it really snazzy, try: <\/p>\n<blockquote><p> firefox -a firefox -remote &#8220;openurl($1,new-tab)&#8221; || firefox $1 <\/p><\/blockquote>\n<p> This way, if firefox isn&#8217;t already running, it will still work. <\/li>\n<li><b>Email yourself after a long task<\/b><br \/> This is a really obvious one, but I only recently thought of it. Due to several recent failed hard drives, I&#8217;ve been moving a lot of data around from one drive to another, some through NFS, and some over my cable modem. Moving 200 gigabytes, even within a LAN, takes a long time&#8212;even longer if you throttle it so as not to congest the network too much. I would find myself checking back on the process every few hours, even though I knew it probably wasn&#8217;t done. So why not append a mail command after a long process? E.g.:<br \/>\n<blockquote><p> rsync -Pa \/ storage.system.somewhere:backup ; echo done | mail adam <\/p><\/blockquote>\n<p> Since I&#8217;m always checking email, I&#8217;ll find out as soon as it&#8217;s done, and waste less time continually checking back on the process, especially when the transfer might take three or four days. <\/li>\n<li> <b>ssh timeout error\/connection reset by peer with rdiff-backup and D-Link DI-604 router<\/b> <br \/> Backing up <a href=\"http:\/\/bostoncoop.net\">bostoncoop.net<\/a> over a cable modem takes a long time. If something goes wrong, <a href='http:\/\/rdiff-backup.stanford.edu\/' title='rdiff-backup Main'>rdiff-backup<\/a> has to roll back the previous backup and start over. As best I can tell, rdiff-backup first makes the connection, then starts the roll back, but doesn&#8217;t send or receive any data during the roll back. On my system, the roll back can take longer than the timeout period for my <a href='http:\/\/www.dlink.com\/products\/?pid=62' title='D-Link DI-604 4-Port Broadband Router'>DI-604 router<\/a>&#8212;the consequence being that the connection is reset before the backup can start and rdiff-backup fails out.\n<p> There&#8217;s an easy fix, which should come in useful to anyone with a router that is too vigilant about timing out ssh connections (for example, if you ssh to get your email and often leave the window alone for an hour at a time). Add the following to your .ssh\/config: <\/p>\n<blockquote><p> serveraliveinterval 300<br \/> serveralivecountmax 10 <\/p><\/blockquote>\n<p> This will insure that ssh will occasional send an ACK type request every 300 seconds so that the connection doesn&#8217;t die. <\/li>\n<li> <b>Fixed font in gnome-terminal<\/b> <br \/> I&#8217;ve wanted to use gnome-terminal for a long time, primarily because of the tabbed terminal feature (many terminals in one window) and because of the URL recognition (open a URL by right clicking on it). I also like being able to paste into the window with the keyboard.\n<p> There was always one problem, though. The font. I know some people like the new fixed-width GNOME fonts, but I don&#8217;t. I just wanted plain old <em>fixed<\/em>, which I use with xterm (10&#215;20). But that font never showed up in the list of available fonts. <\/p>\n<p> I finally found the solution in \/etc\/fonts\/local.conf&#8212;namely, the following lines: <\/p>\n<blockquote>\n<pre> <!-- Uncomment below to enable bitmapped fonts --> <!-- <dir>\/usr\/X11R6\/lib\/X11\/fonts<\/dir> --> <\/pre>\n<\/blockquote>\n<p> Just uncomment the path, run fc-cache as root, and you should see fixed in the output of fc-list. <br \/> I&#8217;m not sure how a naive user would ever figure this out, but then again, maybe a naive user wouldn&#8217;t care that much about having fixed font in gnome-terminal. I also don&#8217;t understand why we wouldn&#8217;t users to have access to bitmapped fonts by default&#8212;why not just set the default font to something the GNOME people like, but have the other choice in there to start? <\/li>\n<\/p>\n<\/ul>\n<p> Okay, now I&#8217;ve really got to study for the bar exam. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>To be added to my ongoing useful linux omnibus page: Firefox 0.9 remote newtab syntax When I open a link from another application (gnome-terminal or evolution, for example), I would like it to open in a new tab in Firefox, so I had a script which I called newmoz: firefox -remote &#8220;openURL($1,new-tab)&#8221; This is my [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[15],"tags":[],"_links":{"self":[{"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/posts\/278"}],"collection":[{"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/comments?post=278"}],"version-history":[{"count":0,"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/posts\/278\/revisions"}],"wp:attachment":[{"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/media?parent=278"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/categories?post=278"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/adam.rosi-kessel.org\/weblog\/wp-json\/wp\/v2\/tags?post=278"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}