How to install syslog-ng on Ubuntu solving the conflict with ubuntu-minimal

One of the problems with Ubuntu is its stubbornness. This bug is 7 years old now. It's pretty obvious that it's a bug and no Canonical employee ever disputed this in the bug's comments. The only progress they made so far was to replace the dependency of sysklogd with rsyslog (which was only to make Ubuntu's dependency system work since sysklogd was dropped/replaced with rsyslog over the years). It's a shame that Ubuntu doesn't provide more attention to the details. Sad

How to view the changelog of APT packages

Manually for each package:
aptitude changelog package-name

Automatically for each upgrade (and of course also manually):
sudo apt-get install apt-listchanges
sudo dpkg-reconfigure apt-listchanges


What to do if chmod/chown/rm commands result in "Operation not permitted" error

"Mac has many enhancements to Unix in the area of files. Ignoring the whole resource fork thing which is not used much anymore, there are:
  • the standard Unix permissions ugo rwx and so on. Normal Unix tools apply.
  • ACLs, viewable with ls -le and changeable with chmod [ -a | +a | =a ].
  • file flags viewable with ls -lO and changeable with chflags.
  • extended attributes, viewable with ls -l@ (attribute keys only) and changeable with xattr. (Note that there is no man page for xattr, but it's a simple program described with xattr -h.)


Adjust the startup chime volume of your Mac


To adjust the volume on your Mac's internal speakers:
  • Unplug speakers or headphones from the headphone jack.
  • Go to System Prefs > Sound, then click on the Output tab.
  • You will then see Internal Speakers (Type built-in) highlighted in the window.
  • Adjust the output volume (which also controls the chime volume) in the slider at the bottom of the window. Remember if you mute it there will be no internal speaker sound.
To set the volume for your external speakers:
  • Plug in speakers or headphones to the headphone jack.
  • Go to System Prefs > Sound >, then click on the Output tab.
  • You will then see Headphones (Type built-in) highlighted in the window.
  • Adjust the output volume (which controls the chime volume in the external speakers) with the slider at the bottom of the window. Remember if you mute it there will be no external speaker sound.

How to limit the number of records put into an INSERT statement by mysqldump

The mysqldump manpage says:

net_buffer_length
The initial size of the buffer for client/server communication. When creating multiple-row INSERT statements (as with the --extended-insert or --opt option), mysqldump creates rows up to net_buffer_length length. If you increase this variable, you should also ensure that the net_buffer_length variable in the MySQL server is at least this large.

Changing Android system settings (eg. airplane mode radios) via commandline (on rooted phones)

There's this old question at stackoverflow.com about how to change system settings stored via android.provider.Settings.System using a shell command. The answer is: SQLite.

How to Play Tetris, Pong and Other Hidden Games on Your Mac

"Did you know that you can play Tetris on your Mac? Of course you did, you can play lots of games. But did you know that there’s already a Tetris game built in? In fact, if you know your way around Emacs, you can play a whole bunch of awesome retro games like pong and snake."

Actually macosxhints.com had an article about this years before "the media" picked up on the topic. Smile But obviously this has been around even longer. Wink

Various reasons for the failure of an umount command

An umount command usually fails with the following message:
umount: /mnt/test: device is busy.
        (In some cases useful info about processes that use
         the device is found by lsof(8) or fuser(1))

The referenced blog post lists most reasons for an umount to fail. The use of lsof and fuser is quite common knowledge. However the use of the -v option with lsof is not. Eg. if you try to umount an NFS exported directory and run lsof and fuser, both will produce nothing. But the umount still fails. If you run fuser with the -v option, it'll point out the culprit, namely the kernel's NFS code holding locks on the given partition (as explained here):
# fuser -v -m /mnt/test
                      USER        PID ACCESS COMMAND
/mnt/test:            root     kernel mount /mnt/test

animate.css - "plug&play" CSS3 animations

"animate.css is a bunch of cool, fun, and cross-browser animations for you to use in your projects. Great for emphasis, home pages, sliders, and general just-add-water-awesomeness."

ext4 partition size / free space discrepancies

Up til now I thought that large discrepancies between the total size of a filesystem and the free space reported by the operating system is due to the reserved blocks. But as it turns out, there's another space hog: the inode table.

Syndicate content Syndicate content