Author Archives: lunger

Hide Drives in Safely Remove Hardware

Navigate to the following registry path:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\msahci

Create new keys:

Controller0\Channel0
Controller0\Channel1

… and so on.

For channel you wish to keep from showing up in “Safely Remove Hardware”, create a DWORD named “TreatAsInternalPort” and set the value to 1.

Source

Bookmarklet: Dump MEGA localStorage

This is a bookmarklet that will dump the HTML5 localStorage object into a bookmarklet that you can then import into another browser.

javascript:(function(){
var key; 
var undump = ""; 
for (var i = 0, len = localStorage.length; i < len; i++){ 
key = localStorage.key(i); 
undump += "localStorage.setItem('" + key + "','" + localStorage.getItem(key) + "'); "; } 
console.log(undump);
window.prompt("Bookmarklet", "javascript:(function(){ localStorage.clear(); " + undump + "}());" );  
}());


Display Server Alias in Network Browser

“Network Places” is built from information obtained by the subnet master
browsers, which get and maintain their browse list by listening for
NetBIOS broadcasts and via periodic communication with the Domain Master
Browser (the PDC-E).

Add a REG_MULTI_SZ value named OptionalNames to the HKLM\System
\CurrentControlSet\Services\lanmanserver\parameters key and put both
names in it. Either restart the server service or reboot the system and
both names *should* show up. Eventually. (~12 minutes by default.)

Credit: Wayne Tilton

Ubuntu 10.04.2 Live USB

Created USB using Universal-USB-Installer-1.8.3.7.exe and ubuntu-10.04.2-desktop-i386.iso.

Edited /syslinux/text.cfg on USB as follows:
default live
label live
menu label ^Run Ubuntu from this USB
kernel /casper/vmlinuz
append noprompt cdrom-detect/try-usb=true persistent file=/cdrom/preseed/ubuntu.seed boot=casper initrd=/casper/initrd.lz splash --
label live-nvidia
menu label Run Ubuntu (NVidia)
kernel /casper/vmlinuz
append noprompt cdrom-detect/try-usb=true persistent file=/cdrom/preseed/ubuntu.seed boot=casper initrd=/casper/initrd.lz nomodeset --
label live-vesa
menu label Run Ubuntu (VESA)
kernel /casper/vmlinuz
append noprompt cdrom-detect/try-usb=true persistent file=/cdrom/preseed/ubuntu.seed boot=casper initrd=/casper/initrd.lz xforcevesa --
label live-install
menu label ^Install Ubuntu on a Hard Disk
kernel /casper/vmlinuz
append cdrom-detect/try-usb=true file=/cdrom/preseed/ubuntu.seed boot=casper only-ubiquity initrd=/casper/initrd.lz splash --
label memtest
menu label Test ^memory
kernel /install/mt86plus
label hd
menu label ^Boot from first hard disk
localboot 0x80

 

Busybox on Rooted HTC Desire w/ Android 2.2 Froyo

Install Titanium Backup and use it to install busybox.
Boot into Recovery. If using clockworkmod, be sure to mount system and data. Using the Android SDK, from the command line, run this stuff:

adb shell
cp /data/data/com.keramidas.TitaniumBackup/files/busybox /system/xbin/busybox
chmod 755 /system/xbin/busybox
./busybox --install -s /system/xbin

Enable External Mail on Ubuntu

First, install the appropriate packages:

sudo apt-get install mailutils

Configure Exim for external mail:

sudo dpkg-reconfigure exim4-config

Options:

  • mail sent by smarthost; no local mail
  • FQDN of the system
  • 127.0.0.1  (This will prevent external use of the server to send mail.)
  • localhost; hostname
  • FQDN of the system
  • External (ISP) SMTP server
  • Dial-on-Demand? No
  • Split config? No
  • Root/postmaster recipient: (enter the email address you wish to receive messages sent to root/postmaster on the system).

The root/postmaster recipient is stored in /etc/aliases

The Exim configuration is stored in /etc/exim4/update-exim4.conf.conf.  To apply configuration manually changed in this file, run:

sudo update-exim4.conf
sudo /etc/init.d/exim4 restart

Actual Exim configuration is stored in /var/lib/exim4/config.autogenerated. Don’t edit this file directly.

This was tested on Ubuntu 10.04 (Lucid)