Jeremy Uejio's Blog

Jeremy Uejio's Weblog
Tuesday Jul 29, 2008

LiveUSB creator for fedora

I needed to install Linux to reproduce a bug remotely displaying apps from Linux to Solaris and found a very easy to use Windows executable to create a Fedora Live USB. You can get it from: http://fedorahosted.org/liveusb-creator

The application lets you choose from a couple of different Fedora releases to download and it downloads and creates the USB all in one step.  If the USB create fails for some reason, it doesn't have to download the image again and it lets you continue on after correcting the error.  In my case, my flash drive was not FAT formatted, so after correcting that and refreshing the target device in their GUI, I continued with the USB creation.  The liveUSB booted fine on my Acer 3400.  Now, why can't creating an OpenSolaris liveUSB be that easy?

Wednesday Jul 16, 2008

OpenSolaris on an iPod Touch (via VNC)

Not sure if this would actually be usable, but here it is:


OpenSolaris 2008.05 on an iPod Touch via VNC.

This is using an iPod Touch that I bought a few months ago running the 2.0 Update and running a free VNC app from the App Store.  OpenSolaris 2008.05 in running on a Sun Ultra 20.  I had to enable XDMCP in gdm by editing the file /etc/X11/gdm/custom.conf and changing the xdmcp section to read:

[xdmcp]
Enable=true

Hm... This looks just like OpenSolaris.  "How do I know that you're running on an iTouch?", one might ask.  The only difference is those three buttons on the bottom of the image.  The keyboard button brings up keyboard input:



The "+" button brings up a menu of options and the "hand" button switches between using our finger as the pointer within VNC and using it as the pointer on the Touch. (i.e. to resize the screen and scroll).

Trust me.  I really do have my iTouch running a VNC app and displaying OpenSolaris 2008.05.  It really works! 

Wednesday Jul 02, 2008

simple DTrace script to print function argument

Someone asked me for a DTrace script to print out the argument to an arbitrary function. I'm not exactly sure if this is what he meant, so I wrote a script which lets you specify a function name and the position of the string argument that you want printed out and then the command to run.  Since it's a script, you can modify to print out integer args or to connect to a running process, etc...

The script is called printarg.d.  You have to run it either as root or with sufficient privileges in /etc/user_attr.  For example, this entry allows me to run dtrace scripts:

uejio::::type=normal;defaultpriv=basic,dtrace_user,dtrace_proc,dtrace_kernel

Anyway, here's an example:

$ printarg.d XLoadQueryFont 1 -c dtcalc
XLoadQueryFont: arg1=-dt-interface user-medium-r-normal-m*-*-*-*-*-*-*-*-*
XLoadQueryFont: arg1=-dt-interface system-medium-r-normal-m sans-17-170-72-72-p-97-iso8859-1
XLoadQueryFont: arg1=-dt-interface user-medium-r-normal-m sans-14-140-72-72-m-90-iso8859-1


Here's another example:

$ printarg.d fopen 0 -c dtcalc
fopen: arg0=/home/uejio/.Xauthority
fopen: arg0=/usr/openwin/lib/locale/locale.alias
fopen: arg0=/usr/openwin/lib/locale/locale.dir
fopen: arg0=/usr/openwin/lib/locale/locale.alias
fopen: arg0=/usr/openwin/lib/locale/locale.alias
fopen: arg0=/usr/openwin/lib/locale/locale.dir
fopen: arg0=/usr/openwin/lib/X11/Xcms.txt
fopen: arg0=/home/uejio/.icons/blueprint-cursor-theme/cursors/arrow
fopen: arg0=/home/uejio/.icons/blueprint-cursor-theme/index.theme
fopen: arg0=/usr/share/icons/blueprint-cursor-theme/cursors/arrow
fopen: arg0=/usr/share/icons/blueprint-cursor-theme/index.theme
fopen: arg0=/usr/share/pixmaps/blueprint-cursor-theme/cursors/arrow
fopen: arg0=/usr/share/pixmaps/blueprint-cursor-theme/index.theme
fopen: arg0=/home/uejio/.icons/default/cursors/arrow
fopen: arg0=/home/uejio/.icons/default/index.theme
fopen: arg0=/usr/share/icons/default/cursors/arrow
fopen: arg0=/usr/share/icons/default/index.theme
fopen: arg0=/usr/share/pixmaps/default/cursors/arrow
fopen: arg0=/usr/share/pixmaps/default/index.theme
fopen: arg0=/usr/dt/appconfig/icons/C/Dtcalc.l.bm
fopen: arg0=/usr/dt/appconfig/icons/C/Dtcalc.l_m.bm


Well, I thought this was pretty cool and so easy to do in DTrace, but your mileage may vary. ;-)

If anyone knows of a simpler way to calculate the args to pass in, please let me know.


Archives
Links
Referrers