Paul - The Programmer

simple & stupid

Enable Adobe Flash Player GPU acceleration on Linux

Flash Player uses the OpenGL to support GPU acceleration on Linux.

This feature requires the below features from the OpenGL facilities.

  • GL_ARB_multitexture
  • GL_EXT_framebuffer_object
  • GL_ARB_shader_objects
  • GL_ARB_shading_language_100
  • GL_ARB_fragment_shader

Flash player automatically checks the video card and driver combination meet the GPU compositing requirement.

However we can ask the Flash player to skip the GPU valiadation by define option OverrideGPUValidation in mms.cfg.

The mms.cfg is a system wild configuration file for policy setting. For Linux, mms.cfg has to be created with the path /etc/adobe.

So, what I need to do to enable the GPU acceleration is :

  1. Create file /etc/adobe/mms.cfg.
  2. Add  "OverrideGPUValidation = 1" ( without the quotes ) in mms.cfg. 1 is for true, 0 is for false.

Unfortunately, this trick does not work for my ATI X300 card. I didn't notice any improvement. The flash played in a little window still make CPU run over 70%.

After checked with glxinfo, I found only the GL_ARB_multitexture. All the other needed OpenGL features are missing. I thought that is the root cause.

By the way, the option OverrideGPUValidation may need Flash rendering problems or even system crash. You should use it with care.

Colorific Man Page

 

# For colourful man pages (CLUG-Wiki style)
export LESS_TERMCAP_mb=$'\E[01;31m'
export LESS_TERMCAP_md=$'\E[01;31m'
export LESS_TERMCAP_me=$'\E[0m'
export LESS_TERMCAP_se=$'\E[0m'
export LESS_TERMCAP_so=$'\E[01;44;33m'
export LESS_TERMCAP_ue=$'\E[0m'
export LESS_TERMCAP_us=$'\E[01;32m'

Add the above in the .bashrc or .profile file

The differences of df and du

  • df:
  1. df gets most of its information from the filesystem's primary superblock.
  2. df calulates the space used by the open files and the inodes.
  3. Check the open file size with "lsof -s <filesystem name> ".
  4. Check the used inode with "df -i".
  • du:
  1. du calculates the exatly size reported by the files on the filesystem. 
  2. du does not count the inodes and the open files.
  3. The block size setting does not effect du's calculation.

df is preciser for the logical used amount of filesystem. As well as du is good at reflecting the use of filesystem from the physical point of view.

redirect stderr to stdout

The intention is to handle the error output as standard output.

e.g.  To filter the permission denied errors complained by command find

find -follow -name 'your pattern' 2>&1 | grep -v 'Permission denied'

give me a colorful linux console

if you want ...

  • colorful grep result;
  • colorful man page;
  • colorful diff result;

just find how-to in the link below. 

wiki.clug.org.za/wiki/Colour_on_the_command_line