While building and testing LiveCDs, QEMU and
VirtualBox can speed up development cycles…
until a bug is encountered: apt-get update hanging on a rename
operation. Maybe aufs is at fault? Its
author then asks for some data, including what happens when some SysRq keys are
pressed. What they are is already quite extensively explained in
Documentation/sysrq.txt
(Linux sources), but I’d like to point to a nice trick for people using
emulation and virtualization tools (ever tried to send Ctrl+Alt+Delete to
a virtual machine?):
# echo $letter > /proc/sysrq-trigger
where $letter is any of the supported SysRq keys. As an example:
# echo d > /proc/sysrq-trigger
# dmesg | tail -1
[558193.423427] SysRq : HELP : loglevel0-8 reBoot Crashdump tErm Full kIll
saK showMem Nice powerOff showPc show-all-timers(Q) unRaw Sync showTasks
Unmount shoW-blocked-tasks
VirtualBox (available in Debian as
virtualbox-ose with a m-a-buildable kernel driver:
virtualbox-ose-source), is quite interesting, and works great on
both sid and lenny. [Why OSE? Open Source Edition.]
Example: X freezes sometimes when gtk-2.11 is installed, maybe due
to bugs like xfwm4's bug #442053, which is quite
annoying since epiphany's trunk needs it. Then develop in a virtual
machine and restart it when needed, leaving the host system
unaffected. It is also quite easy to duplicate, pause, resume, etc.
the virtual machines.
Note: Virtual machines are stored in .vdi files (Virtual Disc
Images). Copying them isn't the way to clone images, since a UID is
stored inside them. Use vboxmanage clone original.vdi clone.vdi
instead.
An annoying bug in VirtualBox is bug #443500: the AltGr key
isn't passed to the virtual machines. Fortunately, upstream's
changeset 3939 fixes that.
Now {, }, [, ], @, |, # are available! \o/
A while ago, IP forwarding was being set through /etc/network/options, which
has been deprecated.
It is possible to play a bit with /etc/sysctl.conf:
net.ipv4.conf.default.forwarding=1 # Or 0...
This sets the default forwarding state of network devices without explicit configuration. It only affects the devices that will be registered in the future.
A similar setting is the following:
net.ipv4.conf.all.forwarding=1 # Or 0...
This applies to all the network devices (even those not in the UP state), but
doesn't apply to the devices that will be registered in the future.
Another setting is the following, which acts as an alias of the previous one:
net.ipv4.ip_forward=1
Then just run sysctl -p to take this parameter into account.
These settings can also be specified replacing the dots by slashes, and are
available under /proc/sys.