Roger's woze

April 29, 2009

squid unable to cache small files

Filed under: Uncategorized — rogerdpack @ 7:45 pm

so…you turn squid’s cache on to

delay_parameters 1 256000/256000

should limit the Bandwidth to 256KB/sec, 256KB max.  Not so!  If you download files < 256K themselves, one at a time, squid will allow each download to download at top speed! Whoa.  Unexpected.

April 28, 2009

svn nfs stale file handle bad

Filed under: Uncategorized — rogerdpack @ 4:01 am

So…got that message once.

Only way to overcome it was to recheckout the current svn folder, then rename it over the top of the existing one (and of course check for modifications in the files).

April 24, 2009

writing cocoa apps in windows (ruby)

Filed under: Uncategorized — rogerdpack @ 8:41 pm

Appears that there’s this

http://snipplr.com/view/2036/wxcocoadialog-dropdown-example-in-ruby/

and

http://code.google.com/p/wxcocoadialog/

so theoretically possible in windows? Or is this cygwin only?

Now to get rubycocoa to work with it…http://rubycocoa.sourceforge.net/HomePage

April 22, 2009

demo c program that does nothing

Filed under: Uncategorized — rogerdpack @ 6:06 pm

here it is –hello world in C.


#include 
int main() {
  printf("helloworld");
  fprintf(stderr, "hello2");
  return 0;
}

how to get the return value of the last executed command in windows dos prompt

Filed under: Uncategorized — rogerdpack @ 5:46 pm

echo %ERRORLEVEL% # even though ERRORLEVEL doesn’t show up when you run “set”

ref:

http://www.computing.net/answers/programming/capturing-return-value-in-batch-scr/14604.html

April 21, 2009

faster copy

Filed under: Uncategorized — rogerdpack @ 5:28 pm

I wonder if disk copy from one disk to the same disk couldn’t be sped up somehow…

ex: read+ zip -> RAM until RAM full, THEN write all that out to disk all at once.

rinse, repeat.

fastish copy

anybody know of anything equivalent?

ref: http://www.ipmsg.org/tools/fastcopy.html.en

does rsync do something equivalent, perhaps, when used on local disk to same disk?

how to increase the size of sennheiser headphones

Filed under: Uncategorized — rogerdpack @ 4:05 pm

Most of us who use sennheiser headphones (I being one who loves them) find that you really can’t use them all day for a working day–they clamp down too tightly on your head and you feel pain after a few hours.

Fix?

” Letting the headphones stretch while clamped on a basketball for several days or clamping them over a thick stack of books will help alleviate that issue for big-head types (like ourselves).”

from

http://www.headphone.com/guide/by-budget/40-80/sennheiser-hd-205.php

I knew there was an answer :)

bluehost rails keepin’ it fresh

Filed under: Uncategorized — rogerdpack @ 2:19 pm

one of the (many) problems with hosting rails at bluehost is that you’re forced into fcgi.  Not that fcgi is bad, per se–but you’re forced into using fcgi with the parameters they specify (which is, that your process, if unused for awhile, should die).  This means that every time you visit the site in the morning, there’s a noticable few second delay.  Actually not bad (almost feels like network lag), but it’s still there.

The fix?  Request a page from your rails hosted site every 5 minutes :)

tool: cron

how: go to mydomain/cpanel, search for “cron” (it’s an icon in there somewhere), then add one something like

0,5,10,15,20,25,30,35,40,45,50,55 * * * * wget http://www.mydomain.com/something > /dev/null

ref: http://www.bluehostforum.com/showthread.php?t=8926

your page will never have a slow startup again :)

mysqlplus lesson

Filed under: Uncategorized — rogerdpack @ 2:14 am

/home/rdp/installs/ruby_trunk_installed/lib/ruby/1.9.1/timeout.rb:50: [BUG] Segmentation fault

ruby 1.9.2dev (2009-04-19 trunk 23207) [i686-linux]

 

– control frame ———-

c:0004 p:—- s:0011 b:0011 l:000010 d:000010 CFUNC  :raise

c:0003 p:0040 s:0006 b:0006 l:001cd8 d:000005 BLOCK  /home/rdp/installs/ruby_trunk_installed/lib/ruby/1.9.1/timeout.rb:50

c:0002 p:—- s:0004 b:0004 l:000003 d:000003 FINISH

c:0001 p:—- s:0002 b:0002 l:000001 d:000001 TOP

—————————

/home/rdp/installs/ruby_trunk_installed/lib/ruby/1.9.1/timeout.rb:50:in `block in timeout’

/home/rdp/installs/ruby_trunk_installed/lib/ruby/1.9.1/timeout.rb:50:in `raise’

 

– C level backtrace information ——————————————-

0x815b625 ruby_19(rb_vm_bugreport+0xb5) [0x815b625]

0x81962ab ruby_19 [0x81962ab]

0×8196338 ruby_19(rb_bug+0×28) [0x8196338]

0x80f4955 ruby_19 [0x80f4955]

0xb7f02440 [0xb7f02440]

0x814774d ruby_19 [0x814774d]

0×8159689 ruby_19 [0x8159689]

0x814c11f ruby_19 [0x814c11f]

0x8152dd2 ruby_19 [0x8152dd2]

0x81551c6 ruby_19(rb_vm_invoke_proc+0×246) [0x81551c6]

0x8160b60 ruby_19 [0x8160b60]

0x8160d41 ruby_19 [0x8160d41]

0xb7ee650f /lib/tls/i686/cmov/libpthread.so.0 [0xb7ee650f]

0xb7dfda0e /lib/tls/i686/cmov/libc.so.6(clone+0x5e) [0xb7dfda0e]

 

[NOTE]

You may have encountered a bug in the Ruby interpreter or extension libraries.

Bug reports are welcome.

For details: http://www.ruby-lang.org/bugreport.html

 

meant “you passed in the wrong param to your rb_thread_blocking_region”

April 20, 2009

vps opportunity

Filed under: Uncategorized — rogerdpack @ 6:29 pm

seems that there is a niche that is waiting–it’s the VPS with 180MB RAM for $12

Compare with linode (who has the best current prices).

http://www.linode.com/index.cfm

Older Posts »

Powered by WordPress