Having fun with Bluetooh in Ubuntu Part 1

Posted July 22nd, 2009 by marslert

Today, my post is about having fun with Bluetooh device in Ubuntu.

First and foremost, lets install obexftp and obexpushd package from OpenOBEX project.

sudo apt-get install obexftp obexpushd

Then, insert your bluetooth device. You should see the bluetooth logo appears in left upper side of your desktop.

Screenshot

Else, you can enable it by System > Preferences > Blueooth > General tab > Check the setting of Notification Area.

Send file to mobile device :

Activating mobile bluetooth connection and scan the device via below comman.

obexftp -b

Scanning result like this,

~$ obexftp -b
Scanning …
Using    00:17:E2:8B:07:7E    Mr.D
Browsing 00:17:E2:8B:07:7E …
Channel: 9

Try to send a file via below command,

obexftp -b 00:17:E2:8B:07:7E -p song.mp3

Receive file from mobile device :

Turn on bluetooth device to discoverable mode.

hciconfig hci0 piscan

Enable obexpushd to listen  incoming bluetooth connection.

obexpushd -B

Try to send a file from your mobile device or scan for your bluetooth device.

obexftp -b

ALERT – configured POST variable limit exceeded

Posted July 21st, 2009 by marslert

Recently, I met some unusual problem after some of hosting servers are using Suhosin. It is kinda good for PHP environment but it could cause problem without any proper configuration.

For instance when you tailing /var/log/message :

Jul 21 21:52:26 server suhosin[19015]: ALERT – configured POST variable limit exceeded – dropped variable ’18_EditView’ (attacker ’123.123.123.123′, file ‘/home/name/public_html/folder/index.php’)

You could not find this error if tailing apache error log.

How to get rid it. You just need to increase Suhosin variables in root php.ini if you did not configure it after installing Suhosin. I would use below settings.

[suhosin]
suhosin.request.max_vars = 500
suhosin.post.max_vars = 500

Manually start wireless – Ubuntu

Posted April 25th, 2009 by marslert

Should you hit a problem on failure starting wireless lan automatically after booting up your ubuntu, execute below command to start your wireless Lan.

sudo ifconfig wlan0 up

Configure MSSQL 2005 Database Mail

Posted March 16th, 2009 by marslert

Due to I am working at a hosting company, coping with Linux and Windows server issues are my daily routine job. I have to keep update myself, learning new stuff. Even my blog share more about Linux stuff, but I will share anything relate to Windows if I ever learn about it.

So, I am going to discuss about configuring MSSQL 2005 database mail in this topic. It is actually a function in MSSQL 2005 configured for sending email. However, MSSQL database mail function will connect to the configured mail relay service for relaying mail.

Read more »

Installing vmware problem

Posted March 5th, 2009 by marslert

Numerous problem might happen when installing Vmware-Server in your Ubuntu system.

As mine after finish installing, some errors occurred when executed vmware

/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_3.4′ not found (required by /usr/lib/libcairo.so.2)
/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_4.2.0′ not found (required by /usr/lib/libstdc++.so.6)
/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_3.4′ not found (required by /usr/lib/libcairo.so.2)
/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_4.2.0′ not found (required by /usr/lib/libstdc++.so.6)
/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_3.4′ not found (required by /usr/lib/libcairo.so.2)
/usr/lib/vmware/bin/vmware: /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1: version `GCC_4.2.0′ not found (required by /usr/lib/libstdc++.so.6)

It was fixed by just simply executing below commands

sudo cp /usr/lib/libpng12.so.0 /usr/lib/vmware/lib/libpng12.so.0/

sudo cp /usr/lib/gcc/i486-linux-gnu/4.2.3/libgcc_s.so /usr/lib/vmware/lib/libgcc_s.so.1/libgcc_s.so.1

:)

Open winmail.dat in Ubuntu

Posted February 25th, 2009 by marslert

I know that I will have some hard time when using Ubuntu after conversion from Windows :) Yeah. It hit me today when I want to read a mail with winmail.dat attachment.

After some research, I learned to install tnef. Once tnef has been installed, execute tnef winmail.dat . A rar file will be output to the directory that consists winmail.dat . Thats it, extract the rar file to find the content inside winmail.dat .

Original guide from http://blog.andrewbeacock.com/2007/07/opening-winmaildat-tnef-files-in.html .

vlc + avi + srt not displayed

Posted February 19th, 2009 by marslert

Sharing of the day.

Keep wondering why my subtitle (srt) cant be displayed when I watch my avi movie with VLC. Though it was not compatible in Ubuntu whereby I was using XP last time which displayed well. Ah Hah. I got the luck solving the problem by edting a file /usr/share/applications/vlc.desktop .

Just need to edit vlc.desktop with su privileges and replace %U for Exec=vlc with %m .

Here we go, double click your avi file and the subtitle will be displaying well.

Without editing this file, you actually can get this problem done by drag the avi file straight into opened VLC. Kinda annoying. Why dont try this way to save the trouble. :)

Additional sharing for conky part which I shared at http://marslert.com/blog/2007/10/02/conky/ .

I was trying to install conky to monitor my laptop process as I found that my firefox keep hogging. The installation is pretty simple and straight forward as any ubuntu users knew :)

Unfortunately, I got problem for this installation whereby some MPD error was throwing after I executed conky.

$ conky
Conky: desktop window (12000c1) is subwindow of root window (59)
Conky: window type – override
Conky: drawing to created window (3400001)
Conky: drawing to double buffer
Conky: MPD error: problems getting a response from “localhost” on port 6600 : Connection refused

Conky: MPD error: problems getting a response from “localhost” on port 6600 : Connection refused

Conky: MPD error: problems getting a response from “localhost” on port 6600 : Connection refused

Conky: MPD error: problems getting a response from “localhost” on port 6600 : Connection refused

Even though MPD configuration is commented in conky configuration, the error is still throwing. Hmmm, what shall do? Lets install MPD through Synaptic Package Manager to solve problem. Yeah. my conky is rocking now :)

apt-get update

Posted February 16th, 2009 by marslert

Sometime, you will get GPG error when running apt-get update after adding some unofficial supported list to your Ubuntu list.

W: GPG error: http://ppa.launchpad.net intrepid Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 28A8205077558DD0

After researching around, found a fix for this kind of situation.

Type in,

gpg –keyserver keyserver.ubuntu.com –recv 247D1CFF

However, you need to replace 247D1CFF with your NO_PUBKEY-key last eight digits from the error-message to import the key. In my case, I replace 247D1CFF with 77558DD0.

After that, add the key to the software source with below command,

gpg –export –armor 247D1CFF | sudo apt-key add -

Again, replace 247D1CFF with your NO_PUBKEY-key last eight digits from the error-message.

You should see some OK message for this 2 command. Then, try running apt-get update and it will be fine.

# mysql
ERROR 1045 (28000): Access denied for user ‘root’@'localhost’ (using password: NO)

Create a file .my.cnf in /root .

Insert below detail to .my.cnf

[client]
user=root
pass=mysql root password