piatok 8. októbra 2010

How to install VMware Server on Ubuntu 10.04 LTS

This procedure works: https://help.ubuntu.com/community/VMware/Server

Maybe restart will be needed...

After successful installation, you can manage VMware server via http://localhost:8222.

sobota 19. júna 2010

Bulk rename of files in directory tree

I needed to remove parts of file-names with broken encoding from directory structure.

Example of the name with bad encoding:

Snímka000.jpg

Requested output example:

000.jpg

I used program find to dump directory tree chained with program rename to do bulk renaming via regular expressions. Here is how it looks like:

find . | rename 's/([^(\/Sn)]*)\/Sn([^0-9]*)([0-9]*\.jpg)$/$1\/$3/'

To check the results before proper execution, you can use flag "-n":

find . | rename -n 's/([^(\/Sn)]*)\/Sn([^0-9]*)([0-9]*\.jpg)$/$1\/$3/'

More info:

man rename
man find

By default, I will not analyze chained command here, but I will answer your questions, if case of need in place.

sobota 17. apríla 2010

How to fix gnome-settings-daemon crashing in Ubuntu 9.10 when connecting via FreeNX

The setup of the server: Ubuntu 9.10 64-bit, FreeNX server

The symptom: unable to switch between keyboard layouts, while connected via NX client - when right-clicking on keyboard indicator and choosing Keyboard Preferences, this error message raises:

Unable to start the settings manager 'gnome-settings-daemon'.
Without the GNOME settings manager running, some preferences may not take effect. This could indicate a problem with DBus, or a non-GNOME (e.g. KDE) settings manager may already be active and conflicting with the GNOME settings manager.


(No problem when logged in locally.)

When trying to start gnome-settings-daemon manually, error output is more detailed:

ostry@celsius:~$ gnome-settings-daemon
Xlib: extension "Generic Event Extension" missing on display ":1000.0".
Xlib: extension "Generic Event Extension" missing on display ":1000.0".
Xlib: extension "Generic Event Extension" missing on display ":1000.0".
Xlib: extension "Generic Event Extension" missing on display ":1000.0".
Xlib: extension "Generic Event Extension" missing on display ":1000.0".
The program 'gnome-settings-daemon' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadRequest (invalid request code or no such operation)'.
(Details: serial 105 error_code 1 request_code 150 minor_code 8)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the --sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)


The solution:


start gconf-editor, then open / -> apps -> gnome_settings_daemon -> plugins -> xrandr in it and disable flag "active".

The conclusion:

There are many reports about this issue on the web, but I consider as important, to have this howto summarized here.

Enjoy!

sobota 9. januára 2010

Sending SMS from Linux via Symbian S60 3rd edition mobile handset connected via USB cable

Application gnokii is a multiple systems tool suite and (eventually) modem/fax driver for the mobile phones (see man gnokii).

You can use it for many things, depending on mobile phone model.

Mobile phones with operating system Symbian are supported with gnapplet application installed in phone. But Symbian S60 3rd edition phones are not supported by gnapplet. But you can use basic function using generic AT model.

Your ~/.gnokiirc file will seem like this:

[global]
port = /dev/ttyACM0
model = AT
connection = serial

/dev/ttyACM0 is symbolic device file for USB port. This can vary on your system, in general, it should be in /dev/ttyACMN or /dev/ttyUSBN, where N is non-zero integer. You can find out it by issuing this command in the shell: dmesg | grep tty.

Succesfull test of gnokii connection with the pohne can seem this way:

ostry@elitebook:~$ gnokii --identify
GNOKII Version 0.6.27
IMEI : PRIVATE
Manufacturer : Nokia
Model : Nokia E00
Product name : Nokia E00
Revision : V ICPR82_09w24

Finally, you can send SMS from command line (Linux shell):

echo "This is a test message" | gnokii --sendsms +PHONENUMBER -r

It works!