Ben Chuanlong Du's Blog

And let it direct your passion with reason.

Add Users to a Group in Linux

There are several ways to add users to a group in Linux. The following uses the sudo group as illustration.

  1. gpasswd, usermod and adduser can all be used to add a user to a given group. However, it is suggested that you use gpasswd as it is more portable and …

Power Settings in Linux with GNOME Desktop

Full control of the power settings in Linux with Gnome Desktop can be done through dconf-editor at org->gnome->settings-daemon->plugins->power. The default way to determine low battery, critical low battery and to carray out critical low action is by counting left battery time. You can change the way …

Dual Monitor for Linux Desktop

  1. Type xrandr or xrandr -q in terminal to dispaly information of all available output device. Then you can use the following commands to set dual display.
    xrandr --output VGA1 --auto 
    xrandr --output VGA1 --same-as LVDS1 --auto
    xrandr --output VGA1 --mode 1024x800
    xrandr --output VGA1 --off
    

where VGA1 and LVDS1 should …

Rescue Linux from GUI Freezing

The kernel of Linux is usually very stable, but the existing free desktop environments are craps. Amongs these desktop environments I tried (Gnome, Xfce, LXDE and so on), none is even close to the desktop environments in Windows and Mac. I do not require desktop environments in Linux to be …

Adjust Screen Brightness for Linux Desktops

For many computers and laptops installed with Linux desktops, you can use shortcuts (usually Fn + Brightness_keys) to adjust screen brightness. This does not work for some laptops. Another way to adjust screen brightness is to use the following command.

    sudo setpci -s 00:02.0 F4.B=brightness_value

The value …

A Secure Way to Use Vino in Debian

VNC on Linux is not secure. Most implementations of VNC servers for Linux allows password only up to 8 characters. Such a VNC server is very vulnerable to brute-force attack. This article discuss a secure way to use VNC. The VNC (vino) server is started only when needed, thus reduce …